initializeInventory
Initialize inventory for a product at a location. This mutation should be used when a product is first added to a location, and it can be used only once for every product that is wanted to be initialized in the inventory. If the product is already initialized, this mutation will return an error.
initializeInventory(
input: InitializeInventoryInput!
): InventoryItem!
Arguments
initializeInventory.input ● InitializeInventoryInput! non-null input
Parameters for InitializeInventory
Type
InventoryItem object
Represents an inventory item that tracks stock quantities and locations for a specific product within a brand's warehouses.
Inventory Calculations
The inventory system uses a hierarchical structure where:
- **Physical** = Total units present in the building
- **Available** = Physical - Reserved (units available for sale)
- **Stock** = Physical - Unavailable (usable inventory)
- **Allocated** = Units assigned to specific orders
Warehouse Filtering
Most quantity fields accept an optional warehouse_id argument to get
inventory levels for a specific warehouse. When omitted, returns totals
across all active warehouses.
Depth Status
The depth field indicates stock availability:
FULL_STOCK: Available inventory exceeds ordered quantitiesOUT_OF_STOCK: No available inventoryOVERSOLD: Ordered quantities exceed available inventory
Incoming Items
The incoming_items field shows ASN (Advanced Shipping Notice) items
that haven't been closed yet, ordered by expected arrival date
(earliest first).