Platform
Store-First Order Sync
Live store inventory is the source of truth. Stock is claimed before anything is written locally.
Webhook- Shopify GraphQL
- TypeScript
- PostgreSQL
- Source of truth
- The store
Read the steps as a list
- trigger Agent places order
- integration Claim stock in store · Shopify
- condition Claim succeeded?
- action Write local order
- condition Local write ok?
- output Order confirmed
- action Compensate store claim
Releases the reserved stock so it cannot leak.
- output Out of stock
No local record is created, so there is nothing to reconcile.
The problem
Writing the order locally first and syncing later oversells. Two customers buy the last item and one of them finds out days afterwards.
How it works
An order claims inventory in the connected store before a local record exists, with automatic fallback and compensation when the store call fails.
The outcome
The store commits first. If it refuses, no local order exists to clean up; if the local write then fails, the store claim is compensated. The same interface is designed for WooCommerce and Salla, though only Shopify is built.