Supplier Feed to Storefront Inventory Pipeline
The problem
Every supplier publishes stock files in its own shape. Some arrive as downloads from a supplier site, some as email attachments, and some split quantity across warehouse columns that have to be summed. The files decide which products the storefront may sell at zero stock, so a stale refresh quietly turns into wrong availability. Today the cleanup is manual and happens about once a month.
The approach
Model each supplier as a small adapter that outputs one shared schema: SKU, available quantity, and a sell-at-zero flag. Validate every SKU against the inventory export from the dealership management system, then write the storefront import file. Plain Python scripts, and EDI where a supplier offers it, fit better than a low-code flow here, given licence cost and a locked-down IT environment. An AI agent can help map a new supplier format, but a person reviews the diff before anything is uploaded.
The flow
- Supplier filesSite downloads and email attachments, every format different
- AdaptersOne per supplier: map columns, sum warehouse quantities
- ValidateMatch SKUs against the dealership system export
- Import fileStorefront-ready inventory and sell-at-zero flags
- Human reviewCheck the diff, then upload
Result
In design and early build. The goal is a refresh that runs at least weekly instead of monthly, with the manual effort moved from reformatting files to reviewing a short list of exceptions.
What I learned
The messy part is never the script, it is the unwritten rules: which supplier counts as available, which column is the real stock. Writing those rules down as adapters makes the process teachable to the next person, which matters as much as the speed.