Hi fellow developers,
I’m experiencing very strange behavior when uploading images using the productUpdate api. I’m using the “new” media method. In most of the cases it works, but occasionally it fails, not sure why. Then I attempt to upload the image again and it usually works the second time.
Now the strange part starts. It looks like the failed images get stuck on the product with a “FAILED” state, which results in two things
-
The product list in admin doesn’t display a preview thumbnail, even though the product has one or more working images
-
Checkout doesn’t display a thumbnail either, again the product having working images (See below screenshot)
The displaying of images is working everywhere else, Collection page, product page and on the cart
I can fix this behavior by going to the product in admin (see screenshot) and clearing the errors. Product list and checkout now correctly shows the image
Checkout and admin product list image now working
Is this by intention? Do I somehow need to clear those errors using the API? I’m failing to see how though.
API Version: 2023-10
Input sample
{
input: {
id: product.id
},
media: [
{
alt: imageName,
mediaContentType: 'IMAGE',
originalSource: `${imageUrl}` //This translates to an external imageUrl
}
]
}





