Nexus ERP — WooCommerce
WooCommerce ↔ Nexus ERP integration for catalog association, price and stock synchronization, and order operations, with local cache, automations, stock reservations, and reconciliation.

Core stack
The challenge
The integration had to keep two systems coherent despite different models for product, warehouse, stock, and order, while some ERP endpoints return large datasets and ignore filters, and automatically retrying a write could create duplicate documents. In addition, WooCommerce stock had to be protected against double deduction while ERP reservation and local orders could be temporarily out of sync.
The solution
The plugin introduces a normalized local ERP catalog, periodically updated through bulk upserts, and uses an explicit WooCommerce product ↔ ERP product ↔ warehouse association. Syncing applies the price and stock from the cache, subtracts local commitments not yet reflected in ERP, and disables native stock reduction for integrated products. For orders, writes have no automatic retry, and recovery relies on external identifiers, metadata, read-back, and healing; reservation, cancellation, and state changes are handled according to the ERP's actual rules.
Notable complexity
Nexus ERP — WooCommerce is a WordPress plugin built to operationally link the online store to Nexus ERP. The administrator configures the connection, associates WooCommerce products with ERP products and the relevant warehouse, then can sync prices and availability manually or on a schedule. The interface includes settings and diagnostics, a dedicated WC ↔ ERP association board, a product list with sync status, a read-only per-product metabox, and an operational log.
The ERP catalog is not queried separately for each product. The plugin pulls products, prices, and stock, normalizes the data into three local MySQL tables, and performs batched upserts. Price and stock are then read from the local cache for the warehouse associated with each product. Available stock accounts for the quantity reserved in ERP and for open WooCommerce orders whose reservation is not yet reflected in ERP, and WooCommerce's native reduce/restore stock mechanism is blocked for products managed by the integration to avoid double adjustments.
The order flow starts automatically when an order reaches Processing or can be triggered manually. The payload is validated, products must have an ERP association, and the lines are grouped by warehouse. The ERP partner is resolved from the billing data, with distinct rules for individuals and companies and an option for automatic creation. After sending, the plugin can retrieve or realign the order's ID and status from ERP, update the header and lines, reserve or release stock, and propagate cancellation within the transitions allowed by the API.
For read operations, the HTTP client only retries transport errors, with backoff. Writes are not retried automatically, since a blind retry could duplicate documents in ERP; instead, the flow uses external identifiers, metadata, and reconciliation through read-back. There is also healing for orders marked as sent but left without an ERP ID, plus best-effort protections for concurrent send, cancel, and reservation operations.
The UI is integrated into WordPress Admin and uses native components, vanilla JavaScript, and custom CSS. The association board offers search, filters, pagination, single/bulk mode, and catalog refresh, and the order metabox offers sending, status checking, updating, and state changes. The repository includes PHPUnit/Brain Monkey tests for sync, catalog, API responses, orders, partners, and stock rules, as well as a build script that produces the installable WordPress archive without development files.
Key results
- WooCommerce plugin with dedicated pages for settings, product association, product monitoring, and operational logs
- Local ERP catalog split into products, prices, and stock, with periodic updates and bulk operations
- Single and bulk association between WooCommerce products and Nexus ERP products, including per-product warehouse
- Manual and scheduled synchronization for price and stock, with handling of products without a valid price
- Automatic or manual sending of WooCommerce orders to ERP and grouping lines by warehouse
- Optional resolution and creation of ERP partners from billing data, with distinct individual/company rules
- ERP stock reservation and release, plus protection against double stock adjustment in WooCommerce
- Reconciliation for order IDs and statuses, including healing for confirmed imports without a persisted ID
- Header/line updates and controlled propagation of state changes and cancellations to ERP
- PHPUnit/Brain Monkey suite and a packaging script for the installable WordPress archive
Related projects
- Farmadati ImportWordPress module that pulls Farmadati datasets via SOAP, normalizes the XML schema, and enriches WooCommerce products with prices, descriptions, manufacturer, pharmaceutical metadata, and images.
- Feed2WooAIWordPress plugin for batch-importing products from JSON feeds into WooCommerce, updating by SKU, images, and categories, OpenAI rewriting, admin progress tracking, and automation through REST endpoints and cron scripts.
- Page Content ExtractorOperational WordPress tool for finding and bulk-updating localized pages, with Elementor/Gutenberg/Classic support, AI rewriting via Gemini, and image generation via Vertex AI Imagen.
Want something similar?
Start with the estimate wizard — answer a few questions and get a realistic price range and timeline.