Create an on-call schedule rotation

Creates an on-call rotation. This creates consecutive on-call events for specified users, rotating through them until reaching the end date, and removes any existing non-override events within this range. Without working_hours, this only creates events that end after 0:00 UTC today. With working_hours, it creates events from now on, only inside the given windows.

POST https://uptime.betterstack.com/api/v2/on-calls/{schedule_id}/rotation

URL parameters

schedule_id
required string

Headers

Authorization
required string

Body parameters

team_name
string
users
required array
rotation_length
required number
rotation_interval
required string
start_rotations_at
required date
end_rotations_at
required date
timezone
string
working_hours
array
200

Response body

{
  "rotation_length": 1,
  "rotation_interval": "day",
  "start_rotations_at": "2026-02-02T00:00:00.000Z",
  "end_rotations_at": "2028-02-02T00:00:00.000Z",
  "users": [
    "bob@betterstack.com",
    "alice@betterstack.com"
  ],
  "timezone": "Europe/Prague",
  "effective_timezone": "Europe/Prague",
  "working_hours": [
    {
      "day": "monday",
      "start_time": "09:00",
      "end_time": "17:00"
    },
    {
      "day": "tuesday",
      "start_time": "09:00",
      "end_time": "17:00"
    },
    {
      "day": "wednesday",
      "start_time": "09:00",
      "end_time": "17:00"
    },
    {
      "day": "thursday",
      "start_time": "09:00",
      "end_time": "17:00"
    },
    {
      "day": "friday",
      "start_time": "09:00",
      "end_time": "17:00"
    }
  ]
}

Example cURL

Example
curl --request POST \
  --url "https://uptime.betterstack.com/api/v2/on-calls/default/rotation" \
  --header 'Authorization: Bearer $TOKEN' \
  --header 'Content-Type: application/json' \
  --data '{
    "users": ["bob@betterstack.com", "alice@betterstack.com"],
    "rotation_length": 1,
    "rotation_interval": "day",
    "start_rotations_at": "2026-02-02T00:00:00Z",
    "end_rotations_at": "2028-02-02T00:00:00Z",
    "timezone": "Europe/Prague",
    "working_hours": [
      { "day": "monday", "start_time": "09:00", "end_time": "17:00" },
      { "day": "tuesday", "start_time": "09:00", "end_time": "17:00" },
      { "day": "wednesday", "start_time": "09:00", "end_time": "17:00" },
      { "day": "thursday", "start_time": "09:00", "end_time": "17:00" },
      { "day": "friday", "start_time": "09:00", "end_time": "17:00" }
    ]
  }'