API docs
Sous Chef Management API
Request access

List stores

POST/management/stores/fetchStores

The identity map: your storefronts, with the complete join between Sous Chef's identifiers and the delivery platform's.

Each store carries Store.id and Store.code (ours), Store.platformStoreId (the platform's own), the owning Store.brand and Store.location each with their own ids and codes, and Store.wentLiveAt.

Integrate this operation first: one call gives the complete crosswalk, and everything else in the API is addressed by identifiers it returns. Ids never change, so build your mapping on them once, at onboarding.

Narrow the result with storeIds, locationIds, brandIds and platforms; omitting them all returns your whole estate, which you page through.

Scope: storefronts at a kitchen you own, or selling a brand you own. Retired storefronts are excluded.

Store.platformStoreId and Store.storeUrl are stored values. This operation makes no live call out to a delivery platform, so it is cheap to poll, and those two fields do not follow a change made directly on a platform.

Paging: sorted by id ascending. Loop until nextCursor is absent. An estate of several thousand storefronts is normal; page, do not ask for everything at once.

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

Request

application/json
required
  • pagePageRequest

    Cursor pagination.

  • storeIdsstring[]

    Narrow to these Store.id values, the ids fetchStores itself returns.

  • locationIdsstring[]

    Narrow to storefronts at these kitchens (Location.id, as returned by fetchLocations).

  • brandIdsstring[]

    Narrow to storefronts selling these brands (Brand.id, as returned by fetchBrands).

  • platformsstring[]

    Narrow to these platform slugs, e.g. ["doordash", "ubereats"].

    Matched case- and punctuation-insensitively against the platform name, so "doordash", "DoorDash" and "Door Dash" all select the same platform. The same open enum as Store.platform: a slug we do not recognise matches nothing and is not an error.

Responses

200: One page of your storefronts with their Sous Chef and platform identifiers, and the cursor for the next page.

Headers

  • x-mealco-tx-idstringoptional

    The correlation id for this call, returned on every response that an operation produces, successful or not. Quote it when you report a problem so that we can trace the request. You may send your own x-mealco-tx-id on the request and it is used as the id. It is optional in the schema because a request with a malformed JSON body is rejected before an id is assigned, so that one response carries neither this header nor the txId field of the error body.

  • storesStore[]

    The page of storefronts, sorted by id ascending.

  • nextCursorstring

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

About Stores

The places you operate and the brands you operate there.

Sous Chef models a restaurant business in three layers, and every other section of this API assumes them. A brand is a menu concept: what a customer sees on a delivery app. A location is a physical address with a kitchen in it. A store is one storefront: a single brand, at a single location, on a single platform. A location running two brands on three platforms has six stores, each with its own menu, hours and pause state.

The directory reads join on ids, never on display names: every store carries its location.id and brand.id, and a location carries the id of each brand it runs.

Start here. A location carries the timezone that every schedule, report window and business day elsewhere on this API is interpreted in.

Every operation is scoped to the organization your API key resolves to, and nothing here calls out to a delivery platform live. The directory reads (fetchLocations, fetchBrands, fetchStores, fetchStore, fetchStoreHours, fetchStoreMenus) never mutate; setLocationHours and setLocationSpecialHours write a location you own.

Whether a storefront is currently taking orders is not in this section. fetchStoreStatuses, pauseStores, unpauseStores and the store.status.changed webhook are in the Store status section. This section describes what you operate. That one describes whether it is open right now, and whether the platform agrees.