The function to run. payload is provided when triggered via pop.schedule().
Optionalpayload: anyOptionalnameA unique name for this task. Used when scheduling it via pop.schedule().
OptionalscheduleCron expression (e.g. "0 9 * * *" for every day at 9am). Omit for on-demand-only tasks.
OptionaltimezoneIANA timezone name (e.g. "America/New_York"). Defaults to UTC.
OptionaloverlapAllow concurrent runs of this task. Defaults to false (skips if previous run is still active).
OptionalretriesNumber of times to retry on failure. Defaults to 0.
OptionalretryMilliseconds to wait between retries. Defaults to 1000.
OptionaltimeoutMaximum execution time in ms before the run is considered timed out.
The definition of a scheduled background task.
Use the task builder function to create one with full type inference. Tasks are auto-loaded from
src/tasks/and can also be triggered on demand viapop.schedule("task-name", payload, delayMs).