WooCommerce: Order Workflows and Inventory Sync with n8n
How to connect WooCommerce orders to accounting or ERP via n8n and automatically sync your inventory.
When a new order comes in on WooCommerce, it should not just land in the shop, but also reach accounting, the ERP system and the inventory, ideally without anyone typing the data in manually. With the WooCommerce node and the WooCommerce Trigger node, n8n brings exactly this connection: orders automatically trigger workflows, inventory levels can be synced with external systems, and you always stay in control of which data flows where. As of: July 2026.
For shop operators who want to connect WooCommerce to accounting or inventory management software, this is a classic automation case. No custom code, just a workflow built on official interfaces that can be extended to further systems as needed.
What does the WooCommerce node in n8n do?
The WooCommerce node covers three resources that map the entire order process: customers, orders and products. Each of these resources offers the same basic operations, namely create, update, delete, get a single record and get all records. For inventory sync, the product resource is especially relevant, because the "update" operation lets you write an item's stock level directly back to WooCommerce once it has been posted in accounting or the ERP. According to the n8n documentation on the WooCommerce node the same node can also be used as a tool for an AI agent, so parameters are filled in automatically depending on context. For a classic, deterministic inventory sync this is not strictly necessary, but it shows how flexible the integration has become.
WooCommerce Trigger: automatically detecting orders
The actual starting point for an order workflow is the WooCommerce Trigger node. It registers a webhook in the background in your WooCommerce shop and starts the n8n workflow as soon as the selected event occurs. According to the n8n documentation on the WooCommerce Trigger twelve event types from four areas are available:
- Orders: created, updated, deleted
- Products: created, updated, deleted
- Customers: created, updated, deleted
- Coupons: created, updated, deleted
For an order workflow, the "order created" event is usually enough. The trigger then delivers the complete order record with all line items, quantities and customer data, which you process further in the following steps.
Building inventory sync between WooCommerce and accounting or ERP
A solid inventory sync workflow follows the same pattern in practice, regardless of whether a classic ERP, an inventory management system or an accounting tool sits on the other end:
- Trigger: The WooCommerce Trigger node starts the workflow on "order created" or, alternatively, on a status change such as "completed", in case cancellations or returns should only affect stock later.
- Prepare line items: A Split or Set node breaks the order down into its individual line items, so each item number can be processed separately.
- Notify accounting or ERP: An HTTP Request node or a dedicated node for the target system creates the document, order or stock posting in the ERP, usually linked via SKU or item number.
- Write stock back: The WooCommerce node uses the "update product" operation to update the relevant item's stock level in WooCommerce, so the shop immediately shows the reduced stock.
- Add an error path: If the posting in the ERP fails, the workflow should surface that through a separate notification instead of silently leaving the stock level wrong.
It is important that the item number or SKU in WooCommerce matches the item identifier in the target system exactly. If it differs, for example due to leading zeros or different spellings, the automatic sync breaks at exactly that point and has to be corrected manually.
Setting up credentials and permissions correctly
For n8n to access your WooCommerce shop at all, you need an API key from the WordPress backend. According to the n8n documentation on WooCommerce credentials you create this under "WooCommerce > Settings > Advanced > REST API > Add key" and assign the "Read/Write" permission. Without write access the workflow can read orders but cannot write stock back, so the inventory sync would fail at this point. You then enter the consumer key, consumer secret and your shop's URL in n8n. If WooCommerce reports an error about a missing consumer key transmission during testing, the documentation says the "Include Credentials in Query" option helps, which transmits the credentials as a query parameter instead of in the header.
Typical pitfalls in the order workflow
- Simultaneous orders: If several orders for the same item come in almost simultaneously, a brief overselling situation can occur without additional safeguards. An intermediate step that fetches the current stock level again before writing it back reduces this risk.
- Failed webhooks: Webhooks are reliable, but not infallible, for example during a brief shop downtime. An additional, less frequently running sync via a schedule trigger catches missed events as a safety net.
- Inconsistent item numbers: If SKUs in WooCommerce and item numbers in the ERP are not maintained identically, the matching fails silently in the background. A mapping table as an additional step in the workflow creates clarity here.
- Missing permissions: Read-only credentials prevent any writing back to WooCommerce, even if the rest of the workflow runs without errors.
If you do not want to build the order workflow and inventory sync on your own, you can find support in the n8n offering from NordFlux, from the initial trigger setup to connecting the right ERP system.
Frequently asked questions
How does n8n automatically detect new WooCommerce orders?
The WooCommerce Trigger node registers a webhook directly in your shop for this. As soon as an order is created, WooCommerce sends the data to n8n, and the corresponding workflow starts without delay through a manual retrieval.
Can inventory be synced in real time?
Yes, as long as the workflow is triggered directly upon order receipt, the inventory sync runs practically in real time. For very high order volumes for the same item, it is also worth adding a step that checks stock again immediately before writing it back.
Which permission do the API credentials need for inventory sync?
For simply reading orders, a read permission is enough. If n8n is supposed to write inventory back after posting in the ERP, the API key in WooCommerce must be created with "Read/Write" permission.
What happens if the webhook fails once?
The affected workflow run for that event is then not automatically retried; WooCommerce does not retry a failed webhook indefinitely. As a safeguard, an additional, scheduled workflow that periodically syncs open orders with the ERP is recommended.
Can the same workflow be used for multiple WooCommerce shops?
Yes, to do this you create separate WooCommerce credentials for each shop and link them to their own trigger and node instances. The actual processing logic, for example passing data on to the ERP or accounting, can be reused as a shared sub-workflow.
NordFlux UG (haftungsbeschränkt)
NordFlux builds digital employees for organisations: automations and AI agents that take over repetitive work. You stay in control.
Concrete questions about automation or AI?
In a free initial analysis we discuss your case directly. No strings attached.