Alerts
Alerts are raised when a machine metric crosses a configured threshold. Use these endpoints to review alerts, acknowledge or snooze them, and add comments. All endpoints require a bearer JWT and the Alerts page (the alert history needs its own page, below). A member limited to some machines sees only the alerts of those machines. To configure what triggers an alert, see Alert Rules.
An alert's life
Endpoints
| Method | Path | Description |
|---|---|---|
GET | /api/v1/alerts | List alerts |
GET | /api/v1/alerts/stats | Aggregated alert counts |
GET | /api/v1/alerts/stats/raised | Alerts raised over a period |
GET | /api/v1/alerts/{alert_id} | Get a single alert |
POST | /api/v1/alerts/{alert_id}/acknowledge | Acknowledge an alert |
POST | /api/v1/alerts/bulk/acknowledge | Acknowledge many alerts |
POST | /api/v1/alerts/{alert_id}/snooze | Snooze an alert |
GET | /api/v1/alerts/{alert_id}/comments | List comments |
POST | /api/v1/alerts/{alert_id}/comments | Add a comment |
GET | /api/v1/alert-history | What happened to alerts: raised, escalated, acknowledged |
List alerts
GET /api/v1/alerts
Query parameters
| Parameter | Type | Description |
|---|---|---|
alert_id | uuid | Just this alert (what a portal notification links to) |
machine_id | uuid | Filter by machine |
severity | string | One of info, warning, critical |
is_acknowledged | boolean | Filter by acknowledgment state |
snoozed | boolean | true for alerts that are snoozed now, false for those that are not. Leave it out to ignore snoozing |
search | string | Text in the alert's message, metric name or machine name (up to 200 characters) |
include_resolved | boolean | Include alerts closed because the metric recovered (default false: the list shows open alerts) |
resolved | boolean | true for only the resolved alerts, false for only the unresolved. When given, include_resolved is ignored |
start_date | datetime | Alerts created on or after this time |
end_date | datetime | Alerts created on or before this time |
page | integer | Page number (default 1) |
page_size | integer | Items per page (default 20, max 100) |
Response: 200 OK
{
"items": [
{
"id": "b7e2...",
"tenant_id": "3f2504e0-4f89-41d3-9a0c-0305e82c3301",
"machine_id": "550e8400-e29b-41d4-a716-446655440000",
"severity": "critical",
"metric_name": "temperature",
"trigger_value": 87.3,
"threshold_value": 85.0,
"message": "Temperature exceeded the critical threshold.",
"is_acknowledged": false,
"acknowledged_at": null,
"acknowledged_by": null,
"snoozed_until": null,
"resolved_at": null,
"created_at": "2026-08-07T10:30:00Z",
"composite_rule_id": null,
"machine_name": "CNC Mill 3",
"playbook": {
"id": "c3d4...",
"scope": "machine",
"metric_name": "temperature",
"safety_note": "Let the housing cool before touching it.",
"check_steps": ["Check the coolant flow", "Check the fan"],
"likely_cause": "Blocked coolant filter.",
"fix": "Replace the filter and flush the line."
}
}
],
"pagination": {
"total": 1,
"page": 1,
"page_size": 20
}
}
resolved_at is set when the metric returned inside its thresholds, and is null while the alert is open. composite_rule_id is set on alerts raised by a composite rule. machine_name is the machine's display name; it can be null in the response to an acknowledge or a snooze.
Each alert carries playbook, the recommended next step it takes (shortened above; the full object is in Alert Playbooks), or null when none matches it.
Alert statistics
GET /api/v1/alerts/stats
Counts the alerts that need attention now, by severity: not acknowledged, not resolved because the metric recovered, and not snoozed at the moment.
{
"total_active": 12,
"critical_count": 3,
"warning_count": 7,
"info_count": 2
}
Alerts raised over a period
GET /api/v1/alerts/stats/raised?days=90
Counts, by severity, the alerts raised in the last days days (required, 1–366). Unlike /alerts/stats, an alert still counts after it is acknowledged, snoozed or resolved: this is what happened in the period, not what needs attention now. The ROI page uses it to estimate avoided downtime for the selected period.
{
"days": 90,
"critical_count": 4,
"warning_count": 19,
"info_count": 31
}
Get a single alert
GET /api/v1/alerts/{alert_id}
Returns one alert, or 404 if it does not exist or is not accessible to you.
Acknowledge an alert
POST /api/v1/alerts/{alert_id}/acknowledge
Requires an operator or administrator role. Marks the alert acknowledged and records who acknowledged it. Returns 409 Conflict if the alert was already acknowledged, and 404 if it does not exist or is not accessible to you.
Response: 200 OK (the updated alert)
Acknowledge many alerts
POST /api/v1/alerts/bulk/acknowledge
Requires an operator or administrator role. Acknowledge 1 to 1,000 alerts in one call.
{
"alert_ids": [
"b7e2...",
"c8f3...",
"d9a4..."
]
}
Response: 200 OK
{
"acknowledged_count": 2,
"already_acknowledged_ids": ["c8f3..."],
"not_found_ids": []
}
Snooze an alert
POST /api/v1/alerts/{alert_id}/snooze
Requires an operator or administrator role. Suppresses the alert until the given time. The snooze_until value must be in the future and no more than 30 days out (422 otherwise). Returns 200 OK with the updated alert, or 404 if the alert does not exist or is not accessible to you.
{
"snooze_until": "2026-08-07T14:00:00Z"
}
Comments
GET /api/v1/alerts/{alert_id}/comments lists the comment thread for an alert. POST /api/v1/alerts/{alert_id}/comments adds a comment (body up to 2,000 characters).
{
"body": "Investigated - bearing wear. Scheduling a replacement."
}
Response: 201 Created
{
"id": "e1a2...",
"author_id": "3f2504e0-4f89-41d3-9a0c-0305e82c3301",
"author_name": "Jordan Rivera",
"body": "Investigated - bearing wear. Scheduling a replacement.",
"created_at": "2026-08-07T11:00:00Z",
"updated_at": "2026-08-07T11:00:00Z"
}
The list response wraps comments in an items array with a total count.
Alert history
GET /api/v1/alert-history
A page of what has happened to your alerts, newest first: each alert's raising, each escalation (one per policy that escalated it), and its acknowledgement, as separate events. Needs the Alert History page; a member limited to some machines sees only theirs.
| Parameter | Type | Description |
|---|---|---|
kind | string | fired, escalated or acknowledged |
severity | string | info, warning or critical |
machine_id | uuid | One machine's alerts |
search | string | Text in the alert's message, metric or machine name (up to 200 characters) |
start_date, end_date | datetime | When the event happened (not when the alert was raised) |
page | integer | Page number (default 1) |
page_size | integer | Items per page (default 20, max 100) |
Response: 200 OK
{
"items": [
{
"id": "acknowledged:3f2504e0-4f89-41d3-9a0c-0305e82c3301",
"kind": "acknowledged",
"occurred_at": "2026-08-07T11:05:00Z",
"alert_id": "3f2504e0-4f89-41d3-9a0c-0305e82c3301",
"severity": "critical",
"message": "Spindle temperature above 85 °C",
"metric_name": "spindle_temperature",
"trigger_value": 91.2,
"threshold_value": 85.0,
"machine_id": "550e8400-e29b-41d4-a716-446655440000",
"machine_name": "CNC Mill 3",
"actor_name": "Jordan Rivera",
"policy_name": null
}
],
"pagination": { "total": 1, "page": 1, "page_size": 20 }
}
actor_name is set on acknowledged events (null if that person was since removed) and policy_name on escalated ones.
Severity levels
| Level | Description |
|---|---|
info | Informational |
warning | Metric above its warning threshold |
critical | Metric above its critical threshold |