Skip to main content

Schedules

10 API calls in this section.

List Location Schedules

Restaurant Menu / Schedules
GET/restaurant/locations/:locationId/schedules

Returns all schedule windows for a location (weekly recurring windows with optional date ranges).

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request GET "$ONDI_BASE_URL/restaurant/locations/:locationId/schedules" \2  --header "Authorization: Bearer {{access_token}}"

Path parameters

locationIdRequired
path string

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": [4    {5      "id": "{{scheduleId}}",6      "location_id": "{{locationId}}",7      "day_of_week": 1,8      "open_time": "08:00:00",9      "close_time": "12:00:00",10      "start_date": null,11      "end_date": null,12      "active": true13    }14  ]15}

List Location Schedule Exceptions

Restaurant Menu / Schedules
GET/restaurant/locations/:locationId/schedule-exceptions

Returns all schedule exceptions for a location.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request GET "$ONDI_BASE_URL/restaurant/locations/:locationId/schedule-exceptions" \2  --header "Authorization: Bearer {{access_token}}"

Path parameters

locationIdRequired
path string

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": [4    {5      "id": "{{exceptionId}}",6      "schedule_id": "{{scheduleId}}",7      "date": "2025-12-25",8      "closed": true,9      "reason": "Holiday",10      "schedule": {11        "location_id": "{{locationId}}",12        "day_of_week": 1,13        "open_time": "08:00:00",14        "close_time": "12:00:00"15      }16    }17  ]18}

Set Location Schedules (replace)

Restaurant Menu / Schedules
POST/restaurant/locations/:locationId/schedules

Replaces all existing schedules for the location with the provided set. Triggers bump availability_version.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request POST "$ONDI_BASE_URL/restaurant/locations/:locationId/schedules" \2  --header "Authorization: Bearer {{access_token}}" \3  --header "Content-Type: application/json" \4  --data '{5  "schedules": [6    {7      "day_of_week": 1,8      "start_time": "08:00:00",9      "end_time": "12:00:00",10      "start_date": null,11      "end_date": null,12      "active": true13    },14    {15      "day_of_week": 1,16      "start_time": "18:00:00",17      "end_time": "22:00:00",18      "active": true19    },20    {21      "day_of_week": 2,22      "start_time": "08:00:00",23      "end_time": "12:00:00"24    }25  ]26}'
Request body
json
1{2  "schedules": [3    {4      "day_of_week": 1,5      "start_time": "08:00:00",6      "end_time": "12:00:00",7      "start_date": null,8      "end_date": null,9      "active": true10    },11    {12      "day_of_week": 1,13      "start_time": "18:00:00",14      "end_time": "22:00:00",15      "active": true16    },17    {18      "day_of_week": 2,19      "start_time": "08:00:00",20      "end_time": "12:00:00"21    }22  ]23}

Path parameters

locationIdRequired
path string

Request body fields

schedulesExample
array<object>

Example field from the request body.

schedules.day_of_weekExample
number

Example field from the request body.

schedules.start_timeExample
string

Example field from the request body.

schedules.end_timeExample
string

Example field from the request body.

schedules.start_dateExample
null

Example field from the request body.

schedules.end_dateExample
null

Example field from the request body.

schedules.activeExample
boolean

Example field from the request body.

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": [4    {5      "id": "{{scheduleId}}",6      "day_of_week": 1,7      "open_time": "08:00:00",8      "close_time": "12:00:00"9    }10  ]11}

Add Location Schedule Exception

Restaurant Menu / Schedules
POST/restaurant/locations/:locationId/schedule-exceptions

Adds an exception for a specific schedule window on a given date. Either provide schedule_id or the (day_of_week,start_time,end_time) signature.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request POST "$ONDI_BASE_URL/restaurant/locations/:locationId/schedule-exceptions" \2  --header "Authorization: Bearer {{access_token}}" \3  --header "Content-Type: application/json" \4  --data '{5  "date": "2025-12-25",6  "closed": true,7  "reason": "Christmas Day",8  "day_of_week": 1,9  "start_time": "08:00:00",10  "end_time": "12:00:00"11}'
Request body
json
1{2  "date": "2025-12-25",3  "closed": true,4  "reason": "Christmas Day",5  "day_of_week": 1,6  "start_time": "08:00:00",7  "end_time": "12:00:00"8}

Path parameters

locationIdRequired
path string

Request body fields

dateExample
string

Example field from the request body.

closedExample
boolean

Example field from the request body.

reasonExample
string

Example field from the request body.

day_of_weekExample
number

Example field from the request body.

start_timeExample
string

Example field from the request body.

end_timeExample
string

Example field from the request body.

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": {4    "id": "{{exceptionId}}",5    "schedule_id": "{{scheduleId}}",6    "date": "2025-12-25",7    "closed": true,8    "reason": "Christmas Day"9  }10}

Delete Location Schedule Exception

Restaurant Menu / Schedules
DELETE/restaurant/schedule-exceptions/:exceptionId

Deletes a location schedule exception by id.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request DELETE "$ONDI_BASE_URL/restaurant/schedule-exceptions/:exceptionId" \2  --header "Authorization: Bearer {{access_token}}"

Path parameters

exceptionIdRequired
path string

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": {4    "id": "{{exceptionId}}"5  }6}

List Menu Schedules

Restaurant Menu / Schedules
GET/restaurant/menus/:menuId/schedules

Returns menu schedule windows (weekly recurring, optional date range).

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request GET "$ONDI_BASE_URL/restaurant/menus/:menuId/schedules" \2  --header "Authorization: Bearer {{access_token}}"

Path parameters

menuIdRequired
path string

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": [4    {5      "id": "{{menuScheduleId}}",6      "menu_id": "{{menuId}}",7      "day_of_week": 1,8      "start_time": "12:00:00",9      "end_time": "16:00:00",10      "active": true11    }12  ]13}

List Menu Schedule Exceptions

Restaurant Menu / Schedules
GET/restaurant/menus/:menuId/schedule-exceptions

Returns all schedule exceptions for a menu.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request GET "$ONDI_BASE_URL/restaurant/menus/:menuId/schedule-exceptions" \2  --header "Authorization: Bearer {{access_token}}"

Path parameters

menuIdRequired
path string

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": [4    {5      "id": "{{exceptionId}}",6      "menu_schedule_id": "{{menuScheduleId}}",7      "date": "2025-12-25",8      "closed": true,9      "reason": "Holiday",10      "schedule": {11        "menu_id": "{{menuId}}",12        "day_of_week": 1,13        "start_time": "12:00:00",14        "end_time": "16:00:00"15      }16    }17  ]18}

Set Menu Schedules (replace)

Restaurant Menu / Schedules
POST/restaurant/menus/:menuId/schedules

Replaces all existing schedules for the menu with the provided set. Triggers bump availability_version via menu-based trigger.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request POST "$ONDI_BASE_URL/restaurant/menus/:menuId/schedules" \2  --header "Authorization: Bearer {{access_token}}" \3  --header "Content-Type: application/json" \4  --data '{5  "schedules": [6    {7      "day_of_week": 1,8      "start_time": "12:00:00",9      "end_time": "16:00:00",10      "active": true11    },12    {13      "day_of_week": 1,14      "start_time": "18:00:00",15      "end_time": "22:00:00",16      "active": true17    }18  ]19}'
Request body
json
1{2  "schedules": [3    {4      "day_of_week": 1,5      "start_time": "12:00:00",6      "end_time": "16:00:00",7      "active": true8    },9    {10      "day_of_week": 1,11      "start_time": "18:00:00",12      "end_time": "22:00:00",13      "active": true14    }15  ]16}

Path parameters

menuIdRequired
path string

Request body fields

schedulesExample
array<object>

Example field from the request body.

schedules.day_of_weekExample
number

Example field from the request body.

schedules.start_timeExample
string

Example field from the request body.

schedules.end_timeExample
string

Example field from the request body.

schedules.activeExample
boolean

Example field from the request body.

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": [4    {5      "id": "{{menuScheduleId}}",6      "day_of_week": 1,7      "start_time": "12:00:00",8      "end_time": "16:00:00"9    }10  ]11}

Add Menu Schedule Exception

Restaurant Menu / Schedules
POST/restaurant/menus/:menuId/schedule-exceptions

Adds an exception for a specific menu schedule window on a given date. Either provide menu_schedule_id or the (day_of_week,start_time,end_time) signature.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request POST "$ONDI_BASE_URL/restaurant/menus/:menuId/schedule-exceptions" \2  --header "Authorization: Bearer {{access_token}}" \3  --header "Content-Type: application/json" \4  --data '{5  "date": "2025-12-25",6  "closed": true,7  "reason": "Christmas Lunch",8  "day_of_week": 1,9  "start_time": "12:00:00",10  "end_time": "16:00:00"11}'
Request body
json
1{2  "date": "2025-12-25",3  "closed": true,4  "reason": "Christmas Lunch",5  "day_of_week": 1,6  "start_time": "12:00:00",7  "end_time": "16:00:00"8}

Path parameters

menuIdRequired
path string

Request body fields

dateExample
string

Example field from the request body.

closedExample
boolean

Example field from the request body.

reasonExample
string

Example field from the request body.

day_of_weekExample
number

Example field from the request body.

start_timeExample
string

Example field from the request body.

end_timeExample
string

Example field from the request body.

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": {4    "id": "{{menuExceptionId}}",5    "menu_schedule_id": "{{menuScheduleId}}",6    "date": "2025-12-25",7    "closed": true,8    "reason": "Christmas Lunch"9  }10}

Delete Menu Schedule Exception

Restaurant Menu / Schedules
DELETE/restaurant/menu-schedule-exceptions/:exceptionId

Deletes a menu schedule exception by id.

Send a bearer token in the Authorization header for an authenticated OnDi user session.
Request
curl
1curl --request DELETE "$ONDI_BASE_URL/restaurant/menu-schedule-exceptions/:exceptionId" \2  --header "Authorization: Bearer {{access_token}}"

Path parameters

exceptionIdRequired
path string

Headers

AuthorizationOptional
header string

Bearer {{access_token}}

Responses

200 OK200OK
Response body
json
1{2  "success": true,3  "data": {4    "id": "{{menuExceptionId}}"5  }6}