Entities and cadence¶
FG.AI WMS imports three classes of entity through this contract. Each has a different shape, a different cadence, and a different consequence of arriving late or wrong.
Master data¶
Master data describes the stable structural facts about a warehouse operation: what a SKU is, what units of measure it ships in, what a bin is, where parties (customers, suppliers, carriers) are located. It changes slowly and is referenced by every document and movement.
Endpoint |
What it carries |
|---|---|
|
Units of measure (EA, KG, M, L, custom). |
|
SKU catalog with descriptions, base UoM, lot/serial-tracking flags, hazmat class, temperature-controlled class. |
|
Bills of materials for assembled / kitted / refurbished SKUs. |
|
Warehouse / zone / bin hierarchy ( |
|
Postal addresses for warehouses, customers, suppliers, and carriers. |
|
Lot registrations for lot-tracked SKUs. |
|
Serial registrations for serial-tracked SKUs. |
Cadence: sync at onboarding (typically via ?mode=bulk), then push every change as it happens (?mode=upsert). Steady-state volume is tiny — typically dozens to hundreds of upserts per day per warehouse.
Consequences of arriving late or wrong: documents and inventory referencing missing master data are quarantined (see Normalization and quarantine). The most common rollout mistake is pushing documents before the master data that they depend on.
Documents¶
Documents are the events that drive work in a warehouse: purchase orders, sales orders, receivers, shippers, work orders, transfer orders. They have a lifecycle (open → released → in-progress → closed) and a fixed identity over that lifecycle.
Endpoint |
Document type |
|---|---|
|
Purchase Order ( |
|
Sales Order ( |
|
Receiver — expected inbound from a PO or ASN. |
|
Shipper — outbound shipment. |
|
Work Order — production, assembly, refurbish. |
|
Transfer Order — inter-warehouse movement. |
|
Cancel a document. |
See WMS ADR-0008 for the generic MES vocabulary the document types share with WorkOrder semantics — this lets the same data model grow into manufacturing later without rename or migration.
Cadence: per-event. Push to FG.AI as the upstream creates or updates each document. A single warehouse may produce hundreds to low-thousands of document events per day.
Consequences of arriving late or wrong: a missing document is work the FG.AI planner cannot schedule. A document with bad master-data references is quarantined and surfaces in a supervisor queue rather than failing silently.
Inventory¶
Inventory is the truth state of what is on hand: quantities per (warehouse, sku, location) with optional lot or serial qualifiers.
Endpoint |
What it carries |
|---|---|
|
Full or partial point-in-time snapshot. |
|
Delta movements between snapshots. |
Cadence:
At onboarding cutover — one full snapshot per warehouse marks the baseline FG.AI takes over. Send
scope=FULLafter a clean operational cutoff (e.g. end of last shift before go-live).During overlap — if the upstream WMS keeps running for a transition period, push deltas via
/inventory/movementsso FG.AI’s view stays in sync. Tag each movement withcorrelation_idfor idempotency.After FG.AI is authoritative — inventory writes flow through FG.AI WES → FG.AI WMS, not through this contract. The upstream stops pushing inventory. It may continue receiving
inventory.adjustedwebhooks if it wants to mirror FG.AI’s state back into its own system.
Consequences of arriving late or wrong: the FG.AI planner schedules against the wrong stock position. This is the worst class of integration bug because it manifests as physical short-picks on the floor. Always verify the cutover snapshot is correct before flipping FG.AI to authoritative.
Cadence summary¶
Onboarding ──► bulk master ──► bulk inventory snapshot ──► open documents
│
▼
Steady-state ──► trickle upserts (master + documents) ──► FG.AI planner active
│
▼
Overlap (optional) ──► inventory deltas during transition
│
▼
Post-cutover ──► FG.AI authoritative; only document upserts continue;
inventory writes flow through FG.AI WES
Identity convention¶
Every entity carries a partner-supplied source_id — the upstream’s natural key. On first acceptance, FG.AI assigns a stable internal_id. Subsequent upserts with the same (partner_id, source_id) mutate the same FG.AI entity. See Identity mapping for the full rules.