Notification groups, members and rosters
All paths below are relative to /api/v1.
GET /notification_groups / MCP list_notification_groups.
Requires notification_groups:read; accepts limit and cursor.
{ "items": [ { "id": "123", "name": "Operations", "delivery_configured": true, "channels_awaiting_confirmation": 0, "user_ids": ["101", "102"], "roster_ids": ["7"], "check_count": 12 } ], "next_cursor": null}user_ids are the account members the group alerts directly, roster_ids its
on-call rosters, and check_count how many checks alert it.
delivery_configured means the group has channels, direct users or rosters.
It does not prove an eligible user is currently on schedule, a delivery method
is enabled or an alert was successfully delivered.
channels_awaiting_confirmation is the number of the group’s email channels
whose recipient hasn’t confirmed yet.
Those channels get no alerts until they’re confirmed. A group can have
delivery_configured: true while all of its channels are still awaiting
confirmation, so check both fields.
Use returned IDs in a check’s notification_group_ids. Supplying this field
also requires notification_groups:assign, including on create. A check
created without the field gets the account’s Default group.
Channel addresses and delivery credentials are never returned.
Members and rosters
Section titled “Members and rosters”GET /members / MCP list_account_members requires members:read, which
needs the Manage alerts capability (Editor or Admin). Each item has the person’s
id, name, email, role (admin, editor, billing or viewer) and owner.
Only current members appear; pending invitations don’t.
GET /rosters / MCP list_rosters requires notification_groups:read.
Each item has the roster’s id, name and user_ids. Rosters are created and
edited in the app.
Both accept limit and cursor.
Create and update
Section titled “Create and update”POST /notification_groups / create_notification_group and
PATCH /notification_groups/:id / update_notification_group require
notification_groups:manage (Editor or Admin).
{ "group": { "name": "Client staff", "user_ids": ["101", "102"], "roster_ids": ["7"] }}| Body field | Constraint |
|---|---|
name |
Nonempty string <=255, unique in the account; required on create |
user_ids |
Up to 100 IDs of people already on the account |
roster_ids |
Up to 100 IDs of the account’s rosters |
On update, user_ids and roster_ids each replace the whole list when sent
and are left alone when omitted. People who stay in the group keep their alert
schedule; people added are alerted at all hours until you set a schedule in the
app.
Nobody is invited or emailed, and channels such as email, Slack or Microsoft Teams aren’t
added here. A name already in use returns validation_failed. An ID that
isn’t a member or roster of this account returns invalid_arguments. Both
leave the group unchanged. The response is the group resource shown above;
creates return 201.
Assign a group to many checks
Section titled “Assign a group to many checks”POST /notification_groups/:id/checks / assign_notification_group
requires notification_groups:assign. Send one of:
{ "check_ids": ["check_FIRST", "check_SECOND"] }{ "dashboard_id": "dash_EXAMPLE" }check_ids takes 1-100 unique check IDs. dashboard_id covers every check on
that dashboard, and returns invalid_arguments when the dashboard has more
than 100; send those as check_ids in batches.
Each check keeps its other groups, and checks that already have the group are unchanged. The response lists the checks covered and how many gained the group:
{ "id": "123", "check_ids": ["check_FIRST", "check_SECOND"], "added": 1 }This operation only adds. To remove a group from a check, send the check’s
full notification_group_ids in a check update.
Delete
Section titled “Delete”DELETE /notification_groups/:id / delete_notification_group requires
notification_groups:delete, a sensitive permission. The group’s channels and
member list go with it, and checks that alerted only this group will alert
nobody. Returns {"id": "123", "name": "Operations", "deleted": true}.
Deletes count toward the delete limit, and the account owner is emailed.
For channels, schedules and rosters, use notification-group management in the signed-in UI.