Listar alarmes
RegistosGET /alarms
Returns the tenant's alarms, newest first, with cursor pagination (limit defaults to 20, at most 100; pass next_cursor as after). Filters combine, so you can ask for the open alarms of one rule at one sensor.
Parâmetros
statusReturn only alarms in this state: open, acknowledged or resolved; omit for all states.
rule_idReturn only alarms raised by this alarm rule (prefix mrl_).
sensor_idReturn only alarms raised at this location: the sensor ID for telemetry rules, or the asset or DMA ID of the sample for quality rules.
limitMaximum resources to return (default 20, maximum 100).
afterOpaque cursor returned by the previous page.
Devolve
200 OK
Mostrar atributos
dataMostrar atributos filhos
idrule_idsensor_idsample_idtitleseverityevent_typestatusum de
open,acknowledged,resolvedvaluepeak_valueunitopened_atlast_observed_atacknowledged_atacknowledged_byresolved_atresolution_notesresolution_codeStable code of a resolution the server wrote (alarm.auto_cleared); clients word it and fall back to resolution_notes. Absent for notes people typed.
has_morenext_cursor
Permissões business:monitoring:read · Funções: admin, analyst, field_supervisor, operations, owner, viewer
curl -X GET "$BUSINESS_API/alarms" \
-H "Authorization: Bearer sk_test_..."
# Sem comando CLI equivalente; use cURL ou HTTP directo.
const res = await fetch("$BUSINESS_API/alarms", {
method: "GET",
headers: {
Authorization: "Bearer sk_test_..."
}
});
const data = await res.json();
import requests
res = requests.get(
"$BUSINESS_API/alarms",
headers={
"Authorization": "Bearer sk_test_..."
}
)
data = res.json()
req, _ := http.NewRequest("GET", "$BUSINESS_API/alarms", nil)
req.Header.Set("Authorization", "Bearer sk_test_...")
resp, err := http.DefaultClient.Do(req)
{
"data": [
{
"id": "ala_2NbIUPJ8YXJkm1LiQVXgqjxIYd7",
"rule_id": "rul_2aARlSaHxSk1Z6Yp9aKdnemXRyk",
"sensor_id": "sen_28o3p46TDQsRdq8pzycV5cIxbMg",
"sample_id": "sam_2U07jOAhTYQNV60Pd6W5x8IZHUU",
"title": "Fuga na Rua 3",
"severity": "severity",
"event_type": "event type",
"status": "open",
"value": 13.42,
"peak_value": 13.42,
"unit": "unit",
"opened_at": "2026-11-19T09:30:00Z",
"last_observed_at": "2026-11-19T09:30:00Z",
"acknowledged_at": "2026-11-19T09:30:00Z",
"acknowledged_by": "acknowledged by",
"resolved_at": "2026-11-19T09:30:00Z",
"resolution_notes": "resolution notes",
"resolution_code": "RES-2026-000142"
}
],
"has_more": true,
"next_cursor": "next cursor"
}