Skip to main content

ServiceStockResponse

successbooleanrequired

Always true on a 2xx response.

Example: true
data object[]required

Stock for each variant in each warehouse that holds it.

  • Array [
  • variantIdstring<uuid>required

    Variant id.

    Example: 5b0c8a6e-2f4d-4d6e-9a53-7c1d2e3f4a5b
    warehouseIdstring<uuid>nullablerequired

    Warehouse id.

    Example: 9d2f6b1c-8e47-4a30-b5c2-0e1f3a4b5c6d
    warehouseNamestringnullablerequired

    Warehouse name.

    Example: Main warehouse
    onHandQuantitynumbernullablerequired

    Quantity physically on hand.

    Example: 120
    reservedQuantitynumbernullablerequired

    Quantity held for open orders.

    Example: 20
    availableQuantitynumbernullablerequired

    Quantity available to sell: on hand minus reserved.

    Example: 100
    trackedbooleannullablerequired

    False when the variant does not track inventory.

    Example: true
  • ]
  • unknownVariantIdsstring<uuid>[]required

    Requested variant ids that do not exist in this workspace. They are not reported as zero stock.

    Example: []
    ServiceStockResponse
    {
    "success": true,
    "data": [
    {
    "variantId": "5b0c8a6e-2f4d-4d6e-9a53-7c1d2e3f4a5b",
    "warehouseId": "9d2f6b1c-8e47-4a30-b5c2-0e1f3a4b5c6d",
    "warehouseName": "Main warehouse",
    "onHandQuantity": 120,
    "reservedQuantity": 20,
    "availableQuantity": 100,
    "tracked": true
    }
    ],
    "unknownVariantIds": []
    }