Skip to main content

WarehouseStock

Per-warehouse aggregate stock line for a product. One line per (product, warehouse) tuple, maintained by Pickware as a denormalised sum of the matching per-bin Stock lines. Use this when you want "how much of this product lives in warehouse X" without scanning per-bin lines.

type WarehouseStock implements Node {
id: ID!
createdAt: DateTime!
productId: ID!
quantity: Int!
updatedAt: DateTime
warehouseId: ID
product: Product
productWarehouseConfiguration: ProductWarehouseConfiguration
warehouse: Warehouse
}

Fields​

WarehouseStock.id ● ID! non-null scalar​

Global identifier for this entity.

WarehouseStock.createdAt ● DateTime! non-null scalar​

Timestamp the warehouse stock line was first persisted.

WarehouseStock.productId ● ID! non-null scalar​

ID of the product.

WarehouseStock.quantity ● Int! non-null scalar​

Number of units of the product present in the warehouse, summed across every bin location in it.

WarehouseStock.updatedAt ● DateTime scalar​

Timestamp of the last quantity change.

WarehouseStock.warehouseId ● ID scalar​

ID of the warehouse.

WarehouseStock.product ● Product object​

WarehouseStock.productWarehouseConfiguration ● ProductWarehouseConfiguration object​

WarehouseStock.warehouse ● Warehouse object​

Interfaces​

Node interface​

Any entity that can be loaded by its global id through the node(id: ID!) query.

Returned By​

adjustStockAtWarehouse mutation ● setStockAtWarehouse mutation ● warehouseStock query

Member Of​

ProductWarehouseConfiguration object ● WarehouseStockEdge object