Availability
5 API calls in this section.
Set Location State
/restaurant/locations/:locationId/stateToggles operational state for a location. When is_manual_mode=true, manual_is_open controls open/closed regardless of schedules.
Path parameters
| Parameter | Type | Description |
|---|---|---|
locationIdRequired | string | Dynamic path value from the request URL. |
Headers
| Parameter | Type | Description |
|---|---|---|
Authorization | string | Example: |
Body parameters
| Parameter | Type | Description |
|---|---|---|
is_manual_mode | boolean | — |
manual_is_open | boolean | — |
1curl --globoff --request POST "https://staging-api.ondi.io/functions/v1/restaurant/locations/${LOCATIONID}/state" \2 --header "Authorization: Bearer ${ONDI_ACCESS_TOKEN}" \3 --header "Content-Type: application/json" \4 --data-raw '{5 "is_manual_mode": true,6 "manual_is_open": false7}'Response examples
1{2 "success": true,3 "data": {4 "id": "{{locationId}}",5 "is_manual_mode": true,6 "manual_is_open": false,7 "availability_version": 428 }9}Set Menu State
/restaurant/menus/:menuId/stateSet a menu to automatic (schedule-driven) or manual (manual_is_active=true/false). Bumps location availability_version by trigger.
Path parameters
| Parameter | Type | Description |
|---|---|---|
menuIdRequired | string | Dynamic path value from the request URL. |
Headers
| Parameter | Type | Description |
|---|---|---|
Authorization | string | Example: |
Body parameters
| Parameter | Type | Description |
|---|---|---|
activation_mode | string | — |
manual_is_active | boolean | — |
Response examples
1{2 "success": true,3 "data": {4 "id": "{{menuId}}",5 "location_id": "{{locationId}}",6 "activation_mode": "manual",7 "manual_is_active": true8 }9}List Active Menus
/restaurant/locations/:locationId/menus/activeReturns menus active 'now' in the location time zone. Manual active menus are included.
Path parameters
| Parameter | Type | Description |
|---|---|---|
locationIdRequired | string | Dynamic path value from the request URL. |
Headers
| Parameter | Type | Description |
|---|---|---|
Authorization | string | Example: |
Response examples
1{2 "success": true,3 "data": [4 {5 "id": "{{menuId}}",6 "location_id": "{{locationId}}",7 "name": {8 "en": "Lunch"9 },10 "activation_mode": "automatic",11 "manual_is_active": false12 }13 ]14}List Available Products (now)
/restaurant/locations/:locationId/products/availableLists currently available products (Location Open ∧ Any Menu Active ∧ Product Enabled) using optimized RPC.
Path parameters
| Parameter | Type | Description |
|---|---|---|
locationIdRequired | string | Dynamic path value from the request URL. |
Query parameters
| Parameter | Type | Description |
|---|---|---|
category_id | string | Example: |
limit | string | Example: |
page | string | Example: |
Headers
| Parameter | Type | Description |
|---|---|---|
Authorization | string | Example: |
1curl --globoff --request GET "https://staging-api.ondi.io/functions/v1/restaurant/locations/${LOCATIONID}/products/available?category_id=${CATEGORY_ID}&limit=12&page=1" \2 --header "Authorization: Bearer ${ONDI_ACCESS_TOKEN}"Response examples
1{2 "success": true,3 "data": [4 {5 "id": "{{productId}}",6 "location_id": "{{locationId}}",7 "category": {8 "id": "{{category_id}}",9 "name": {10 "en": "Burgers"11 }12 },13 "name": {14 "en": "Cheeseburger"15 },16 "description": {},17 "is_active": true,18 "images": [],19 "primary_variant": {20 "id": "{{variantId}}",21 "price": 8.99,22 "is_primary": true23 },24 "variant_count": 2,25 "created_at": "2025-11-10T10:00:00Z"26 }27 ],28 "page": 1,29 "limit": 1230}List Available Products (at)
/restaurant/locations/:locationId/products/availableLists available products at a specific timestamp (time-travel) using RPC.
Path parameters
| Parameter | Type | Description |
|---|---|---|
locationIdRequired | string | Dynamic path value from the request URL. |
Query parameters
| Parameter | Type | Description |
|---|---|---|
at | string | Example: |
Headers
| Parameter | Type | Description |
|---|---|---|
Authorization | string | Example: |
1curl --globoff --request GET "https://staging-api.ondi.io/functions/v1/restaurant/locations/${LOCATIONID}/products/available?at=2025-12-25T12:00:00Z" \2 --header "Authorization: Bearer ${ONDI_ACCESS_TOKEN}"Response examples
1{2 "success": true,3 "data": [ ... ],4 "page": 1,5 "limit": 126}