How to enable products on Online Store using the API

New Member
7 0 0

Hello Shopifyers!

I need help with the API... I manage stock and price no problem, but for some reason when trying to publish (true or false) I get an error of "Not Acceptable". Here's the API call example:

 

PUT /admin/api/2019-10/products/#{product_id}.json { "product": { "id": 632910392, "published": true } }

 

Any help really appreciated :)

Simon
Vehicle-Spares.com

0 Likes
Shopify Staff
Shopify Staff
223 28 28

Hello @Simon__Vehicle- 

 

Are you only publishing to the Online Store? If so, you can use published_scope: web You can read more in our Product API documentation here: https://help.shopify.com/en/api/reference/products/product

Vix | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 


1 Like
Highlighted
New Member
7 0 0

Hello @vix 

 

Thank you for your reply. Yes I am only publishing to the Online Store. How do I update the "published_scope: web" ? Also, when an item is out of stock and discontinued I also want to remove the product from Online Store. Would that also be managed through "published_scope" with a different value?

Thanks

 

Simon @ Vehicle-Spares.com

0 Likes