OneTablet API Documentation

List items at a location

POST/management/item-availability/fetchLocationItems

The item catalogue at one location — every item and modifier option this organization sells there, with OneTablet's item ids and current availability. The discovery read setItemAvailability depends on.

Scope: items whose brand this organization owns, at a location this organization owns or operates a brand out of. An unknown or foreign locationId is NotFound.

Safe to retry: this operation is read-only and idempotent.

Request

application/json
required
  • locationIdstring

    The location (kitchen) whose catalogue you want — the id from StoresApi.fetchLocations. Required; absent is 400. A location that does not exist and one outside your organization's scope are the same 404.

  • querystring

    Case-insensitive name search.

  • availableboolean

    Filter to items currently available (or unavailable) at the location.

  • pagePageRequest

    Cursor pagination.

Responses

200 — One page of the location's items with their current availability, and the cursor for the next page.

Headers

  • x-mealco-tx-idstringoptional

    The correlation id for this call, echoed on every response — a 200 exactly as much as a 400, 401 or 500. Quote it when reporting a problem and we can find every log line for the request, in every service it touched. You may also send your own x-mealco-tx-id on the request and we adopt it, so your correlation id becomes ours. Not marked required for one reason: a request whose JSON body is malformed is rejected before it reaches an operation, so no id exists yet and that single response carries neither this header nor the txId field of the error body. Everything that reaches an operation carries it.

  • asOfstring<date-time>

    When this response was assembled — UTC, ISO-8601. The availability values are read live at that moment; this is the freshness claim for the whole response.

  • itemsItemAvailability[]

    The page of items tracked at the location, sorted by name, restricted to items of brands your organization owns. Empty when nothing matches.

  • nextCursorstring

    Opaque cursor for the next page. Absent means the last page.

About Item availability

Item availability ("86-ing") — mark one item available or unavailable at one kitchen.

fetchLocationItems and setItemAvailability work as a pair: the write needs the discovery read, because OneTablet's item ids cannot be known in advance.

There is no Idempotency-Key replay on this API: a retried setItemAvailability call re-applies the same value rather than de-duplicating.