Browse the docs

Message templates

Saved wording for incidents and maintenance, with variables substituted at render time.

Templates have a kind of incident or maintenance, an optional title_tpl and a body_tpl. Both accept {{component}}, {{components}}, {{page}}, {{title}} and {{eta}}. Monitor rules reference them by id. See the message templates guide.

List templates

GET/user/message_templates

Needs the dashboard.read permission, or an API key with the matching scope.

Query parameters

workspace_idintegerrequired
The workspace to read from.
kindstring
incident or maintenance.
Request
curl "https://api.statusbee.co/user/message_templates?workspace_id=5&kind=incident" \
  -H "Authorization: Bearer sb_live_…"
Response
{
  "statusCode": 200,
  "error": false,
  "message": null,
  "data": {
    "rows": [
      {
        "id": 4,
        "workspace_id": 5,
        "org_id": 5,
        "kind": "incident",
        "name": "Automated outage",
        "title_tpl": "{{component}} is unavailable",
        "body_tpl": "Our monitoring detected a problem with {{component}}. We are investigating and will post an update within 30 minutes.",
        "created_at": "2026-09-14T09:02:11.000Z",
        "updated_at": "2026-09-14T09:02:11.000Z"
      }
    ]
  }
}

Create a template

POST/user/message_templates

Needs the templates.manage permission, or an API key with the matching scope.

Body

workspace_idintegerrequired
kindstringrequired
incident or maintenance.
namestringrequired
Shown in pickers.
body_tplstringrequired
Markdown with variables.
title_tplstring
Up to 200 characters.
Request
curl -X POST "https://api.statusbee.co/user/message_templates" \
  -H "Authorization: Bearer sb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "workspace_id": 5,
  "kind": "incident",
  "name": "Automated outage",
  "title_tpl": "{{component}} is unavailable",
  "body_tpl": "Our monitoring detected a problem with {{component}}. We are investigating and will post an update within 30 minutes."
}'
Response
{
  "statusCode": 200,
  "error": false,
  "message": null,
  "data": {
    "id": 4,
    "workspace_id": 5,
    "org_id": 5,
    "kind": "incident",
    "name": "Automated outage",
    "title_tpl": "{{component}} is unavailable",
    "body_tpl": "Our monitoring detected a problem with {{component}}. We are investigating and will post an update within 30 minutes.",
    "created_at": "2026-09-14T09:02:11.000Z",
    "updated_at": "2026-09-14T09:02:11.000Z"
  }
}

Render a template

POST/user/message_templates/:id/render

Preview with your own variable values. Unknown variables are left as typed.

Needs the dashboard.read permission, or an API key with the matching scope.

Path parameters

idintegerrequired
Template id.

Body

varsobjectrequired
{ component, components, page, title, eta }, any subset.
Request
curl -X POST "https://api.statusbee.co/user/message_templates/4/render" \
  -H "Authorization: Bearer sb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "vars": {
    "component": "Checkout",
    "page": "Acme Cloud"
  }
}'
Response
{
  "statusCode": 200,
  "error": false,
  "message": null,
  "data": {
    "title": "Checkout is unavailable",
    "body": "Our monitoring detected a problem with Checkout. We are investigating and will post an update within 30 minutes."
  }
}

Update a template

PATCH/user/message_templates/:id

Needs the templates.manage permission, or an API key with the matching scope.

Path parameters

idintegerrequired
Template id.

Body

namestring
title_tplstring
body_tplstring
Request
curl -X PATCH "https://api.statusbee.co/user/message_templates/4" \
  -H "Authorization: Bearer sb_live_…" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Monitor-detected outage"
}'
Response
{
  "statusCode": 200,
  "error": false,
  "message": null,
  "data": {
    "id": 4,
    "workspace_id": 5,
    "org_id": 5,
    "kind": "incident",
    "name": "Monitor-detected outage",
    "title_tpl": "{{component}} is unavailable",
    "body_tpl": "Our monitoring detected a problem with {{component}}. We are investigating and will post an update within 30 minutes.",
    "created_at": "2026-09-14T09:02:11.000Z",
    "updated_at": "2026-09-14T09:02:11.000Z"
  }
}

Delete a template

DELETE/user/message_templates/:id

Needs the templates.manage permission, or an API key with the matching scope.

Path parameters

idintegerrequired
Template id.
Request
curl -X DELETE "https://api.statusbee.co/user/message_templates/4" \
  -H "Authorization: Bearer sb_live_…"
Response
{
  "statusCode": 200,
  "error": false,
  "message": null,
  "data": {
    "deleted": 1
  }
}