0

I have a master woocommerce website and there are few slave woocommerce websites. I have copied all the products in into the slave websites. I want to show product stock from master website only. So for example, if there are 4 USB's in stock on master and 1 gets sold. All the other slave website should show 3 USB in stock.

In short, How can I show the stock in slave woocommerce website from the stock of Master woocommerce website ? What do you suggest me to do?

Thank You!

John MD
  • 1
  • 1

1 Answers1

0

You can use Woocommerce Rest API https://docs.woocommerce.com/document/woocommerce-rest-api/

Use API: http://woocommerce.github.io/woocommerce-rest-api-docs/?php#retrieve-a-product

Anil Dhull
  • 31
  • 3
  • Updating stock with API sucks, I have 480 slave websites. It takes 10 minutes to sync quantity. I need this in real time. Can I grab the stock from master website ? So at the time of displaying products on website, can I fetch stock from master website using sku ? – John MD Oct 13 '16 at 08:07
  • If you are using Multisite, you can use switch blog function. – Anil Dhull Nov 08 '16 at 06:15