API · v1 · stabiel
CODEMETA OSDeveloper Center
NL
Console openen
Entity · alarms

Alarm Schema

Schema-ID
alarm
Collection
alarms
Permissions
  • Lezenalarm_view
  • Aanmakenalarm_manage
  • Wijzigenalarm_manage
  • Verwijderenalarm_manage
Relaties

Velden

Alarm Schema

alarms4 permissions

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

statusstringvereist

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

OPENACKNOWLEDGEDRESOLVEDCLOSED
read-only
isOpenbooleanvereist

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.

read-only
severitystringvereist

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

infowarningerror
read-only
canonicalSeveritystringoptioneel

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
Default: nullread-onlynullable
dedupKeystringvereist

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

1–500 tekensread-only
providerstringvereist

RMM provider id (octoja|riverbird|…).

max. 40 tekensread-only
connectionIdstringoptioneel

integration_config the events came from.

PatternDefault: nullread-onlynullable
errorTypestringoptioneel

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

max. 500 tekensDefault: nullread-onlynullable
checkTypestringoptioneel

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

max. 40 tekensDefault: nullread-onlynullable
messagestringoptioneel

Human-readable check output — updated on UPDATE events.

max. 20000 tekensDefault: nullread-onlynullable
deviceNamestringoptioneel
max. 500 tekensDefault: nullread-onlynullable
deviceCategorystringoptioneel

Normalized device category (RMM_DEVICE_CATEGORIES value).

max. 40 tekensDefault: nullread-onlynullable
siteNamestringoptioneel
max. 500 tekensDefault: nullread-onlynullable
customerNamestringoptioneel
max. 500 tekensDefault: nullread-onlynullable
partyIdstringoptioneel
PatternDefault: nullread-onlynullable
rmmDeviceIdstringoptioneel
PatternDefault: nullread-onlynullable
assetIdstringoptioneel

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

PatternDefault: nullread-onlynullable
ticketIdstringoptioneel

Ticket created/attached by a create_ticket action.

PatternDefault: nullread-onlynullable
matchedRuleIdsuuid[]optioneel

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

Default: []read-only
suppressedByExceptionbooleanoptioneel

A rule matched but its exception suppressed all actions.

Default: falseread-only
pinnedbooleanoptioneel

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

Default: falseread-only
hiddenByuuid[]optioneel

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

Default: []read-only
acknowledgedBystringoptioneel
PatternDefault: nullread-onlynullable
acknowledgedAtdatetimeoptioneel
Default: nullread-onlynullable
firstOccurredAtdatetimeoptioneel
Default: nullread-onlynullable
lastEventAtdatetimeoptioneel
Default: nullread-onlynullable
resolvedAtdatetimeoptioneel
Default: nullread-onlynullable
closedBystringoptioneel

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.

Patternread-onlynullable
closedAtdatetimeoptioneel

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

read-onlynullable
eventCountintegeroptioneel
≥ 0Default: 1read-only
scheduledActionJobIdsstring[]optioneel

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

Default: []read-only
executedActionKeysstring[]optioneel

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

Default: []read-only
evaluationModestringoptioneel

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
read-only
discardedbooleanoptioneel

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.

read-only
maintenancebooleanoptioneel

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.

read-only
deferredTicketobjectoptioneel

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.

read-onlynullable

Standaard-endpoints

Deze resource volgt het generieke CRUD-contract van het platform. Lees de conventies voor paginering, idempotentie, optimistic locking en audit. De belangrijkste endpoints:

  • GET /api/v1/alarms — Lijst, gepagineerd + filterbaar
  • GET /api/v1/alarms/<id> — Enkele entity
  • POST /api/v1/alarms — Aanmaken
  • PATCH /api/v1/alarms/<id> — Gedeeltelijke update
  • DELETE /api/v1/alarms/<id> — Soft-delete
  • GET /api/v1/alarms/<id>/timeline — Audit + activiteiten

Zoeken