cron
Source:
src/Cloudflare/Workers/CronEventSource.ts
Subscribe to Cloudflare Cron Triggers with an Effect handler.
This wires both pieces of a scheduled Worker:
- Runtime: registers a
scheduledlistener on the Worker. - Deploy-time: attaches the cron expression to the host Worker.
Examples
Section titled “Examples”yield* Cloudflare.cron("0 12 * * *").subscribe((controller) => Effect.log(`scheduled at ${controller.scheduledTime}`),);