Skip to main content

stockMovement

Requires permission inventory:stock_movement:read.

Returns one stock movement: the quantity moved in or out, its warehouse and the document behind it, or null when there is none. Needs the stock movement read permission.

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

query StockMovement($id: ID!) {
stockMovement(id: $id) {
id
batchNumber
movementNumber
serialNumber
status
type
fromWarehouse {
id
code
taxRegistrationNumber
name
status
type
}
}
}

Variables:

{
"id": "id"
}

Response:

{
"data": {
"stockMovement": {
"id": "id",
"batchNumber": "string",
"movementNumber": "string",
"serialNumber": "string",
"status": "CANCELLED",
"type": "ADJUSTMENT",
"fromWarehouse": {
"id": "id",
"code": "string",
"taxRegistrationNumber": "string",
"name": "string",
"status": "ACTIVE",
"type": "string"
}
}
}
}
stockMovement(
id: ID!
): StockMovement

Arguments​

stockMovement.id ● ID! non-null scalar​

The ID of the stock movement.

Type​

StockMovement object​

A movement of stock: a receipt, issue, transfer or adjustment.