countSiteAlarms

GET https://{{host}}/api/v1/sites/:site_id/alarms/count

Response Parameters

ParameterTypeDescription
resultslistList of result objects
stringA field based on which alarms are grouped & counted
countintNumber of alarms grouped by distinct parameter value

Request Params

KeyDatatypeRequiredDescription
typenullstring, Key-name of the alarms; accepts multiple values separated by comma
ack_admin_namenullstring, Name of the admins who have acked the alarms; accepts multiple values separated by comma
ackednullboolean
groupnullstring, Alarm group name; accepts multiple values separated by comma
severitynullstring, Alarm severity; accepts multiple values separated by comma
distinctnullstring, Group by and count the alarms by some distinct field (e.g. type, group, severity etc.); default=type

RESPONSES

status: OK

{"results":[{"type":"switch_restarted","count":2},{"type":"device_down","count":1},{"type":"device_restarted","count":1}],"start":1625477727.0,"end":1625566540.9141023,"limit":10,"distinct":"group","total":1,"percentage":100}