Hello,
[removed original post since it was the product way while I'm going the variant one now, but the solution is the same; so, just to alleviate the thread:]
I'm trying to associate an image and a variant. For this, I'm going through the product API using the PUT method sending this JSON string:
{
"variant": {
"id": 27468625799,
"image_id": 18410371463
}
}
But the Shopify response is: {"errors":{"product":"Required parameter missing or invalid"}}. So, I'm wondering what's the mandatory fields? Where is the place to read this kind of detail in the documentation. My data seems to comply what I read at https://help.shopify.com/api/reference/product_variant#update
EDIT: Solved! My "Content-Type: application/json; charset=utf-8" header was overriden at a point of my code! So, it was not a matter of JSON field, but a matter of HTTP request. Hoping it will help someone else a day...
User | Count |
---|---|
14 | |
12 | |
10 | |
8 | |
7 |