API referenceCollection slots

Collection slots

3 operations. Every schema and example on this page is generated from the platform contract.

List the store’s upcoming materialised collection slots.

The REAL upcoming slots (reflecting recurrence + exceptions) for the Business "manage upcoming slots" surface. Read-only. Cancelling an occurrence is DELETE /api/v1/collection-windows.

Parameters

store_idstring · uuidqueryrequired

Store whose upcoming slots to list (also authorises the merchant).

daysintegerqueryoptional

Horizon in days (default 14). The server shows at least the store’s full book-ahead window.

fromstringqueryoptional

Store-local YYYY-MM-DD start of the window. Default: today.

tostringqueryoptional

Store-local YYYY-MM-DD end of the window (inclusive). Default: from + the horizon. Span clamped to 180 days.

include_plannedenumqueryoptional

Pass 'true' to merge in what the store's RULES would produce beyond the release horizon (origin='planned') plus occurrences the merchant closed (origin='cancelled'), and to fill in rule_max_orders/overridden on every row. Planned rows are never bookable. Default: materialised only.

truefalse

Response, 200

slotsarray of objectrequired
13 child fields
slot_datestringrequired

YYYY-MM-DD.

start_timestringrequired

HH:MM.

end_timestringrequired

HH:MM.

bookedbooleanrequired

Has at least one order → cannot be cancelled.

closed_daybooleanrequired

Day is hidden from customers (closing date-override OR a Closed/collect-off weekday).

booked_countintegeroptional

Orders already holding a place in this slot. Real for capped AND uncapped slots.

max_ordersinteger, nullableoptional

The slot’s capacity, or null when the store runs this slot uncapped.

orders_remaininginteger, nullableoptional

Places still free, or null when uncapped (no meaningful remainder).

originenumoptional

'materialised' = a real, released slot. 'planned' = the store's rules WOULD produce it but the book-ahead horizon has not reached it, NOT bookable, it has no row. 'cancelled' = the merchant closed this one occurrence (present so the close can be undone).

materialisedplannedcancelled
bookablebooleanoptional

Real, released, open, not full, not a closed day. The one flag a merchant surface renders on.

pausedbooleanoptional

Merchant stopped NEW orders for this occurrence. Orders already in it are untouched.

rule_max_ordersinteger, nullableoptional

What the merchant’s RULE alone gives this slot ("usually 5"), so a per-slot override reads as a difference. null = the rule is uncapped. Only sent when include_planned=true.

overriddenbooleanoptional

This occurrence carries a per-slot override, i.e. there is something for "back to normal" to undo. Only sent when include_planned=true.

curl -G "https://www.membber.com/api/v1/collection-slots" \
  -H "Authorization: Bearer $MEMBBER_TOKEN" \
  --data-urlencode "store_id=6659c139-0000-4000-8000-d0c500000066"
Response, 200
{
  "slots": [
    {
      "slot_date": "<slot_date>",
      "start_time": "<start_time>",
      "end_time": "<end_time>",
      "booked": true,
      "closed_day": true,
      "booked_count": 1,
      "max_orders": -9007199254740991,
      "orders_remaining": -9007199254740991,
      "origin": "materialised",
      "bookable": true,
      "paused": true,
      "rule_max_orders": -9007199254740991,
      "overridden": true
    }
  ]
}

Back to normal, drop a slot’s per-slot override so it follows the rule again.

The undo for setCollectionSlotOverride: removes the per-occurrence capacity/pause override and re-syncs the materialised slot to the rule. Never refuses, removing a constraint is always allowed, so when the rule’s cap sits below what is already booked the remainder clamps to 0 rather than blocking the undo. Idempotent. Inputs are supplied as query parameters.

Parameters

store_idstring · uuidqueryrequired

Store that owns the occurrence (also authorises the merchant).

slot_datestringqueryrequired

YYYY-MM-DD of the occurrence.

start_timestringqueryrequired

HH:MM start time of the occurrence.

Response, 200

occurrenceobjectrequired

The state of ONE collection occurrence after a write, enough to reconcile the row in place.

9 child fields
slot_datestringrequired

YYYY-MM-DD.

start_timestringrequired

HH:MM.

end_timestring, nullablerequired

HH:MM, or null when the occurrence has no rule to take it from.

max_ordersinteger, nullablerequired

Effective capacity for this occurrence; null = uncapped.

rule_max_ordersinteger, nullablerequired

What the merchant’s rule alone gives it; null = the rule is uncapped.

pausedbooleanrequired

false = taking new orders.

booked_countintegerrequired

Orders already in it. REAL, never derived from a cap.

overriddenbooleanrequired

Is there anything for "back to normal" to undo?

materialisedbooleanrequired

Has the occurrence been released as a real, bookable row yet?

clearedbooleanrequired

true when an override existed and was removed; false = nothing to undo (not an error).

curl -X DELETE "https://www.membber.com/api/v1/collection-slots/override?store_id=6659c139-0000-4000-8000-d0c500000066&slot_date=%3Cslot_date%3E&start_time=%3Cstart_time%3E" \
  -H "Authorization: Bearer $MEMBBER_TOKEN" \
  -H "Idempotency-Key: 1f0e2d3c-4b5a-4678-9abc-def012345678"
Response, 200
{
  "occurrence": {
    "slot_date": "<slot_date>",
    "start_time": "<start_time>",
    "end_time": "<end_time>",
    "max_orders": -9007199254740991,
    "rule_max_orders": -9007199254740991,
    "paused": true,
    "booked_count": 1,
    "overridden": true,
    "materialised": true
  },
  "cleared": true
}

Customise ONE collection slot: its capacity and/or whether it takes new orders.

Writes a durable per-occurrence override (store_collection_slot_overrides) that the slot generator re-applies every time slots are materialised, so it SURVIVES resync_collection_slots, which deletes and regenerates unbooked slots whenever any rule is edited. Pausing stops NEW orders only; orders already in the slot are untouched and the booking RPC answers a paused slot with its own code. Refuses with 409 SLOT_CAPACITY_BELOW_BOOKED (carrying the real booked count) rather than clamping when the new capacity is below what is already booked. Idempotent (last write wins on one row).

Request body

store_idstring · uuidrequired

Store that owns the occurrence (also authorises the merchant).

slot_datestringrequired

YYYY-MM-DD of the occurrence.

start_timestringrequired

HH:MM start time of the occurrence.

capacity_modeenumoptional

How this ONE occurrence's capacity behaves. 'inherit' = follow the rule again, 'unlimited' = take any number, 'fixed' = hold exactly max_orders. OMIT to leave the capacity exactly as it is.

inheritunlimitedfixed
max_ordersinteger, nullableoptional

Required when capacity_mode='fixed'. At least 1, 0 is not a capacity; to stop new orders, pause.

pausedboolean, nullableoptional

true = take no NEW orders (existing ones are untouched). OMIT to leave this facet as it is.

Response, 200

occurrenceobjectrequired

The state of ONE collection occurrence after a write, enough to reconcile the row in place.

9 child fields
slot_datestringrequired

YYYY-MM-DD.

start_timestringrequired

HH:MM.

end_timestring, nullablerequired

HH:MM, or null when the occurrence has no rule to take it from.

max_ordersinteger, nullablerequired

Effective capacity for this occurrence; null = uncapped.

rule_max_ordersinteger, nullablerequired

What the merchant’s rule alone gives it; null = the rule is uncapped.

pausedbooleanrequired

false = taking new orders.

booked_countintegerrequired

Orders already in it. REAL, never derived from a cap.

overriddenbooleanrequired

Is there anything for "back to normal" to undo?

materialisedbooleanrequired

Has the occurrence been released as a real, bookable row yet?

curl -X PUT "https://www.membber.com/api/v1/collection-slots/override" \
  -H "Authorization: Bearer $MEMBBER_TOKEN" \
  -H "Idempotency-Key: 1f0e2d3c-4b5a-4678-9abc-def012345678" \
  -H "Content-Type: application/json" \
  -d '{
    "store_id": "6659c139-0000-4000-8000-d0c500000066",
    "slot_date": "<slot_date>",
    "start_time": "<start_time>"
  }'
Response, 200
{
  "occurrence": {
    "slot_date": "<slot_date>",
    "start_time": "<start_time>",
    "end_time": "<end_time>",
    "max_orders": -9007199254740991,
    "rule_max_orders": -9007199254740991,
    "paused": true,
    "booked_count": 1,
    "overridden": true,
    "materialised": true
  }
}
WhatsApp
Book a Call
Start Free