/ heartbeat monitoring
Cron job monitoring that alerts when a run is late or fails
A heartbeat is a URL your cron job, queue worker or backup script calls when it finishes. Tell Fettle how often the job runs and how long to wait. When the ping does not come, or the job reports a failure, you get an alert before anyone notices the missing data.
Heartbeats are on every plan, free included. The cron job monitoring guide walks through the setup step by step.
One line at the end of the job
Create a heartbeat with the job’s period, copy its ping URL, and chain a request to it after the command. A plain GET or POST works, with no API key:
0 3 * * * /usr/local/bin/backup.sh && curl -fsS -m 10 --retry 3 https://api.fettle.sh/v1/heartbeat/<token> > /dev/nullThe ping goes out only when the job succeeds, so a crash, a hung run or a server that never started the job all end the same way: a missed deadline and an alert. The heartbeat reference covers period and grace, the /start and /fail pings, and the create API.
What a heartbeat catches
- Late runs
- When a ping does not arrive within the period plus the grace you set, the heartbeat goes down and you get an alert. Fettle checks every 30 seconds.
- Failures the job reports
- A job that knows it failed calls its ping URL with /fail and the alert goes out at once, without waiting for the deadline.
- How long each run took
- Call /start when the job begins and the success ping at the end, and Fettle records the run's duration.
- No alarm before the first run
- A new heartbeat waits for its first ping before it can be late, so creating one ahead of the deploy is safe.
- Recovery alerts
- The next successful ping closes the incident and tells you the job is back.
- From a script or an agent
- Create, pause and resume heartbeats through the API, or ask Claude or Codex to do it over the MCP server.
Where the alert goes
Heartbeat alerts use the same channels as your uptime monitors: email and Telegram on every plan, and Slack, Discord or a signed webhook from Plus. Maintenance windows silence monitors, not heartbeats: before turning a job off, pause its heartbeat.
Plans
Heartbeats per organization: 3 on Free, 20 on Plus, 50 on Pro and 150 on Max. They count separately from monitors. Every plan and limit is on the pricing page.