Nested & Complex JSONadvanced

Multi-location Inventory JSON Example

A nested stock model that tracks the same SKU across multiple locations.

Real-world use case: Use this for warehouse systems, omnichannel fulfillment, and stock sync APIs.
1{
2 "sku": "TSHIRT-BLK-M",
3 "updatedAt": "2026-03-12T08:00:00Z",
4 "locations": [
5 {
6 "warehouseId": "wh_north_1",
7 "onHand": 84,
8 "reserved": 6,
9 "available": 78
10 },
11 {
12 "warehouseId": "wh_west_2",
13 "onHand": 41,

Where this shape shows up in production

Warehouse sync
Omnichannel inventory
Planning tools

Related examples