API · v1 · stable
CODEMETA OSDeveloper Center
FR
Ouvrir la console
Entité · alarms

Alarm Schema

ID du schéma
alarm
Collection
alarms
Autorisations
  • Lirealarm_view
  • Créeralarm_manage
  • Modifieralarm_manage
  • Supprimeralarm_manage
Relations

Champs

Alarm Schema

alarms4 autorisations

ADR 0326 — stateful monitoring alarm (one doc per open dedupKey period), classified by the alarm rule stack.

statusstringobligatoire

Lifecycle: OPEN → ACKNOWLEDGED (in Bearbeitung) → RESOLVED (source sent CLEAR) | CLOSED (manual or auto_close action).

OPENACKNOWLEDGEDRESOLVEDCLOSED
lecture seule
isOpenbooleanobligatoire

Computed: true while status is OPEN or ACKNOWLEDGED. Exists solely for the unique partial index (one open alarm per dedupKey) — always derive from status, never set independently.

lecture seule
severitystringobligatoire

Display severity from the FIRST matching rule; fallback: severityHint mapping (critical→error) when no rule matched.

infowarningerror
lecture seule
canonicalSeveritystringfacultatif

Provider-mapped 4-level severity of the first RAISE (RmmSeverity). Kept alongside the 3-level display severity because ticket-priority policies are 4-level — the seeded default rule maps priorities from THIS field (fixed-policy parity).

infowarningerrorcriticalnull
Par défaut : nulllecture seulenullable
dedupKeystringobligatoire

Provider-scoped identity (ADR 0244) — passed through, never recomputed.

1–500 caractèreslecture seule
providerstringobligatoire

RMM provider id (octoja|riverbird|…).

max. 40 caractèreslecture seule
connectionIdstringfacultatif

integration_config the events came from.

MotifPar défaut : nulllecture seulenullable
errorTypestringfacultatif

Check name/category ("Fehlerart") — snapshot from the first RAISE.

max. 500 caractèresPar défaut : nulllecture seulenullable
checkTypestringfacultatif

Normalized check type (RMM_CHECK_TYPES catalog value), null when unknown.

max. 40 caractèresPar défaut : nulllecture seulenullable
messagestringfacultatif

Human-readable check output — updated on UPDATE events.

max. 20000 caractèresPar défaut : nulllecture seulenullable
deviceNamestringfacultatif
max. 500 caractèresPar défaut : nulllecture seulenullable
deviceCategorystringfacultatif

Normalized device category (RMM_DEVICE_CATEGORIES value).

max. 40 caractèresPar défaut : nulllecture seulenullable
siteNamestringfacultatif
max. 500 caractèresPar défaut : nulllecture seulenullable
customerNamestringfacultatif
max. 500 caractèresPar défaut : nulllecture seulenullable
partyIdstringfacultatif
MotifPar défaut : nulllecture seulenullable
rmmDeviceIdstringfacultatif
MotifPar défaut : nulllecture seulenullable
assetIdstringfacultatif

CMDB asset of the device — snapshot of rmm_device.assetId at alarm creation; null = no match ("ohne Asset" marker in the UI).

MotifPar défaut : nulllecture seulenullable
ticketIdstringfacultatif

Ticket created/attached by a create_ticket action.

MotifPar défaut : nulllecture seulenullable
matchedRuleIdsuuid[]facultatif

All rules that matched (evaluation transparency in the UI).

Par défaut : []lecture seule
suppressedByExceptionbooleanfacultatif

A rule matched but its exception suppressed all actions.

Par défaut : falselecture seule
pinnedbooleanfacultatif

OR over the matching rules — a pinned alarm cannot be hidden.

Par défaut : falselecture seule
hiddenByuuid[]facultatif

Users who hid this alarm from their board (only when not pinned).

Par défaut : []lecture seule
acknowledgedBystringfacultatif
MotifPar défaut : nulllecture seulenullable
acknowledgedAtdatetimefacultatif
Par défaut : nulllecture seulenullable
firstOccurredAtdatetimefacultatif
Par défaut : nulllecture seulenullable
lastEventAtdatetimefacultatif
Par défaut : nulllecture seulenullable
resolvedAtdatetimefacultatif
Par défaut : nulllecture seulenullable
closedBystringfacultatif

The user who closed the alarm by hand („Problem erledigt", POST /alarms/:id/close). Set only by that route — never by the rule action auto_close. The NinjaOne outbound sweep resets the condition in NinjaOne only for alarms carrying it. Absent = closed by a rule/system, or before the field existed.

Motiflecture seulenullable
closedAtdatetimefacultatif

When the alarm was closed by hand (with closedBy).

lecture seulenullable
eventCountintegerfacultatif
≥ 0Par défaut : 1lecture seule
scheduledActionJobIdsstring[]facultatif

Pending BullMQ action jobIds — best-effort cancel bookkeeping on CLEAR/ack.

Par défaut : []lecture seule
executedActionKeysstring[]facultatif

Idempotency keys of actions that already fired. The authoritative dedup — BullMQ jobId dedup ends at removeOnComplete.

Par défaut : []lecture seule
evaluationModestringfacultatif

ADR 1115 — who decides about tickets: the alarm rule stack (rules) or the fixed ticket policy of the connection (record — the alarm only records the disturbance and links that ticket, no rule ever runs). Kept for the whole open period. Absent = rules (every alarm before ADR 1115).

rulesrecord
lecture seule
discardedbooleanfacultatif

ADR 1115 — no rule matched and the unmatched policy is discard: the alarm is kept (dedup slot, event history) but hidden from the board by default and never acted on. Absent = false.

lecture seule
maintenancebooleanfacultatif

The alarm arose while its asset was in maintenance (`assets.maintenance`). A marker only: rule actions wait until the maintenance is over (and then run if the alarm is still open), the fixed ticket policy parks its ticket in `deferredTicket`. Absent = false.

lecture seule
deferredTicketobjectfacultatif

Record mode during an asset maintenance: the ticket the fixed policy would have created, rendered by the RMM adapter. Created by the alarm-consumer once the maintenance is over and the alarm is still open, then removed. Absent/null = nothing waiting.

lecture seulenullable

Endpoints standard

Cette ressource suit le contrat CRUD générique de la plateforme. Lisez les conventions pour la pagination, l'idempotence, le verrouillage optimiste et l'audit. Les endpoints principaux :

  • GET /api/v1/alarms — Liste, paginée et filtrable
  • GET /api/v1/alarms/<id> — Une entité
  • POST /api/v1/alarms — Créer
  • PATCH /api/v1/alarms/<id> — Mise à jour partielle
  • DELETE /api/v1/alarms/<id> — Suppression logique
  • GET /api/v1/alarms/<id>/timeline — Audit et activités

Recherche