API Documentation

Integrate CronSpark directly into your CI/CD pipelines, applications, and custom dashboards.

Authentication

All API requests require a valid API key passed in the Authorization header as a Bearer token.

Authorization: Bearer csk_live_123456789...

Base URL

https://cronspark.com/api/v1

Endpoints

List all jobs

GET /jobs

Returns a list of all your scheduled jobs and heartbeat monitors.

Create a job

POST /jobs

Payload example:

{
  "name": "Database Backup",
  "url": "https://api.yoursite.com/backup",
  "schedule": "0 0 * * *",
  "method": "POST",
  "timezone": "UTC"
}

Trigger a heartbeat

POST /ping/:uuid

Call this endpoint from your scripts to signal that a job completed successfully.

Webhooks

CronSpark can send out webhooks when a job fails or recovers. All outgoing webhooks are signed using HMAC-SHA256. You can verify the signature using the x-cronspark-signature header.

Status badges

Embed a live status badge for any job in your README, dashboard, or docs. The badge is an SVG that always reflects the job's most recent run (passing, failing, timeout, paused, or pending).

https://cronspark.com/api/v1/jobs/:id/badge

Markdown (links the badge back to CronSpark):

[![Job status](https://cronspark.com/api/v1/jobs/JOB_ID/badge)](https://cronspark.com)

HTML:

<a href="https://cronspark.com"><img src="https://cronspark.com/api/v1/jobs/JOB_ID/badge" alt="Job status" /></a>

Rate Limits

The API is rate-limited to 60 requests per minute per API key. If you exceed this limit, you will receive a 429 Too Many Requests response.