Rules & alerts

Rules are visual trigger → condition → action flows. When a trigger fires and the conditions pass, every connected action runs.

Triggers

TriggerFires whenKey options
telemetryA metric crosses a thresholdmetric, comparison (>, <, …), value, and for_seconds — the condition must hold that long before firing (debounces noisy sensors).
statusA device changes statustarget status (online / offline); scope to a device type or specific devices.
scheduleA cron expression matchescron in your org's timezone (Settings → Org timezone), evaluated at minute granularity.

Conditions

Optional expression nodes between trigger and actions. All clauses must pass (value > 30, comparisons against the triggering metric, device fields, and constants). Use them to narrow a broad trigger — for example only alert for devices tagged production.

Actions

ActionWhat it does
alertOpens an alert in the Alerts page with severity (info / warning / critical), templated title and body.
commandSends a command to a device (e.g. set_lamp {on: true}) — closes the loop from sensing to actuation.
webhookPOSTs a templated JSON body to your URL — Slack, PagerDuty, or your own service.
emailSends a templated email to the addresses you list. Requires an email provider key (RESEND_API_KEY); until one is configured the action is recorded in the rule run but not delivered.
delayWaits N seconds before running the actions after it.

Templates support variables like {{rule.name}}, {{device.name}}, {{metric}}, {{value}}, and {{ts}}.

Cooldown & debounce

  • Cooldown (cooldown_s, per rule): after firing, the rule stays quiet for this long — prevents alert storms from a flapping sensor.
  • for_seconds (telemetry trigger): the threshold must hold continuously for this long before the rule fires at all.

Tips

  • New rules start disabled — build the flow, then flip the switch.
  • Every run is recorded with its trigger payload and per-action results — check the rule's run history when debugging.
  • Start with one high-value rule: "alert me when anything goes offline" catches most fleet problems.