Documentation

Alerts

Needs a person, machine offline, failed job, failing check; Slack, signed webhooks and email.

The four alert types

An alert is a condition worth a person's attention. The cloud raises four kinds; each is listed on the Alerts page while it is open, and list_alerts lists them (state: resolved for the recently resolved ones). The dashboard's overview and describe_cloud count the open ones.

TypeOpens whenResolves
needs_humanAn agent needs a person
A job is waiting for a person: an open question, or a run that ended needing one.On its own when the job is answered (answer_job, the dashboard), or when dismissed.
machine_offlineA machine went offline
A machine missed its next poll; the alert says when it was last seen and what waits for it.On its own when the machine syncs again.
job_failedA job failed
A job ended failed or timed out; the alert names the failure kind.When dismissed. A later failure of another job is another alert.
health_failingA health check is failing
A health check on a machine turned to failing; the alert carries the detail and the fix.On its own when the check recovers, or when dismissed.

One alert per condition

Every alert has a fingerprint, and an organisation has at most one open alert per fingerprint: a condition that stays true does not notify twice, and a notification goes out when the alert opens and again when it resolves. Alerts resolve themselves when their condition clears; dismiss_alert and the dashboard resolve one by hand, and it opens again only if the condition clears and recurs.

AlertTypeDescription
needs_human
fingerprint
needs_human:<job>
machine_offline
fingerprint
machine_offline:<machine>
job_failed
fingerprint
job_failed:<job>
health_failing
fingerprint
health_failing:<machine>:<check>

Channels

Admins add channels under Settings → Notifications and choose, per channel, which alert types it gets; a channel can be switched off without removing it, and shows its last delivery or the last error. An API key with fleet:admin can list channels and send a test (list_channels, test_channel), never add one: targets are chosen by a signed-in person only. Without a channel, alerts only show on the Alerts page.

KindTargetWhat arrives
slackSlack (incoming webhook)
https://hooks.slack.com/services/…A message with the title, the body and a button to the job or machine; resolved and test messages are marked as such.
webhookWebhook (signed, Standard Webhooks)
Any public HTTPS URLA JSON POST signed with a whsec_ secret shown once when the channel is added. For your own code, or a skillhook skill.
emailEmail
An addressOne email per event, from the service's support inbox, with a link to answer or open.

Deliveries are POSTs with content-type: application/json and a five-second timeout; any 2xx answer counts as delivered, redirects are not followed. A delivery that fails is retried with backoff (1, 2, 4, 8 minutes) and given up after five attempts; the channel shows the error. One organisation's unreachable target never holds up another's.

The signed webhook

A webhook channel POSTs {type, timestamp, data}, where type is alert.opened, alert.resolved or alert.test and data is the alert. The request carries the Standard Webhooks headers, signed with the channel's whsec_… secret, which is shown once when the channel is added. Any Standard Webhooks (or Svix) verifier checks them; so does a skillhook skill, below.

Testing a channel

The Test button on a channel, or test_channel {channel}, sends one sample alert (type needs_human, event alert.test, titled "This is a test notification from Skillhook Cloud") to the target and records on the channel whether it arrived, with the error when it did not. Email tests report when email is not enabled on the deployment.

A skillhook skill that acts on alerts

A machine can act on its own organisation's alerts: point a webhook channel at a skill whose auth is standard-webhooks, with the channel's secret stored on the machine. The skill's when filter keeps resolved and test events from starting a run. The channel's target can be the skill's public URL or its hosted URL; either way the machine verifies the signature itself. The secret must have a name of its own: a skill's secret_env may not name one of skillhook's credentials (SKILLHOOK_ADMIN_TOKEN, SKILLHOOK_CLOUD_*).

Dismissing

dismiss_alert {alert} (members, or a fleet:run key) resolves an open alert by hand; the channels are not told (they are when an alert resolves on its own). Use it for a failed job you have dealt with; answering an agent or bringing a machine back resolves theirs without you.