Orders & fulfilment
Marketplace Order Aggregation
Indicative price, not an offer: €64/mo; supports 5 marketplaces, order sync, inventory sync
Generated from docs/plan/paid/marketplace-order-aggregation/PLAN.md in the AstroBaaS repository. Nothing described below is implemented — it is the written plan for it.
A multi-marketplace order aggregation system that syncs orders from Amazon, eBay, and Facebook into one AstroCMS dashboard, with order de-duplication and centralized fulfillment.
The problem
Sell on Amazon, eBay, Facebook; merchants need a central dashboard for all orders without manual duplication.
What it does
- Connect to Amazon Seller Central, eBay, Facebook Shop via OAuth
- Sync orders from all marketplaces into one AstroCMS dashboard
- Sync inventory levels (reduce inventory when marketplace order is placed)
- Fulfill orders across marketplaces (print labels, update status)
- Centralized order search and filtering
- De-duplicate orders (same customer, same items, across platforms)
- Webhook updates: auto-sync new orders, status changes
What it deliberately does NOT do
Each boundary carries its reason. A boundary without a reason gets crossed by the next person who reads this.
- Marketplace-specific features (e.g., Amazon A+ content, eBay store design) — not included. Reason: vendor-specific.
- Listing synchronization — we don’t sync product listings back to marketplaces. Reason: complex inventory mapping.
- Marketplace analytics — we don’t display marketplace-specific metrics. Reason: paid feature.
Data model
New tables: MarketplaceAccount {id, merchantId, platform (‘amazon’|‘ebay’|‘facebook’), accountId, accessToken (encrypted), isActive}; MarketplaceOrder {id, orderId (local), externalOrderId (platform-specific), platform, syncedAt, status}. No migration.
API
- POST /api/marketplaces/connect
- GET /api/marketplaces/accounts
- POST /api/marketplaces/sync
- GET /api/marketplaces/orders
Every route added here must also appear in src/pages/openapi.json.ts — a test
fails the build if it does not.
Admin
Marketplace connection page: connect Amazon/eBay/Facebook. Unified order dashboard: show orders from all platforms in one list. Fulfillment: create shipment across platform (generates labels, updates status on all platforms).
The seam — why this is paid
Core owns: order aggregation interface, unified dashboard. Paid owns: marketplace OAuth, order/inventory sync, platform-specific error handling.
Support commitment: marketplace API maintenance, order deduplication, SLA
Dependencies
- Order infrastructure
- Inventory management (if available)
- Webhook system (to receive marketplace updates)
Acceptance checks
Each of these must be able to fail. Before claiming this is done, break the code deliberately and watch each one go red.
- Connecting Amazon account via OAuth adds MarketplaceAccount; token is stored encrypted
- Syncing orders fetches all orders from Amazon API and creates local Order records
- De-duplication: if same order appears on Amazon and Facebook, only one Order is created with two MarketplaceOrder references
- Inventory sync: when marketplace order is placed, local inventory is decremented
- Fulfillment: marking order as shipped updates status on both Amazon and Facebook via API
Risks
Token expiry: OAuth token expires; refreshing fails; mitigation: refresh token logic, alert merchant if refresh fails. Out-of-sync inventory: inventory mismatch between AstroCMS and marketplace; mitigation: periodic full sync (e.g., 1x per hour).
Commercial context
| Suggested price | €64/mo; supports 5 marketplaces, order sync, inventory sync |
| Rival anchor | Zentail: €200-1000/mo; SellerActive: €99-1000/mo; custom: €5000+ |
The anchor is what the nearest equivalent charges on Shopify or Magento today. It is context for a pricing decision, not the decision.
Generated from the commerce plan. See docs/COMMERCE-PLAN.md for the full
catalogue and ../../AI-GUIDE.md for how to work on this repository.