Skip to main content

InventoryItem

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 quantities
  • OUT_OF_STOCK: No available inventory
  • OVERSOLD: Ordered quantities exceed available inventory

Incoming Items

The incoming_items field shows Shipment items that haven't been closed yet, ordered by expected arrival date (earliest first).

type InventoryItem {
allocated(
buildingIds: [ID!]
locationIds: [ID!]
warehouseId: ID
): Int!
archivedAt: ISO8601DateTime
available(
buildingIds: [ID!]
warehouseId: ID
): Int!
availableToAllocate(
buildingIds: [ID!]
warehouseId: ID
): Int!
availableToMake(
buildingIds: [ID!]
): Int!
availableToSell(
buildingIds: [ID!]
warehouseId: ID
): Int!
brand: Brand @deprecated
brandId: ID @deprecated
createdAt: ISO8601DateTime!
deletedAt: ISO8601DateTime @deprecated
depth: DepthEnum!
id: ID!
incoming(
warehouseId: ID
): Int!
incomingItems: [InventoryIncoming!]
inventoryLocations(
filters: InventoryLocationFilterInput
): [ItemLocation!]
ordered(
buildingIds: [ID!]
warehouseId: ID
): Int!
physical(
buildingIds: [ID!]
locationIds: [ID!]
warehouseId: ID
): Int!
poQuantity(
buildingIds: [ID!]
): BigDecimal!
poShipped(
buildingIds: [ID!]
): BigDecimal!
poUnshipped(
buildingIds: [ID!]
): BigDecimal!
product: Product!
productId: ID!
shipmentUnlinked(
buildingIds: [ID!]
): BigDecimal!
stock(
buildingIds: [ID!]
warehouseId: ID
): Int!
totalIncoming(
buildingIds: [ID!]
): BigDecimal!
unallocated(
buildingIds: [ID!]
warehouseId: ID
): Int!
unavailable(
buildingIds: [ID!]
warehouseId: ID
): Int!
updatedAt: ISO8601DateTime!
warehouses: [InventoryWarehouse!]
}

Fields

InventoryItem.allocated ● Int! non-null scalar common

The allocated quantity of the inventory item.

InventoryItem.allocated.buildingIds ● [ID!] list scalar common
InventoryItem.allocated.locationIds ● [ID!] list scalar common

When set, returns sum of allocated at these warehouse locations.

InventoryItem.allocated.warehouseId ● ID scalar common

InventoryItem.archivedAt ● ISO8601DateTime scalar common

The "Archived At" field denotes the date and time that the inventory item was archived. If the inventory item has not been archived, this field will be null.

InventoryItem.available ● Int! non-null scalar common

The available quantity of the inventory item. Defined as the total quantity of an SKU that is available for sale. Available Inventory = Physical Inventory - Reserved

InventoryItem.available.buildingIds ● [ID!] list scalar common
InventoryItem.available.warehouseId ● ID scalar common

InventoryItem.availableToAllocate ● Int! non-null scalar common

The amount of this product that is available to allocate to a fulfillment order. Defined as unallocated stock plus available-to-make inventory.

InventoryItem.availableToAllocate.buildingIds ● [ID!] list scalar common
InventoryItem.availableToAllocate.warehouseId ● ID scalar common

InventoryItem.availableToMake ● Int! non-null scalar common

The available-to-make quantity for bundle products. Calculated as MIN(floor(component_available / qty_needed)) across all components. This value is additive to the regular available quantity.

InventoryItem.availableToMake.buildingIds ● [ID!] list scalar common

InventoryItem.availableToSell ● Int! non-null scalar common

Total units available for sale. For products with composition lines, this includes units that can be made from available component inventory; otherwise, this is the same as the regular available quantity.

InventoryItem.availableToSell.buildingIds ● [ID!] list scalar common
InventoryItem.availableToSell.warehouseId ● ID scalar common

InventoryItem.brand ● Brand deprecated object common

DEPRECATED

This field will be removed in the future. Brand is becoming a product-only attribute.

The brand that the inventory item is for.

InventoryItem.brandId ● ID deprecated scalar common

DEPRECATED

This field will be removed in the future. Brand is becoming a product-only attribute.

InventoryItem.createdAt ● ISO8601DateTime! non-null scalar common

When this inventory item was created.

InventoryItem.deletedAt ● ISO8601DateTime deprecated scalar common

DEPRECATED

Use archived_at instead. This field will be removed in the future.

When this inventory item was deleted.

InventoryItem.depth ● DepthEnum! non-null enum inventory

The depth of the inventory item.

InventoryItem.id ● ID! non-null scalar common

The ID of the inventory item.

InventoryItem.incoming ● Int! non-null scalar common

The incoming quantity of the inventory item. Calculated as the total expected quantity minus the already received quantity across active shipments.

InventoryItem.incoming.warehouseId ● ID scalar common

InventoryItem.incomingItems ● [InventoryIncoming!] list object inventory

The incoming inventory items. These items represents Shipment items that have not been closed.

InventoryItem.inventoryLocations ● [ItemLocation!] list object inventory

The locations that the inventory item is stored in.

InventoryItem.inventoryLocations.filters ● InventoryLocationFilterInput input inventory

InventoryItem.ordered ● Int! non-null scalar common

The ordered quantity of the inventory item. Defined as the total quantity of an SKU that has been ordered by customers.

InventoryItem.ordered.buildingIds ● [ID!] list scalar common
InventoryItem.ordered.warehouseId ● ID scalar common

InventoryItem.physical ● Int! non-null scalar common

The physical quantity of the inventory item. Defined as the total quantity of an SKU present in the building. Physical Inventory = Unavailable + In Stock

InventoryItem.physical.buildingIds ● [ID!] list scalar common
InventoryItem.physical.locationIds ● [ID!] list scalar common

When set, returns sum of stock_level at these warehouse locations (from inventory_locations).

InventoryItem.physical.warehouseId ● ID scalar common

InventoryItem.poQuantity ● BigDecimal! non-null scalar common

Total quantity ordered across open POs for this product

InventoryItem.poQuantity.buildingIds ● [ID!] list scalar common

InventoryItem.poShipped ● BigDecimal! non-null scalar common

Quantity on POs that already has a shipment assigned

InventoryItem.poShipped.buildingIds ● [ID!] list scalar common

InventoryItem.poUnshipped ● BigDecimal! non-null scalar common

Quantity on POs not yet assigned to any shipment

InventoryItem.poUnshipped.buildingIds ● [ID!] list scalar common

InventoryItem.product ● Product! non-null object products

The product that the inventory item is for.

InventoryItem.productId ● ID! non-null scalar common

InventoryItem.shipmentUnlinked ● BigDecimal! non-null scalar common

Quantity on shipments not linked to any PO line

InventoryItem.shipmentUnlinked.buildingIds ● [ID!] list scalar common

InventoryItem.stock ● Int! non-null scalar common

The stock quantity of the inventory item. Defined as Physical Inventory - Unavailable. In Stock is also separated into Allocated + Unallocated

InventoryItem.stock.buildingIds ● [ID!] list scalar common
InventoryItem.stock.warehouseId ● ID scalar common

InventoryItem.totalIncoming ● BigDecimal! non-null scalar common

Canonical total incoming quantity for the inventory item, combining PO shipped, PO unshipped, and unlinked shipment quantities

InventoryItem.totalIncoming.buildingIds ● [ID!] list scalar common

InventoryItem.unallocated ● Int! non-null scalar common

The unallocated quantity of the inventory item. Defined as In Stock Inventory - Allocated.

InventoryItem.unallocated.buildingIds ● [ID!] list scalar common
InventoryItem.unallocated.warehouseId ● ID scalar common

InventoryItem.unavailable ● Int! non-null scalar common

The unavailable quantity of the inventory item. Unavailable is the sum of Quarantine + Damaged units.

InventoryItem.unavailable.buildingIds ● [ID!] list scalar common
InventoryItem.unavailable.warehouseId ● ID scalar common

InventoryItem.updatedAt ● ISO8601DateTime! non-null scalar common

When this inventory item was last updated.

InventoryItem.warehouses ● [InventoryWarehouse!] list object inventory

The inventory values for each warehouse.

Returned By

initializeInventory mutation ● inventoryItem query ● inventoryQuickAdjust mutation

Member Of

ASNItem object ● InventoryItemConnection object ● InventoryItemEdge object ● ItemAllocation object ● ItemLocation object ● OrderItem object ● Product object ● SupplyOrderItem object ● TransferItem object

Implemented By

Notable union