All things Shopify and commerce
Hey folks, i'm trying to migrate from API Rest to GraphQL in N8N because i got an automation workflow where i receive some products through JSON information, BUT in REST i can create the product with price, name, stock available and other stuff, on GraphQL the only options i can create is Title, HTML description, tags and vendor... but i need to place the price, stock, some products we sell by specific units (like 10$/100ml) and etcetera.
The only thing that worked was creating the product:
mutation CreateProduct { productCreate(product: { title: "Purple LED Light", descriptionHtml: "<p>Description on HTML</p>", productType: "Lights", vendor: "MXLED", tags: ["LED", "PURPLE"], metafields: [ { }] }) { product { id title vendor tags } shop { id } userErrors { field message } } }
PS: More than 90/95% of products are unique, so if there's another type, it's another product, so I'm not going to create a product with several variants, there may be a few exceptions.
Have a look at the productSet mutation: it allows you to add variants with price and more.
https://shopify.dev/docs/api/admin-graphql/latest/mutations/productSet
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025