Making inventory synchronization between NetSuite and Adobe Commerce fast and reliable
Project Size:
2 developers, 1 PM
Timeline
3 weeks
USED TECHNOLOGIES
SuiteScript 2.1, RESTLet, SuiteQL, NetSuite Saved Searches.
We helped DecksDirect overhaul their inventory integration between NetSuite and Adobe Commerce to ensure reliable stock levels on the website and prevent overselling.
Challenge
A previous SOAP-based integration relied on a Saved Search to list recently modified items, which Adobe Commerce would then retrieve every hour. Then, once a day it would refresh the stock of all items.
This method had major drawbacks:
Unreliable Stock Information: A 60-minute delay between updates meant the stock numbers on the website were often inaccurate.
Pending Approval Quantity: Products in pending approval orders are not committed until the order is approved. This means the inventory remains available for other customers, often leading to overselling.
Inefficient Data Transfer: The system couldn't identify changes that were only related to stock levels. This led to unnecessary data transmissions for products that hadn't been modified in other ways, creating redundant work and slowing things down.
Performance Nightmare: Hourly syncs taking up to 45 minutes during peak hours
Out of fashion technology: SOAP complexity made integration changes nearly impossible

Requirements
Inventory data on the website must be accurate at all times — Sync frequency of 5 minutes
Data transmission efficiency - To optimize API communications and reduce the payload size, we must ensure that every data transmission includes only items with changes to their stock, with no redundant data.
Incremental stock changes must take less than 60 seconds
Inventory level must account for “Pending Approval” orders
Zero tolerance for page load time increase – real-time updates are not an option
Technology must provide for rapid prototyping and testing
Solution
We designed and built a RESTLet API that:
Calculates item availability for all synced products
Deducts items in Pending Approval orders
Supports Item Groups and Kits
Calculates the difference compared to the last sync, and only transmits stock information of items with any changes
Supports for a full refresh, that is retrieved by Adobe Commerce every night, to reset stock information.
Includes lead time and backorder strategy information
Implements OAuth 1.0 (Token Based Authentication) for secure communications.

Results
Overselling issues disappeared
Website stock information is always reliable and up-to-date.
Performant API communications, reduce stress on website servers
SuiteScript and REST-based architecture allows for quick development iteration of the product
Fully native NetSuite integration, requiring no external connector platforms
Conclusion
In the end, the new RESTLet API successfully solved DecksDirect's inventory problems. By providing reliable, near real-time updates and accounting for items in pending approval orders, the solution eliminated overselling. This native NetSuite integration not only improved performance but also set up a flexible, modern system for future growth.