Ping API

Send heartbeats and progress updates from your cron jobs

Use these endpoints from your cron jobs to monitor execution. Available on all plans. For programmatic management of jobs and workspaces, see the Management API (Business plan).

Prefer an SDK? We have official libraries for PHP, Node.js, Python, Ruby, and Go. View SDK documentation →

Endpoints

POST /ping/{job_key} Simple heartbeat — signal job completed
POST /ping/{job_key}/start Mark job as started, begin execution timer
POST /ping/{job_key}/end/success Mark job as finished successfully
POST /ping/{job_key}/end/fail Mark job as failed
POST /ping/{job_key}/progress/{seq} Progress update with percentage (0–100)
POST /ping/{job_key}/progress Progress update with message only
Language:

Simple ping

Send a single heartbeat when your job completes. No start/end tracking needed.

POST https://cronbeats.io/ping/{job_key}
curl -X POST https://cronbeats.io/ping/abc123de

Start & end signals

Signal when a job starts and when it finishes. Enables execution time tracking and stuck-job detection.

POST https://cronbeats.io/ping/{job_key}/start

Marks job as started and begins the execution timer.

curl -X POST https://cronbeats.io/ping/abc123de/start
POST https://cronbeats.io/ping/{job_key}/end/{status}

Marks job as finished. Use end/success when the job succeeded, or end/fail when it failed.

Example with both variants:

# On success
curl -X POST https://cronbeats.io/ping/abc123de/end/success

# On failure
curl -X POST https://cronbeats.io/ping/abc123de/end/fail

Advanced: start → run job → end (one command)

Wrap your script so execution time is tracked end-to-end. Replace YOUR_KEY with your job key and ./backup.sh with your command.

curl -sS -X POST https://cronbeats.io/ping/YOUR_KEY/start && ./backup.sh && curl -sS -X POST https://cronbeats.io/ping/YOUR_KEY/end/success

Progress tracking

Send percentage and/or status messages while your job runs. Two modes depending on your use case.

Mode 1 — With percentage

POST /progress/{seq}

Body: {"message": "..."}

Dashboard shows a progress bar (0–100) alongside your message.

Use when you can calculate meaningful progress — e.g. processed 50 of 100 records.

Mode 2 — Message only

POST /progress

Body: {"message": "..."}

Dashboard shows only your status message — no percentage bar.

Use when progress isn't measurable — e.g. "Connecting to database..."

Note: Both modes require Content-Type: application/json. The seq value (0–100) goes in the URL path, not the request body.

Progress endpoint reference

POST https://cronbeats.io/ping/{job_key}/progress/{seq} (with percentage)
POST https://cronbeats.io/ping/{job_key}/progress (message only)
Parameter Type Description
seq integer (0–100), URL path Progress percentage. Include in URL path like /progress/50 to show a percentage bar. Omit for message-only mode.
message / msg string, JSON body Status text in POST body as JSON: {"message": "Step 2/4"}. Max 255 characters.
curl -X POST "https://cronbeats.io/ping/abc123de/progress/50" \
  -H "Content-Type: application/json" \
  -d '{"message": "Processing batch 50/100"}'

Examples

Copy and adapt these examples. Replace YOUR_KEY with your job's ping key from the dashboard.

1. Backup with percentage

Run backup steps and report progress after each stage.

#!/bin/bash
PING_URL="https://cronbeats.io/ping/YOUR_KEY"
curl -sS -X POST $PING_URL/start
curl -sS -X POST "$PING_URL/progress/10" -H "Content-Type: application/json" -d '{"message":"Starting backup"}'
pg_dump -U user mydb > backup.sql
curl -sS -X POST "$PING_URL/progress/40" -H "Content-Type: application/json" -d '{"message":"Database dump complete"}'
gzip -f backup.sql
curl -sS -X POST "$PING_URL/progress/70" -H "Content-Type: application/json" -d '{"message":"Compression complete"}'
aws s3 cp backup.sql.gz s3://my-bucket/
curl -sS -X POST "$PING_URL/progress/90" -H "Content-Type: application/json" -d '{"message":"Upload complete"}'
curl -sS -X POST "$PING_URL/progress/100" -H "Content-Type: application/json" -d '{"message":"Done"}'
curl -sS -X POST $PING_URL/end/success

2. Processing records

Update progress every N records in a loop.

PING_URL="https://cronbeats.io/ping/YOUR_KEY"
TOTAL=10000
curl -sS -X POST $PING_URL/start
for ((i=1;i<=TOTAL;i++)); do
  # process_record $i
  if (( i % 500 == 0 )); then
    pct=$(( i * 100 / TOTAL ))
    curl -sS -X POST "$PING_URL/progress/$pct" -H "Content-Type: application/json" -d "{\"message\":\"Processed $i / $TOTAL\"}"
  fi
done
curl -sS -X POST $PING_URL/end/success

3. Multi-step pipeline

Report progress for each step in an ETL or pipeline.

PING_URL="https://cronbeats.io/ping/YOUR_KEY"
curl -sS -X POST $PING_URL/start
curl -sS -X POST "$PING_URL/progress/0"  -H "Content-Type: application/json" -d '{"message":"Step 1/4: Extract"}'
# extract...
curl -sS -X POST "$PING_URL/progress/25" -H "Content-Type: application/json" -d '{"message":"Step 2/4: Transform"}'
# transform...
curl -sS -X POST "$PING_URL/progress/50" -H "Content-Type: application/json" -d '{"message":"Step 3/4: Load"}'
# load...
curl -sS -X POST "$PING_URL/progress/100" -H "Content-Type: application/json" -d '{"message":"Step 4/4: Done"}'
curl -sS -X POST $PING_URL/end/success

What you see on the dashboard

  • Live progress bar — percentage you send, updated in real time
  • Current status message — your latest message string
  • Elapsed time — time since /start
  • Progress timeline — full history of updates for the current run
Dashboard showing Progress column with 65% and status message

Response codes

Code Meaning
200Success — signal recorded
400Invalid route, key format, or payload
404Job key not found or disabled
429Rate limit exceeded
500Service unavailable or processing failed