cron.schedule

schedule(name: string, expression: string, handler: ScheduledTaskHandler)

Runs a task from a five-field cron expression in UTC.

Fields are minute, hour, day of month, month, and day of week. Use *, comma-separated values, ranges, and / steps. Sunday is 0 or 7. When both day fields are restricted, either may match. Named values, macros, and extensions such as L, #, and ? are not accepted.

Example: weeble.cron.schedule('daily-report', '0 9 * * *', handler) runs every day at 09:00 UTC.