Tell your agent what should run and when. It creates the job, reads the run history when one fails, and runs it again. Or do it all from the dashboard.
MIT licensed · Cloudflare Workers or Docker
Describe the job to Claude, Cursor or any MCP client. It writes the script, sets the schedule and runs it once to check. When a run fails, it reads the result and fixes the job. A read key lets it look; a write key lets it change things.
claude mcp add --transport http opencron \ https://opencron.example.com/api/mcp \ --header "Authorization: Bearer oc_…"
A reboot, a rescheduled container, a script that throws. crontab stays quiet, and you find out days later when someone asks why the numbers stopped updating.
When did it last run, how long did it take, what did it print? The logs live on whichever box ran it, and debugging one failure starts with SSH.
Serverless and edge apps have no long-running process. Keeping a server alive for a handful of scheduled tasks means one more thing that can go down.
Every job, every run and every alert channel in one dashboard, and the same things over the REST API and MCP.
Write any five-field expression or start from a preset, and see the next five runs before you save. Schedules run in UTC; times are shown in your browser's time zone.
Status, duration and the first 500 characters of the response are kept for 7 days. Run a job by hand at any time, or let your agent do it.
When a run fails, OpenCron posts to Slack, Discord, Telegram, Lark, DingTalk or any webhook. Failures within a minute of each other are sent once.
Secrets are stored encrypted and reach scripts as environment variables. Agents can list their names and set new values, but never read one back.
Not every job is an API call. Write a script and OpenCron runs it on your schedule, isolated from everything else.
// Count the runs of this job in its own KV store
export default {
async fetch(request, env) {
const { jobName, scheduledAt } = await request.json();
const runs = Number((await env.KV.get("runs")) ?? 0) + 1;
await env.KV.put("runs", String(runs));
return new Response(`${jobName}: run ${runs} at ${scheduledAt}`);
},
};OpenCron is MIT licensed. Deploy it to Cloudflare Workers with D1, or run it anywhere with Docker and Postgres. Your jobs and their history stay in your own database.
# clone and start git clone https://github.com/becoolme/opencron cd opencron && cp .env.docker.example .env # replace every change-me value in .env docker compose up -d --build # open http://localhost:8080 and create the first account
Create a job in a minute, or ask your agent to.