agentskit.js

CronSchedulerOptions

Auto-generated API reference for CronSchedulerOptions.

Interface: CronSchedulerOptions<TContext>

Defined in: background.ts:24

#Type Parameters

#TContext

TContext = unknown

#Properties

#jobs

jobs: CronJob<TContext>[]

Defined in: background.ts:25


#now?

optional now?: () => Date

Defined in: background.ts:35

Clock override for tests.

#Returns

Date


#onEvent?

optional onEvent?: (event) => void

Defined in: background.ts:27

Observability hook.

#Parameters

event
error?

string

job

string

now

Date

result?

string

type

"tick" | "run:start" | "run:end" | "run:error"

#Returns

void


#scheduleTick?

optional scheduleTick?: (fn) => () => void

Defined in: background.ts:37

Timer override for tests — takes tick handler, returns stop fn.

#Parameters

fn

() => void

#Returns

() => void

Explore nearby

✎ Edit this page on GitHub·Found a problem? Open an issue →·How to contribute →

On this page