Guide · Get notified
Receive alerts by webhook
Point Mortemain at your own URL and every alert arrives there as a JSON POST, ready to feed your own tooling, an incident system or a no-code flow. Looking for the other direction, a job or an app calling Mortemain to check in? That is the check-in webhook guide.
1. Have an endpoint ready
Any https URL that accepts a POST and answers with a 2xx status within 8 seconds: your own service, a serverless function, or a catch hook in a no-code tool (n8n Webhook node, Zapier Webhooks by Zapier → Catch Hook, Make Webhooks → Custom webhook).
It must be reachable from the internet: Mortemain refuses private and internal addresses, and does not follow redirects, so give it the final URL.
2. Add the target in Mortemain
In your Mortemain dashboard, add a notification target:
- Type → Webhook
- Name → anything you'll recognise, e.g. Incident bridge
- URL → your endpoint
Save, then wire it to the checks you care about.
3. What Mortemain sends
On every state change of a wired check, one POST with Content-Type: application/json and an Idempotency-Key header:
{
"check": "Nightly backup",
"check_id": "6f1c2b9e-0d4a-4e8b-9a51-2c7f3e1d8b40",
"transition": "down",
"title": "🔴 Nightly backup · DOWN",
"body": "Mortemain: \"Nightly backup\" is DOWN (missed its expected check-in) as of 2026-10-19 02:30 GMT+2.",
"at": "2026-10-19T00:30:00.000Z",
"at_local": "2026-10-19 02:30 GMT+2",
"idempotency_key": "4812:1"
}
- transition: what happened, as a stable code that is never translated. Branch on this one.
down(missed its check-in, grace over),late(overdue, still inside grace),fail(the job reported a failure),up(recovered),flapping(keeps toggling between healthy and late or down),auth_reject(a check-in was refused; only if you turned that alert on for the check). - check and check_id: the check's name and its stable id (the one in the check's dashboard URL).
- title and body: ready-to-display text, in the language of the project owner.
- at: when it happened, ISO 8601 in UTC. at_local: the same instant in the project owner's timezone.
- idempotency_key: the same value as the header.
4. Delivery and retries
Any 2xx answer counts as delivered. Anything else, a timeout or a redirect counts as a failure and is retried with a growing delay (30 seconds, then doubling, at most an hour apart), up to 8 attempts. A target that keeps failing shows an undelivered count on your dashboard.
Each attempt carries its own Idempotency-Key: receiving the same key twice means the same attempt arrived twice, so drop the duplicate. Answer quickly and do the real work afterwards, so a slow reply never turns into a retry.
Test it
Hit Test on the target. Your endpoint receives a sample alert for a check named Mortemain test alert, with transition up. If it does not arrive, the target shows the error your endpoint returned.