Add a schedule
Setcron when you register the workflow:
Write a schedule
A schedule has five fields, separated by spaces:
In each field,
* means every value, 1-5 a range, 1,15 a list, and */15 every fifteenth value. Months and days of the week can also be written as names, like JAN or MON-FRI. Times are in UTC.
What a scheduled run receives
A scheduled run has no payload, so the workflow takes no argument. When the work depends on the time, read it in a step, so every call of the run gets the same value:When runs start
- After you add a schedule, the first run starts at the next time it matches, never right away.
- Nelkap checks schedules every minute, so a run starts within a minute of its time.
- If runs couldn’t start for a while, the times missed meanwhile give a single run, not one per missed time.
- A changed schedule applies as soon as your app registers it. The next run follows the new schedule. On a serverless host, your app registers its list on its first request after a deploy. See Register your workflows on every start.
- Removing the schedule, or the workflow, stops the runs.
concurrency: 1.
Run it now
To test a scheduled workflow without waiting for its time, start a run from your code withrun. It runs the same workflow, with no payload.
For a complete scheduled workflow, see the weekly report example.