App reviews, troubleshooting, and recommendations
Hello,
I'm creating an app where at some moment I need to add a product to the shop, I have used the graphql client, and passing these variables for the product creation.
It works fine and creates me a product when I do it like that
variables: {
input: {
title: `${data.title}`,
variants: [{ price: randomPrice() }],
},
},
but when I try to add an image to the product, it gives me an error.
These are the variables I'm trying to post...
variables: {
input: {
title: `${data.title}`,
"images": [
{
"width": 110,
"height": 140,
"src": data.imageUrl,
"variant_ids": [
{}
]
}
],
variants: [{ price: randomPrice() }],
},
},
I'm doing it the right way or should I do something else in order to give the product an image url?
Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025