| 1 | /** |
| 2 | * Reserved entry-socket path that triggers the user worker's `scheduled()` |
| 3 | * handler, mirroring Miniflare's `CorePaths.SCHEDULED` |
| 4 | * (`workers-sdk/packages/miniflare/src/workers/core/constants.ts`). |
| 5 | * |
| 6 | * Query parameters (all optional, matching Miniflare's |
| 7 | * `workers/core/scheduled.ts`): |
| 8 | * - `cron` — the cron expression reported on `controller.cron` |
| 9 | * - `time` — epoch milliseconds reported on `controller.scheduledTime` |
| 10 | * - `format=json` — respond with the full `FetcherScheduledResult` JSON |
| 11 | * instead of the plain-text outcome |
| 12 | */ |
| 13 | export const PATH_SCHEDULED = "/cdn-cgi/handler/scheduled"; |
| 14 | |
| 15 | /** |
| 16 | * Legacy Miniflare path for triggering scheduled handlers |
| 17 | * (`CorePaths.LEGACY_SCHEDULED`). Kept for compatibility with older tooling. |
| 18 | */ |
| 19 | export const PATH_SCHEDULED_LEGACY = "/cdn-cgi/mf/scheduled"; |