Skip to content

Developer Documentation

WooCommerce Zapier is built with third-party developers in mind.

The WooCommerce REST API and WooCommerce webhooks are used extensively for the integration.

Heads Up

We are unable to provide support for writing custom code, so you may need to enlist the support of a professional WordPress/WooCommerce developer if you need assistance.

REST API Endpoints

The following REST API endpoints are available for the WooCommerce Zapier integration. These are used exclusively by the WooCommerce app on Zapier.com, and they should not be used by any other third-party applications, as the following endpoints are subject to change without notice.

This list of endpoints is provided as a reference in case they need to be whitelisted by your security plugins or hosting provider.

All endpoint URLs are relative.

Endpoint Used Method(s) API
/wc-zapier-auth/v1/authenticate POST Authentication
/wp-json/wc-zapier/v1/ GET REST Index
/wp-json/wc-zapier/v1/ping GET Authentication test
/wp-json/wc-zapier/v1/bookings GET Bookings Resource1
/wp-json/wc-zapier/v1/coupons GET, POST, PUT, OPTIONS Coupons Resource
/wp-json/wc-zapier/v1/customers GET, POST, PUT, OPTIONS Customers Resource
/wp-json/wc-zapier/v1/memberships/members GET, POST, PUT, OPTIONS User Membership Resource2
/wp-json/wc-zapier/v1/memberships/plans GET, OPTIONS Membership Plan Resource2
/wp-json/wc-zapier/v1/orders GET, POST, PUT, OPTIONS Orders Resource
/wp-json/wc-zapier/v1/orders/notes GET, POST, OPTIONS Order Notes Resource
/wp-json/wc-zapier/v1/products GET, POST, PUT, OPTIONS Products Resource
/wp-json/wc-zapier/v1/products/prices PUT Update Product Price
/wp-json/wc-zapier/v1/products/stocks PUT Update Product Stock Quantity
/wp-json/wc-zapier/v1/subscriptions GET, POST, PUT, OPTIONS Subscriptions Resource3
/wp-json/wc-zapier/v1/subscriptions/notes GET, POST, OPTIONS Subscription Notes Resource3
/wp-json/wc-zapier/v1/webhooks POST, DELETE Webhooks
/wp-json/wc-zapier/v1/webhooks/topics/<resource> GET Webhooks Topics

Note

WooCommerce Zapier has never used WooCommerce’s Legacy REST API. There is no need to enable it in the settings.

Authentication

To authenticate, issue a POST request to the /wc-zapier-auth/v1/authenticate endpoint with a valid WordPress administrator username and password. With WordPress 5.6 and above you may want to use an “Application Password” to provide greater compatibility with third-party plugins.

Upon successful authentication, the response will include a consumer key/secret that you can use for authorisation.

Authorisation

You may use the HTTP Basic Auth header by providing the REST API Consumer Key as the username and the REST API Consumer Secret as the password.

curl https://www.example.com/wp-json/wc-zapier/v1/orders \
    -u consumer_key:consumer_secret

Occasionally some servers may not parse the Authorisation header correctly (if you see a “Consumer key is missing” error when authenticating over SSL, you have a server issue). In this case, you may provide the consumer key/secret as query string parameters instead.

REST API

The WooCommerce Zapier endpoint behaviours are based on the WooCommerce REST API version 3 and some cases version 1. For detailed information by endpoints, please see the original documentation:

Warning

Even though the WooCommerce Zapier integration is based on the above endpoints, it does not support the following functionality:

  • No batch actions.
  • No delete support (only create, update and search).
  • No subtype access. For example: Order refunds or Product attributes.

Extending Zapier Integration

To modify or extend the data transmitted to Zapier via a Webhook or received through the REST API, you can utilise the filters provided by WordPress and WooCommerce. This process typically involves implementing available filters and hooks to append additional fields to the existing REST API endpoints of WooCommerce. By modifying the data within the Webhook payload or the REST API input, these changes will be recognised by WooCommerce and, consequently, by our plugin, which will automatically incorporate them.

Before customising the data flow between WooCommerce and Zapier, the initial step is to pinpoint the hook corresponding to the specific modification you wish to implement. This helps to ensure that your customisations are preserved even when the core software is updated. Identifying the right hook is crucial, as it determines where and how your custom code will interact with WooCommerce’s processes. Once the appropriate hook is identified, you can write and integrate your custom code, which will execute precisely when the hook is called. This process allows for seamless integration of your enhancements, ensuring that the data sent to Zapier via Webhooks or received via the REST API contains all the necessary information tailored to your operational requirements.

Important

It’s crucial to remember that if you introduce any new fields or change behaviour to create, update, or find endpoints, you must also provide schema definitions for these fields. This step is essential because the WooCommerce Zapier integration depends on the endpoint schema definitions to accurately identify the available data fields for each resource/endpoint and build the field interface for the Zap editor. To accomplish this, the woocommerce_rest_{$object_type}_schema filter can be employed.

Modifying output data

You might use the general WordPress rest_post_dispatch filter to alter the data sent out. Alternatively, you can employ a more specific WooCommerce filter tailored to the resource, such as woocommerce_rest_prepare_{$this->post_type}.

Accessing incoming data

When dealing with incoming data, the general WooCommerce filter woocommerce_rest_{$this->post_type}_query can be pretty valuable. Additionally, you may opt for other filters more specific to the particular Resource or Action within WooCommerce.

By leveraging these hooks and filters, you can seamlessly customise the data interactions between WooCommerce and Zapier, ensuring a smooth and efficient workflow that caters to your specific requirements.

Useful Documentation

Translating

You can easily translate the WooCommerce Extension interface to your language using the provided languages/woocommerce-zapier.pot file as a starting point.

If you do translate WooCommerce Zapier, please contact us and send us the translation file so that we can include it in the extension for others to benefit from.

REST API Logs

To understand how WooCommerce Zapier uses the REST API, you may wish to install the REST API Log Plugin.

After installing the plugin, trigger a few of your Zaps and then navigate to WordPress DashboardSide MenuToolsRest API Log screen to see which endpoints are queried.


  1. Only available if the WooCommerce Bookings plugin is installed. 

  2. Only available if the WooCommerce Memberships plugin is installed. 

  3. Only available if the Woo Subscriptions plugin is installed.