I am currently saving some images in shopify via File API:
mutation fileCreate($files: [FileCreateInput!]!) {
fileCreate(files: $files) {
files {
alt
}
userErrors {
field
message
}
}
}',
[
'files' => [
'alt' => $alt_text,
'contentType' => 'IMAGE',
'originalSource' => $from_url,
]
]
It works, but unfortunately I am not able to get the url in return. It returns null as if it's still processing. Is there any way to do it? I am saving the image name locally, but I wouldn't consider querying the api again for each single one a valid solution (too many files, huge overhead)
Thanks in advance