on this page

GlossaryWhat is a cron expression?

What is a cron expression?

A cron expression is a short line of text that describes a repeating schedule, such as "every five minutes" or "09:00 on weekdays". It comes from cron, the Unix job scheduler, and the same five-field format is used by most scheduled-job systems.


How it works

The five fields, separated by spaces, are minute, hour, day of month, month and day of week:

┌──────── minute (0-59)
│ ┌────── hour (0-23)
│ │ ┌──── day of month (1-31)
│ │ │ ┌── month (1-12)
│ │ │ │ ┌ day of week
│ │ │ │ │
30 6 * * *

Each field takes a number, a * for every value, a list (0,30), a range (1-5) or a step (*/15, every 15th value). A job runs whenever the current time matches every field. 0 * * * * is the top of every hour, */5 * * * * every five minutes, 0 0 1 * * midnight on the first of each month.

Two things trip people up. First, the time zone: a schedule runs in whatever zone the scheduler uses, which is often UTC rather than your local time. Second, day of week: classic cron counts from 0 for Sunday, but not every system does, so check before you write 1-5. Some systems also accept shorthands like @hourly or extra fields for seconds and years; plain five-field expressions are the portable form.


Cron expressions on Tissue Cloud

Tissue Cloud runs scheduled work with pulse. You add a [[pulse]] block to ribo.toml with a five-field schedule, and export a pulse(event, env) function from the Cell. All schedules are UTC. Day of week counts from 1 for Sunday through 7 for Saturday, so Monday to Friday is 2-6 and a 0 is refused; names such as mon-fri work too. There's no @hourly shorthand. The shortest interval is one minute, a Cell can have up to 25 schedules, and ribo deploy rejects a schedule it can't parse before anything is published.

Pulse overview has the full field table and examples.