Business schedules
Business schedules: 5 operations of the ChaosDesk REST API.
- GET
/api/business_schedulesRetrieves the collection of BusinessSchedule resources. - POST
/api/business_schedulesCreates a BusinessSchedule resource. - GET
/api/business_schedules/{id}Retrieves a BusinessSchedule resource. - PATCH
/api/business_schedules/{id}Updates the BusinessSchedule resource. - DELETE
/api/business_schedules/{id}Removes the BusinessSchedule resource.
Retrieves the collection of BusinessSchedule resources.
Responses
200BusinessSchedule collection403Forbidden
Example request
curl -X GET "https://yourcompany.chaosdesk.io/api/business_schedules" \
-H "Authorization: Bearer $CHAOSDESK_TOKEN" \
-H "Accept: application/json" Creates a BusinessSchedule resource.
Request body application/json
namestringrequiredtimezonestringrequiredintervalsobject- weekday (mon…sun) => ["07:00-19:00", …] in local time
defaultboolean- Used by policies without an explicit schedule.
Responses
201BusinessSchedule resource created400Invalid input403Forbidden422An error occurred
Example request
curl -X POST "https://yourcompany.chaosdesk.io/api/business_schedules" \
-H "Authorization: Bearer $CHAOSDESK_TOKEN" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{"name":"string","timezone":"string"}' Retrieves a BusinessSchedule resource.
GET/api/business_schedules/{id}
Parameters
idstringpathrequired- BusinessSchedule identifier
Responses
200BusinessSchedule resource403Forbidden404Not found
Example request
curl -X GET "https://yourcompany.chaosdesk.io/api/business_schedules/{id}" \
-H "Authorization: Bearer $CHAOSDESK_TOKEN" \
-H "Accept: application/json" Updates the BusinessSchedule resource.
PATCH/api/business_schedules/{id}
Parameters
idstringpathrequired- BusinessSchedule identifier
Request body application/merge-patch+json
namestringtimezonestringintervalsobject- weekday (mon…sun) => ["07:00-19:00", …] in local time
defaultboolean- Used by policies without an explicit schedule.
Responses
200BusinessSchedule resource updated400Invalid input403Forbidden404Not found422An error occurred
Example request
curl -X PATCH "https://yourcompany.chaosdesk.io/api/business_schedules/{id}" \
-H "Authorization: Bearer $CHAOSDESK_TOKEN" \
-H "Accept: application/json" \
-H "Content-Type: application/merge-patch+json" \
-d '{"name":"string","timezone":"string"}' Removes the BusinessSchedule resource.
DELETE/api/business_schedules/{id}
Parameters
idstringpathrequired- BusinessSchedule identifier
Responses
204BusinessSchedule resource deleted403Forbidden404Not found
Example request
curl -X DELETE "https://yourcompany.chaosdesk.io/api/business_schedules/{id}" \
-H "Authorization: Bearer $CHAOSDESK_TOKEN" \
-H "Accept: application/json"