After creating a product how can I publish it to the online store?

Wakil_eFoli
Shopify Partner
43 2 4

I'm creating new product using the productCreate mutation. Now I want to publish it to my online store.

To do that I'm querying the list of publications using the publications query but the challenge I'm facing is to determine which publication id belongs to the online store? Previously they had a "name" property which is now deprecated. 

 

Once I become certain that this id belongs to the online store then I can publish it using the publishablePublish mutation.

Also how can I set the inventory quantity of a newly created product?

Thanks! 

 

Replies 2 (2)

websensepro
Shopify Partner
1047 146 153

hi, @Wakil_eFoli 

websensepro_0-1700120085821.png

 

websensepro_1-1700120091131.pngwebsensepro_2-1700120097097.png

 

Need a Shopify developer?
Hire us at WebSensePro
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel or buy us a Cofee here
Wakil_eFoli
Shopify Partner
43 2 4

I don't see anything relevant to my question i.e. publication or inventory.