inventoryReservations
Requires at least one of the permissions inventory:stock_level:read or sales:sales_order:allocate.
Lists the reservations held against one stock line: which orders have set aside how much of its quantity. Needs the stock level read or the sales order allocate 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:
- GraphQL
- cURL
query InventoryReservations($inventoryId: ID!) {
inventoryReservations(inventoryId: $inventoryId) {
id
orderNumber
customerName
createdAt
expiresAt
isActive
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query InventoryReservations($inventoryId: ID!) {\n inventoryReservations(inventoryId: $inventoryId) {\n id\n orderNumber\n customerName\n createdAt\n expiresAt\n isActive\n }\n}",
"variables": {
"inventoryId": "id"
}
}
EOF
Variables:
{
"inventoryId": "id"
}
Response:
{
"data": {
"inventoryReservations": [
{
"id": "id",
"orderNumber": "string",
"customerName": "string",
"createdAt": "2025-01-15T00:00:00Z",
"expiresAt": "2025-01-15T00:00:00Z",
"isActive": true
}
]
}
}
inventoryReservations(
inventoryId: ID!
): [InventoryReservationInfo!]!
Arguments
inventoryReservations.inventoryId ● ID! non-null scalar
The ID of the inventory record.
Type
InventoryReservationInfo object
One reservation behind a stock row's reserved quantity. It is made when a sales order is confirmed, used up when the order ships, and released on cancel or expiry.