Skip to main content

Query warehouse availabilities

note

The warehouse code in the example is a placeholder — use a real warehouse code from your context.

Use findWarehouse query to retrieve the product and bundle availabilities of a warehouse by code (or warehouse by id). Each availability row carries the on-hand, reserved and available quantities and the time the on-hand quantity was last updated.

findWarehouse returns null when no warehouse matches the code, and fails with a MULTIPLE_RECORD_FOUND error when more than one does (see Errors).

products and bundles are paginated connections: on a real catalog walk the pages with first and after (see Pagination). Availability queries cost significant query complexity points, so budget your polling accordingly.

Response
{
  "data": {
    "findWarehouse": {
      "id": "12",
      "codes": ["MIL"],
      "city": "Milano",
      "products": {
        "totalCount": 1,
        "pageInfo": {
          "hasNextPage": false,
          "endCursor": "WzUwMV0"
        },
        "nodes": [
          {
            "id": "501",
            "sku": "SKU-1",
            "skuDescription": "Demo product",
            "brand": {
              "id": "31",
              "code": "BRAND_CODE"
            },
            "availabilities": [
              {
                "id": "8001",
                "availableQuantity": 11,
                "onHandQuantity": 12,
                "onHandQuantityUpdatedAt": "2026-07-22T09:30:00Z",
                "reservedQuantity": 1
              }
            ]
          }
        ]
      },
      "bundles": {
        "totalCount": 1,
        "pageInfo": {
          "hasNextPage": false,
          "endCursor": "WzYwMV0"
        },
        "nodes": [
          {
            "id": "601",
            "sku": "BUNDLE-1",
            "brand": {
              "id": "31",
              "code": "BRAND_CODE"
            },
            "availabilities": [
              {
                "id": "9001",
                "availableQuantity": 3,
                "onHandQuantity": 5,
                "onHandQuantityUpdatedAt": "2026-07-22T09:30:00Z",
                "reservedQuantity": 2
              }
            ]
          }
        ]
      }
    }
  },
  "extensions": {
    "queryComplexity": 476,
    "bucketBalance": 9524,
    "bucketRestoreRate": 100
  }
}

Relevant permissions

The operations in this page require the following permissions on the API credentials — they are configured for you by Calicantus.

  • warehouse:query:find_warehouse
  • warehouse:read
  • product:read
  • bundle:read
  • brand:read