REST API
Manage your cron jobs programmatically, in JSON.
Authentication
Create a key in Account › API key and send it in the Authorization: Bearer header (or X-API-Key).
curl -H "Authorization: Bearer 7c_xxxxxxxx…" https://7cron.com/api/v1/me
Limit: 120 requests per minute. Dates are in UTC (ISO 8601). API access may be an add-on depending on your plan.
Endpoints
| GET /me | Your account and limits |
| GET /jobs | List your jobs |
| POST /jobs | Create a job (HTTP or heartbeat) |
| GET /jobs/{id} | Job details |
| PATCH /jobs/{id} | Edit a job (only the fields sent) |
| DELETE /jobs/{id} | Delete a job and its history |
| POST /jobs/{id}/run | Run an HTTP job now |
| POST /jobs/{id}/pause | Pause a job |
| POST /jobs/{id}/resume | Resume a job |
| GET /jobs/{id}/logs?limit=50 | Latest runs (max. 500) |
Base URL : https://7cron.com/api/v1
Example and fields
Same fields and rules as the web form:
curl -X POST https://7cron.com/api/v1/jobs \
-H "Authorization: Bearer 7c_xxxxxxxx…" -H "Content-Type: application/json" \
-d '{"name":"Nightly backup","url":"https://example.com/cron/backup",
"method":"POST","cron_expr":"0 3 * * *","timezone":"Europe/Zurich",
"timeout":30,"retries":1,"alert_threshold":3,"success_keyword":"OK"}'
# Heartbeat
curl -X POST https://7cron.com/api/v1/jobs -H "Authorization: Bearer 7c_…" -H "Content-Type: application/json" \
-d '{"type":"heartbeat","name":"Backup script","hb_period_min":1440,"hb_grace_min":30}'
type, name, url, method, headers, body, cron_expr, timezone, timeout, enabled, notify_on_failure, notify_chat, alert_threshold, webhook_url, success_keyword, keyword_mode (contains|absent), retries, hb_period_min, hb_grace_min, on_status_page
Errors
{"error": {"code": 422, "message": "Validation failed.", "fields": {"cron_expr": "…"}}}
Codes: 400 invalid JSON, 401 missing key, 403 not allowed, 404 not found, 405 method, 422 validation, 429 rate limit.