Introduction
In this article, we describe how to integrate with a WooCommerce vendor. If your vendor has a WooCommerce store, Onport can automatically sync products and orders.
Disclaimer
Share this video tutorial or this support article with your WooCommerce vendors to ensure they provide the correct credentials needed for the WooCommerce integration.
Getting started
To get started, Onport will need a valid set of API credentials to communicate with the store. Pre-generated keys can be used to authenticate use of the REST API endpoints. New keys can be generated either through the WordPress admin interface or they can be auto-generated through an endpoint.
Generating API keys in the WordPress admin interface
To create or manage keys for a specific WordPress user, go to WooCommerce > Settings > Advanced > Rest API.
Click the Add Key button. In the next screen, add a description and select the WordPress user you would like to generate the key for. Use of the REST API with the generated keys will conform to that user's WordPress roles and capabilities.
Choose the level of access for this REST API key, which needs to be Read/Write access to sync inventory and orders. Then click the Generate API Key button and WooCommerce will generate REST API keys for the selected user.
Now that keys have been generated, you should see two new keys, a QRCode, and a Revoke API Key button. These two keys are your Consumer Key and Consumer Secret. It's the Consumer Key and Consumer Secret that Onport needs to communicate with the store.
If the WordPress user associated with an API key is deleted, the API key will cease to function. API keys are not transferred to other users.
Generating the legacy API
Go to WooCommerce > Settings > Advanced > Legacy API, and check the option for enabling it.
This should now allow the rest of the connection to work properly.
Syncing inventory levels
Inventory management works slightly differently in WooCommerce than in some other platforms. There isn't always a clear equivalent setting between the two systems. To reconcile the differences, here is how the stock will sync if you are using Shopify and your vendor is using WooCommerce:
- If Inventory tracking is turned off in WooCommerce AND the item IS marked as In Stock, the item will be set to Don't track inventory in Shopify and the item WILL be purchasable in your store.
- If Inventory tracking is turned off in WooCommerce AND the item IS NOT marked In stock, the item will be set to Shopify tracks this product's inventory in Shopify, the inventory quantity will be set to 0 and the item WILL NOT be purchasable in your store.
- If Inventory tracking is turned on in WooCommerce, the item will be set to Shopify to track this product's inventory in Shopify, the inventory quantity from the store will be synced and the item will be purchasable depending on whether the quantity is greater than 0.
Changing the language
WooCommerce isn't multi-language out of the box. However, your dropship provider may have installed a 3rd party plugin to translate the content. By default, the default language of the store will typically be imported. However, there may be a way to override this to bring in an alternative language.
The screencast below will walk you through this process. Currently, only the marketplace admin will be able to set this. It's not possible for the dropship provider to follow these steps in their portal.
Please note, that we may not be able to support every WooCommerce language plugin. This outlines the typical steps taken. If this doesn't work, we'd recommend getting in touch with the plugin creator to see what's possible. Also, it's not possible to automatically translate content, if the content is in another language AND a plugin is not being used.
Important: tracking details
There are some known restrictions that may limit Onport from being able to import tracking details from vendors.
Out of the box, WooCommerce does not have a way to store tracking information. Or, ways to partially ship orders. Onport will detect when the order is complete and mark it as shipped within your store. However, there will be no tracking number of the carrier.
WooCommerce vendors sometimes install 3rd party add-ons to support tracking being added to orders. Onport currently supports the official WooCommerce plugin for this (https://woocommerce.com/products/shipment-tracking/).
Inventory feed's API path and vendor's API order endpoint path
These fields are optional and they refer to the same thing. They are usually left empty unless WordPress is installed in a subfolder. In other words, the API path/API order endpoint path is the subfolder where the WooCommerce/WordPress resides:
For example, the vendor may have a welcome page introducing their business but have the store in a subfolder.
❗️We recommend reaching out to the vendor to confirm if this is the case before fetching the feed the first time within Onport. The API path needs to be specified if the vendor has their shop in a subfolder, otherwise our system won't be able to access and pull their products.
Troubleshooting
Credentials
If you're trying to fetch a WooCommerce feed and it fails yielding an error message saying the API key is invalid or with wrong credentials and the vendor says the API is correct and active, it may be useful to understand what user created the API key initially. API keys are tied to the user who created them, which means that if a user leaves the organization and is deleted from WooCommerce, API keys created by that user will be rendered useless. In that case, creating a new API key is imperative.
Taxes
Unable to connect
If you are not able to successfully sync your merchant's WooCommerce store with Onport, read below for some tips on resolving the issue. For more tips on debugging WooCommerce connection issues, see this helpful support article from WooCommerce.
- What version of WooCommerce are you using? Onport only works with WooCommerce 2.2.0 and above.
- Is the REST API enabled? In your WordPress Admin, go to WooCommerce > Settings > General and make sure the Enable the REST API option is checked.
- Even if you’re using WooCommerce 2.1.7+, try upgrading to the latest version of WooCommerce. There may be a bug in your version of WooCommerce that has been fixed in the latest version.
- If you’ve been able to connect in the past and can no longer connect, have you installed any new plugins?
- Do you have iThemes Security installed? Ensure that “filter suspicious query string URLs” is disabled under Security > Settings > System Tweaks.
- If you come across an error when connecting Onport to a WooCommerce store, it might be because the legacy API is not enabled in your vendor's store.
Comments
0 comments
Please sign in to leave a comment.