Alerts API

Manage alert rules and query alert event history via the API.

List alerts

GET /api/v1/alerts

Create an alert

POST /api/v1/alerts

{
  "endpoint_id": "ep_abc123",
  "type": "slack",
  "config": {
    "webhook_url": "https://hooks.slack.com/services/..."
  },
  "failure_threshold": 3,
  "success_threshold": 1,
  "send_on_resolved": true,
  "description": "See runbook: https://..."
}

Update an alert

PUT /api/v1/alerts/:id

{
  "failure_threshold": 5,
  "enabled": false
}

Delete an alert

DELETE /api/v1/alerts/:id

List alert events

GET /api/v1/alerts/events?limit=50

Returns recent triggered and resolved events across all alerts in the organization.

Alert object

{
  "id": "al_abc123",
  "endpoint_id": "ep_xyz789",
  "type": "slack",
  "enabled": true,
  "config": {"webhook_url": "https://..."},
  "failure_threshold": 3,
  "success_threshold": 1,
  "send_on_resolved": true,
  "description": "",
  "triggered": false,
  "created_at": "2025-01-01T00:00:00Z"
}

Supported alert types

Valid values for type: email, slack, discord, pagerduty, teams, telegram, webhook, twilio, opsgenie.