Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

Product price issue

Solved

Product price issue

redsolstore_com
New Member
5 0 0

We need to know, how to update the price using only the handle or variant sku column.

Accepted Solution (1)

Liam
Community Manager
3108 344 910

This is an accepted solution.

Shopify does not provide a direct way to update the price using only the handle or variant SKU. However, you can query the product or variant ID using the handle or SKU. The REST API provides a productVariant query where you can filter by SKU. Then, once you have the product or variant ID, you can use the ProductUpdate mutation to update the price.

 

Hope this helps!

Liam | Developer Advocate @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

View solution in original post

Reply 1 (1)

Liam
Community Manager
3108 344 910

This is an accepted solution.

Shopify does not provide a direct way to update the price using only the handle or variant SKU. However, you can query the product or variant ID using the handle or SKU. The REST API provides a productVariant query where you can filter by SKU. Then, once you have the product or variant ID, you can use the ProductUpdate mutation to update the price.

 

Hope this helps!

Liam | Developer Advocate @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog