Cron Jobs
Cron and scheduled tasks fail silently more often than teams expect. Seiri watches for the check-in, not the host’s uptime.
Where this lives in the product
- Create the monitor under Core → Webhooks with type Cron (or Periodic for fixed intervals).
- Copy the endpoint URL from the ENDPOINT column.
- Review schedule adherence under Services → Cron Jobs and per-webhook stats.
Monitoring pattern
- Run the job.
- On success, GET/POST
https://ping.seiri.app/webhook/<endpoint-id>/success. - On failure, GET/POST
.../fail(optional but recommended). - Keep the ping timeout short and swallow ping errors so monitoring never takes down the job.
<endpoint-id> is the webhook endpoint ID (org-slug:webhook-ref), not a random token.
Example (Node.js)
import fetch from "node-fetch";
const SEIRI_BASE = process.env.SEIRI_BASE_URL;
// e.g. https://ping.seiri.app/webhook/acme-demo:deno-xFY-7Yv
async function scheduledTask() {
// Task logic ...
await fetch(`${SEIRI_BASE}/success`, { method: "GET" });
}
scheduledTask();
Example (crontab)
0 2 * * * /usr/local/bin/backup.sh && curl -fsS -m 10 https://ping.seiri.app/webhook/acme-demo:YOUR_REF/success || curl -fsS -m 10 https://ping.seiri.app/webhook/acme-demo:YOUR_REF/fail
See also: Integrate a job.