On-call
Define who is on duty and when: rotation schedules, members, overrides and current on-call.
What it's for
An on-call schedule determines who must be notified at a given moment. You define a rotation schedule: a list of members who take turns according to a rhythm (e.g. weekly), in a given time zone, with optional ad-hoc overrides. Alert policies rely on the current on-call to route notifications to the right person.
The schedule model
| Field | Type | Required | Description |
|---|---|---|---|
id | uuid | (generated) | Unique identifier. |
name | string | ✅ | Schedule name (Web on-call). |
timezone | string | — | Time zone. Default: America/Toronto. |
rotation_type | string | — | Rotation type. Default: weekly. |
members | JSON array | — | Members of the rotation, in order. Default: []. |
overrides | JSON array | — | Ad-hoc overrides (replacements). Default: []. |
Using it from the portal
The On-call section shows the current on-call ("On-Call Now") and the list of your schedules. You can create, edit and delete a schedule, set the order of members and add overrides.
Listing and viewing: all roles. Create, edit, delete:
ownerandadmin.
Using it through the API
List schedules
GET /api/v2/oncall-schedules
curl -s https://api.secumon.secuaas.ovh/api/v2/oncall-schedules \
-H "Authorization: Bearer $SECUMON_TOKEN"[
{
"id": "5b4a3c2d-aaaa-4bbb-9ccc-ddddeeeeffff",
"name": "Web on-call",
"timezone": "America/Toronto",
"rotation_type": "weekly"
}
]Create a schedule
POST /api/v2/oncall-schedules — name required. The default values
(timezone: America/Toronto, rotation_type: weekly, members: [],
overrides: []) apply if you omit them.
curl -s -X POST https://api.secumon.secuaas.ovh/api/v2/oncall-schedules \
-H "Authorization: Bearer $SECUMON_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Web on-call",
"timezone": "America/Toronto",
"rotation_type": "weekly",
"members": [
{ "name": "Alice", "email": "alice@example.com" },
{ "name": "Bob", "email": "bob@example.com" }
]
}'Response: 201 Created with the schedule.
View a schedule (with the current on-call)
GET /api/v2/oncall-schedules/:id returns the schedule and the member
currently on call.
curl -s https://api.secumon.secuaas.ovh/api/v2/oncall-schedules/5b4a3c2d-aaaa-4bbb-9ccc-ddddeeeeffff \
-H "Authorization: Bearer $SECUMON_TOKEN"{
"schedule": { "id": "5b4a3c2d-aaaa-4bbb-9ccc-ddddeeeeffff", "name": "Web on-call", "...": "..." },
"current_oncall": { "name": "Alice", "email": "alice@example.com" }
}Edit and delete
# Edit
curl -s -X PUT https://api.secumon.secuaas.ovh/api/v2/oncall-schedules/5b4a3c2d-aaaa-4bbb-9ccc-ddddeeeeffff \
-H "Authorization: Bearer $SECUMON_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Web on-call",
"timezone": "America/Toronto",
"rotation_type": "weekly",
"members": [ { "name": "Alice", "email": "alice@example.com" } ]
}'
# Delete
curl -s -X DELETE https://api.secumon.secuaas.ovh/api/v2/oncall-schedules/5b4a3c2d-aaaa-4bbb-9ccc-ddddeeeeffff \
-H "Authorization: Bearer $SECUMON_TOKEN"Edit and delete return 204 No Content.
Current on-call across all schedules
GET /api/v2/oncall/current returns, for each schedule, the on-call member at
the time of the call.
curl -s https://api.secumon.secuaas.ovh/api/v2/oncall/current \
-H "Authorization: Bearer $SECUMON_TOKEN"[
{
"schedule_id": "5b4a3c2d-aaaa-4bbb-9ccc-ddddeeeeffff",
"schedule_name": "Web on-call",
"on_call": { "name": "Alice", "email": "alice@example.com" }
}
]Use cases
- Weekly rotation: alternate on-call duty between members of a team, each covering one week.
- Ad-hoc replacement: use
overridesto cover an absence (leave, travel) without changing the base rotation. - On-call board: display
GET /oncall/currentto know at a glance who is reachable right now.
Tips
- Set the correct
timezone: the rotation and overrides are computed in that zone, which avoids time confusion. - Pair the on-call with an alert policy so that notifications automatically reach the person on duty.
- Check
current_oncallafter changing the rotation to confirm that the right person is now on call.