← API reference
Mutation / logistics

upsertWarehouseStock

Create or wholesale-replace a warehouse stock record in the caller's tenant: creates one when input.id is omitted or unknown, otherwise overwrites the existing record. Emits a warehouse-stock updated event. Requires write access to warehouse stock.

Arguments

Full state of the stock record to write.

Returns WarehouseStockPayload!

Explore in a view

Fulfillment
View exact SDL
"""
Create or wholesale-replace a warehouse stock record in the caller's tenant: creates one when `input.id` is omitted or unknown, otherwise overwrites the existing record. Emits a warehouse-stock updated event. Requires write access to warehouse stock.
"""
upsertWarehouseStock(
  """Full state of the stock record to write."""
  input: UpsertWarehouseStockInput!
): WarehouseStockPayload! @topic(names: ["logistics"])

Schema reference describes the API contract. Actual access is checked by the platform for every operation.