How do I rename product media filenames with the products API deprecation update?

Topic summary

Main issue: After the deprecation of productImageUpdate, productUpdateMedia doesn’t allow uploading product images with renamed filenames. Previously this was possible via the REST endpoint (products/product_id.json), including batch updates and ALT text changes.

Official guidance: There is no REST alternative. The GraphQL mutation fileUpdate can rename files and update ALT text; if the file is referenced by a product, those updates propagate.

Current limitation: fileUpdate requires the filename extension to match the original, blocking format changes (e.g., PNG↔JPG). Attempts to upload a PNG for a JPG lead to a black background (transparency lost; screenshot linked), and PNG→JPG conversion returns “The filename extension provided must match the original filename.”

Impact cited: Image optimization apps processing hundreds of thousands of images daily (millions monthly) rely on format conversion; 93% of customers reportedly use PNG→JPG conversion.

Status: No solution provided for changing file extensions or formats under the new APIs. The request for capability to change filenames and extensions (including PNG↔JPG) remains unresolved and open.

Summarized with AI on December 29. AI used: gpt-5.

With the deprecation of productImageUpdate I cannot upload a renamed image with productUpdateMedia.

As an image optimizaiton app that optimizes over 100 thousand images each day (we optimize filenames, convert from png to jpg and add ALT texts) and with this new updates, I cannot see a way to upload new filenames through productUpdateMedia.

Previously It was really easy through productImageUpdate or to update all images at once with REST API products/product_id.json

Is there a way now to upload new product gallery images with new filenames and ALT texts ?

Hello!

Unfortunately we don’t have an alternative option do this outside the deprecated API in REST. We do however have a targeted API for doing exactly this in GraphQL: fileUpdate.

With fileUpdate, you’ll be able to directly rename the file or update alt texts. If the file is being referenced by a product, it should be updated for the product as well.

If I want to upload a png image instead of jpg image (to have the image transparent) - I cannot do that as as black background is applied: https://prnt.sc/4a_qacYbqLlR

Same goes the other way around. If I want to upload a converted image from png to jpg (as It’s a log lighter in most cases) - I cannot do that. I get the error “The filename extension provided must match the original filename.”.

Please advise as we need a way to change the image filename and It’s extension too.

We optimize millions of images each month for merchants and file conversion from png to jpg is really widely used. To be exact - 93% of our customers use png to jpg conversion.

This functionality is crucial for us and all other image optimization apps, background removal apps and image modification apps.

1 Like