Integration guide
Every monitor has a unique ping URL. Hit it from your job (with GET or POST) every time it
completes successfully. If we don't see a ping inside interval + grace, we alert.
curl
curl -fsS --retry 3 https://your-beatwatch.example.com/ping/<TOKEN>/
Plain Python
from beatwatch import ping
def nightly_report():
do_the_work()
ping("<TOKEN>") # non-blocking, swallows its own errors
Celery
from beatwatch.celery import monitored_task
@monitored_task("<TOKEN>")
def cleanup_old_records():
OldRecord.objects.filter(stale=True).delete()
# auto-pings on successful return
GitHub Actions
name: nightly
on:
schedule: [{ cron: "0 3 * * *" }]
jobs:
run:
runs-on: ubuntu-latest
steps:
- run: ./your-job.sh
- run: curl -fsS https://your-beatwatch.example.com/ping/$/
Configuration tips
- Set
expected_intervalto your job's nominal cadence in seconds. - Set
grace_periodto a few × the job's worst-case runtime — not just average. - Ping at the end of the job, after the work has actually succeeded.