I want to build a plugin for WooCommerce which will export customer order data to my suppliers, and later import the tracking numbers into "Shipment Tracking" plugin ([login to view URL])
The plugin will add a "drop ship" button into every order received in WooCommerce, when clicking the button, a popup window will appear which shows all items on the order with check marks to choose which items will be drop shipped. The user/administrator will check the products to drop ship, then will click on button for Supplier #1, or Supplier #2.
For Supplier #1, it's very simple, we will export a CSV file to an FTP site. The CSV file contains information such as customer name, company, address, city, state, zip, country, product SKU's, and quantities for processing the order. Filename will be [login to view URL]
For Supplier #2, we can use the custom SOAP API developed by the supplier:
[login to view URL]
There are different operations we will use with this API:
PlaceOrder - To submit the order data.
GetShippingMethods - To get a list of valid shipping codes the user can choose.
GetOrderStatusV2 - To get tracking information after the order was shipped.
Finally, at the end of each day, we will get the tracking numbers and import them into "Shipment Tracking" plugin ([login to view URL])
For Supplier #1, the tracking will be in a CSV file in the same FTP site. We can download the CSV file automatically, and import the tracking data into the "Shipment Tracking" plugin.
For Supplier #2, the tracking is provided by the SOAP API by the GetOrderStatusV2 operation. We will get the tracking details each evening