Solved

How to update product via REST without loosing images?

friendoftheroot
Shopify Partner
45 4 8

Hello,

 

I built an importer for products and variations with images.

Everything works fine.
Sometimes I want to update that data more regularily and avoid pushing the images. However it seems images get overwritten. 
What is the solution here, do I have to get the imageids first?
I would like to avoid that as it increases he number of calls quite significantly.

Accepted Solution (1)

friendoftheroot
Shopify Partner
45 4 8

This is an accepted solution.

If not handing over the media id the original images get deleted. I got this sorted with a seperate call to get the media id. It is a bit cumbersome, as it increases the number of calls to the api. Would be much better just to set a flag, but it is what it is.

 

View solution in original post

Replies 2 (2)

friendoftheroot
Shopify Partner
45 4 8

I solved this one.

friendoftheroot
Shopify Partner
45 4 8

This is an accepted solution.

If not handing over the media id the original images get deleted. I got this sorted with a seperate call to get the media id. It is a bit cumbersome, as it increases the number of calls to the api. Would be much better just to set a flag, but it is what it is.