Skip to content
Sections

API reference

Availability

Stock for the variants you sell: one answer per variant across every supplier location, and a changes feed to keep a local copy current.

Can these quantities be met, and by when

post/v1/availability/check

For each line: whether it can be met now, the shortfall, the earliest date incoming stock completes it, and which locations would supply it. Lines for the same variant share its stock. Nothing is reserved; supplier stock can change before you order.

Called by
Account client
Scope
stock:read

Request body · application/json

  • linesarray of (ByVariantIdLine | BySupplierSkuLine | ByGtinLine | ByExternalRefLine)required

    1–500 items

    Each item is one of these shapes

    ByVariantIdLine

    A Presslane Suppliers variant ID.

    • quantityintegerrequired

      ≥ 1 · ≤ 10000000

    • variant_idstringrequired

      1–100 characters

    BySupplierSkuLine

    A supplier and that supplier's SKU.

    • quantityintegerrequired

      ≥ 1 · ≤ 10000000

    • supplierstringrequired

      Supplier ID or slug.

      1–100 characters

    • supplier_skustringrequired

      1–100 characters

    ByGtinLine

    A GTIN.

    • gtinstringrequired

      A GTIN (8–14 digits); leading zeros are matched loosely.

      matches ^\d{8,14}$

    • quantityintegerrequired

      ≥ 1 · ≤ 10000000

    ByExternalRefLine

    The account's own variant reference.

    • external_refstringrequired

      The account's own variant reference, through its links.

      1–200 characters

    • quantityintegerrequired

      ≥ 1 · ≤ 10000000

  • locationstring

    1–20 characters

Responses

200The check result.Show
  • can_fulfil_nowbooleanrequired
  • fulfil_bystring (date) | nullrequired

    The date by which every line can be met, or null.

    e.g. 2026-11-21

  • linesarray of objectrequired
    Child attributes
    • allocationobjectrequired
      Child attributes
      • incomingarray of objectrequired
        Child attributes
        • expected_onstring (date)required

          e.g. 2026-11-21

        • locationstringrequired
        • quantityintegerrequired
      • nowarray of objectrequired
        Child attributes
        • locationstringrequired
        • quantityintegerrequired
    • as_ofstring (date-time)required

      e.g. 2026-11-09T08:00:00Z

    • available_nowinteger | nullrequired
    • can_fulfil_nowbooleanrequired
    • candidatesintegerrequired

      Supplier variants the identifier matched; the best is used.

    • external_refstring | nullrequired
    • fulfil_bystring (date) | nullrequired

      Today if met now; else the date incoming stock completes the line; null if it cannot.

      e.g. 2026-11-21

    • quantityintegerrequired
    • request_indexintegerrequired
    • shortfallintegerrequired

      Units not available now.

    • stalebooleanrequired
    • statusstringrequired

      in_stock at or above the low-stock threshold; low_stock above 0 and below it; out_of_stock 0 with nothing incoming; backorder 0 with incoming stock dated; discontinued ended by the supplier or feed; unknown no stock yet or data past the supplier's stale-after age (last numbers still returned, stale: true); supplier_archived the supplier left the directory; trade_account_required the supplier shows stock only to businesses with a trade account number recorded for it.

      One of in_stock, low_stock, out_of_stock, backorder, discontinued, unknown, supplier_archived, trade_account_required

    • variant_idstringrequired
  • not_foundarray of map of anyrequired
  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X POST 'https://suppliers.presslane.ai/v1/availability/check' \
  -H "Authorization: Bearer $TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{"lines":[{"quantity":1,"variant_id":"string"}]}'
Response · 200
{
  "can_fulfil_now": false,
  "fulfil_by": "2026-11-21",
  "lines": [
    {
      "allocation": {
        "incoming": [
          {
            "expected_on": "2026-11-21",
            "location": "string",
            "quantity": 1
          }
        ],
        "now": [
          {
            "location": "string",
            "quantity": 1
          }
        ]
      },
      "as_of": "2026-11-09T08:00:00Z",
      "available_now": 1,
      "can_fulfil_now": false,
      "candidates": 1,
      "external_ref": "string",
      "fulfil_by": "2026-11-21",
      "quantity": 1,
      "request_index": 1,
      "shortfall": 1,
      "stale": false,
      "status": "in_stock",
      "variant_id": "string"
    }
  ],
  "not_found": [
    {}
  ]
}
Try it in the sandbox

Availability for up to 500 variants

post/v1/availability/lookup

By any mix of variant ID, supplier + SKU, GTIN or your own variant reference (external_ref, through your links). Identifiers that match nothing come back in not_found; they never fail the request. Reserves nothing.

Called by
Account client
Scope
stock:read

Request body · application/json

  • includearray of string
  • itemsarray of (ByVariantId | BySupplierSku | ByGtin | ByExternalRef)required

    1–500 items

    Each item is one of these shapes

    ByVariantId

    A Presslane Suppliers variant ID.

    • variant_idstringrequired

      1–100 characters

    BySupplierSku

    A supplier and that supplier's SKU.

    • supplierstringrequired

      Supplier ID or slug.

      1–100 characters

    • supplier_skustringrequired

      1–100 characters

    ByGtin

    A GTIN.

    • gtinstringrequired

      A GTIN (8–14 digits); leading zeros are matched loosely.

      matches ^\d{8,14}$

    ByExternalRef

    The account's own variant reference.

    • external_refstringrequired

      The account's own variant reference, through its links.

      1–200 characters

  • locationstring

    Totals over one location code instead of all.

    1–20 characters

Responses

200Availability per matched variant.Show
  • dataarray of objectrequired
    Child attributes
    • as_ofstring (date-time)required

      The older of the supplier's timestamp and the load time across the locations used.

      e.g. 2026-11-09T08:00:00Z

    • availableinteger | nullrequired

      Null when the supplier gives a band, or quantities are withheld.

    • bandstring | nullrequired

      The supplier's band text, when banded.

    • colourstring | nullrequired
    • external_refstring | nullrequired
    • lead_time_daysinteger | nullrequired
    • locationsarray of LocationAvailability

      With include: ["locations"].

      Child attributes
      • availableinteger | nullrequired
      • bandstring | nullrequired
      • codestringrequired
      • incomingarray of Incomingrequired

        Up to the three soonest deliveries.

        Child attributes
        • expected_onstring (date)required

          e.g. 2026-11-21

        • quantityintegerrequired
      • quantity_at_leastinteger | nullrequired
    • next_incomingIncoming | nullrequired
      Child attributes
      • expected_onstring (date)required

        e.g. 2026-11-21

      • quantityintegerrequired
    • product_codestringrequired
    • product_idstringrequired
    • quantity_at_leastinteger | nullrequired

      Lower bound when stock is banded ("50+").

    • request_indexintegerrequired

      Index of the identifier in items.

    • sizestring | nullrequired
    • stalebooleanrequired
    • statusstringrequired

      in_stock at or above the low-stock threshold; low_stock above 0 and below it; out_of_stock 0 with nothing incoming; backorder 0 with incoming stock dated; discontinued ended by the supplier or feed; unknown no stock yet or data past the supplier's stale-after age (last numbers still returned, stale: true); supplier_archived the supplier left the directory; trade_account_required the supplier shows stock only to businesses with a trade account number recorded for it.

      One of in_stock, low_stock, out_of_stock, backorder, discontinued, unknown, supplier_archived, trade_account_required

    • supplierSupplierRefrequired
      Child attributes
      • idstringrequired

        e.g. sup_01jd7p…

      • slugstringrequired

        e.g. example-wholesale

    • supplier_skustringrequired
    • variant_idstringrequired
  • not_foundarray of map of anyrequired

    The identifiers that matched nothing, with request_index.

  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X POST 'https://suppliers.presslane.ai/v1/availability/lookup' \
  -H "Authorization: Bearer $TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{"items":[{"variant_id":"string"}]}'
Response · 200
{
  "data": [
    {
      "as_of": "2026-11-09T08:00:00Z",
      "available": 1,
      "band": "string",
      "colour": "string",
      "external_ref": "string",
      "lead_time_days": 1,
      "next_incoming": {
        "expected_on": "2026-11-21",
        "quantity": 1
      },
      "product_code": "string",
      "product_id": "string",
      "quantity_at_least": 1,
      "request_index": 1,
      "size": "string",
      "stale": false,
      "status": "in_stock",
      "supplier": {
        "id": "sup_01jd7p…",
        "slug": "example-wholesale"
      },
      "supplier_sku": "string",
      "variant_id": "string"
    }
  ],
  "not_found": [
    {}
  ]
}
Try it in the sandbox

Colour by size availability grid

get/v1/products/{id}/availability

Every variant of the product, with totals per colour, per size and overall.

Called by
Account client
Scope
stock:read

Path parameters

  • idstringrequired

    at most 100 characters

Query parameters

  • includestring

    One of locations

  • locationstring

    1–20 characters

Responses

200The grid.Show
  • as_ofstring (date-time) | nullrequired

    e.g. 2026-11-09T08:00:00Z

  • cellsarray of objectrequired
    Child attributes
    • as_ofstring (date-time)required

      The older of the supplier's timestamp and the load time across the locations used.

      e.g. 2026-11-09T08:00:00Z

    • availableinteger | nullrequired

      Null when the supplier gives a band, or quantities are withheld.

    • bandstring | nullrequired

      The supplier's band text, when banded.

    • colourstring | nullrequired
    • colour_codestring | nullrequired
    • lead_time_daysinteger | nullrequired
    • locationsarray of LocationAvailability

      With include: ["locations"].

      Child attributes
      • availableinteger | nullrequired
      • bandstring | nullrequired
      • codestringrequired
      • incomingarray of Incomingrequired

        Up to the three soonest deliveries.

        Child attributes
        • expected_onstring (date)required

          e.g. 2026-11-21

        • quantityintegerrequired
      • quantity_at_leastinteger | nullrequired
    • next_incomingIncoming | nullrequired
      Child attributes
      • expected_onstring (date)required

        e.g. 2026-11-21

      • quantityintegerrequired
    • optionsmap of stringrequired
    • product_codestringrequired
    • product_idstringrequired
    • quantity_at_leastinteger | nullrequired

      Lower bound when stock is banded ("50+").

    • sizestring | nullrequired
    • size_codestring | nullrequired
    • stalebooleanrequired
    • statusstringrequired

      in_stock at or above the low-stock threshold; low_stock above 0 and below it; out_of_stock 0 with nothing incoming; backorder 0 with incoming stock dated; discontinued ended by the supplier or feed; unknown no stock yet or data past the supplier's stale-after age (last numbers still returned, stale: true); supplier_archived the supplier left the directory; trade_account_required the supplier shows stock only to businesses with a trade account number recorded for it.

      One of in_stock, low_stock, out_of_stock, backorder, discontinued, unknown, supplier_archived, trade_account_required

    • supplierSupplierRefrequired
      Child attributes
      • idstringrequired

        e.g. sup_01jd7p…

      • slugstringrequired

        e.g. example-wholesale

    • supplier_skustringrequired
    • variant_idstringrequired
  • coloursarray of objectrequired
    Child attributes
    • colourstring | nullrequired
    • colour_codestring | nullrequired
    • totalStockTotalrequired
      Child attributes
      • availableinteger | nullrequired
      • quantity_at_leastinteger | nullrequired
  • productobjectrequired
    Child attributes
    • brandstring | nullrequired
    • idstringrequired
    • namestringrequired
    • product_codestringrequired
    • supplierSupplierRefrequired
      Child attributes
      • idstringrequired

        e.g. sup_01jd7p…

      • slugstringrequired

        e.g. example-wholesale

  • sizesarray of objectrequired
    Child attributes
    • sizestring | nullrequired
    • size_codestring | nullrequired
    • totalStockTotalrequired
      Child attributes
      • availableinteger | nullrequired
      • quantity_at_leastinteger | nullrequired
  • stalebooleanrequired
  • totalStockTotalrequired
    Child attributes
    • availableinteger | nullrequired
    • quantity_at_leastinteger | nullrequired
  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 404Not found (not_found).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X GET 'https://suppliers.presslane.ai/v1/products/{id}/availability' \
  -H "Authorization: Bearer $TOKEN"
Response · 200
{
  "as_of": "2026-11-09T08:00:00Z",
  "cells": [
    {
      "as_of": "2026-11-09T08:00:00Z",
      "available": 1,
      "band": "string",
      "colour": "string",
      "colour_code": "string",
      "lead_time_days": 1,
      "next_incoming": {
        "expected_on": "2026-11-21",
        "quantity": 1
      },
      "options": {},
      "product_code": "string",
      "product_id": "string",
      "quantity_at_least": 1,
      "size": "string",
      "size_code": "string",
      "stale": false,
      "status": "in_stock",
      "supplier": {
        "id": "sup_01jd7p…",
        "slug": "example-wholesale"
      },
      "supplier_sku": "string",
      "variant_id": "string"
    }
  ],
  "colours": [
    {
      "colour": "string",
      "colour_code": "string",
      "total": {
        "available": 1,
        "quantity_at_least": 1
      }
    }
  ],
  "product": {
    "brand": "string",
    "id": "string",
    "name": "string",
    "product_code": "string",
    "supplier": {
      "id": "sup_01jd7p…",
      "slug": "example-wholesale"
    }
  },
  "sizes": [
    {
      "size": "string",
      "size_code": "string",
      "total": {
        "available": 1,
        "quantity_at_least": 1
      }
    }
  ],
  "stale": false,
  "total": {
    "available": 1,
    "quantity_at_least": 1
  }
}
Try it in the sandbox

Changes to linked variants since a cursor

get/v1/stock/changes

Up to 500 changes, oldest first, each with your external_ref. Start from the changes_cursor in a stock.changed event or the next_cursor of the previous page. More than 30 days behind: 410 cursor_expired; re-read all links instead.

Called by
Account client
Scope
stock:read

Query parameters

  • cursorstring

    From a stock event or the previous page. Omit to start 30 days back.

    at most 40 characters

  • limitinteger

    ≥ 1 · ≤ 500

Responses

200A page of changes.Show
  • dataarray of objectrequired
    Child attributes
    • changed_atstring (date-time)required

      e.g. 2026-11-09T08:00:00Z

    • cursorstringrequired
    • external_refstringrequired
    • newobjectrequired
      Child attributes
      • availableinteger | nullrequired
      • quantity_at_leastinteger | nullrequired
      • statusstring | nullrequired
    • oldobjectrequired
      Child attributes
      • availableinteger | nullrequired
      • quantity_at_leastinteger | nullrequired
      • statusstring | nullrequired
    • run_idstringrequired
    • supplier_idstringrequired
    • variant_idstringrequired
  • has_morebooleanrequired
  • next_cursorstringrequired

    Store it and poll from it next time.

  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 410The changes cursor is older than 30 days (cursor_expired).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X GET 'https://suppliers.presslane.ai/v1/stock/changes' \
  -H "Authorization: Bearer $TOKEN"
Response · 200
{
  "data": [
    {
      "changed_at": "2026-11-09T08:00:00Z",
      "cursor": "string",
      "external_ref": "string",
      "new": {
        "available": 1,
        "quantity_at_least": 1,
        "status": "string"
      },
      "old": {
        "available": 1,
        "quantity_at_least": 1,
        "status": "string"
      },
      "run_id": "string",
      "supplier_id": "string",
      "variant_id": "string"
    }
  ],
  "has_more": false,
  "next_cursor": "string"
}
Try it in the sandbox