Skip to main content
worker.observe({ function_id: "cron::on-tick", args: { expression } }, target) means: when the cron worker ticks for expression, target runs. The cron worker starts a job for each expression its observers ask for, and stops it when the last observer of that expression goes away. expression has seven fields: second, minute, hour, day of month, month, day of week, and year. This observer runs reports::daily-summary every day at 09:00:00:
With capture: ["input"], the target receives the tick as the payload’s input: { expression, scheduled_time, actual_time }. An expression the cron worker cannot parse rejects the observer with INVALID_CRON_EXPRESSION.