Skip to content

Commit 78ad63c

Browse files
committed
Add scheduled
1 parent af4c0e2 commit 78ad63c

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/components/Apiker/Apiker.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ export class Apiker {
4949
authRoutes = false,
5050
name = "Apiker",
5151
email,
52-
debug
52+
debug,
53+
scheduled,
5354
} = options;
5455

5556
/**
@@ -100,7 +101,8 @@ export class Apiker {
100101
*/
101102
const workerExports = {
102103
handlers: {
103-
fetch: handleEntryRequest
104+
fetch: handleEntryRequest,
105+
scheduled,
104106
}
105107
};
106108

src/components/Apiker/interfaces.ts

+1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ export interface Options {
2424
adminPanel?: boolean;
2525
name?: string;
2626
email?: EmailOptions;
27+
scheduled?: (event: any, env: any, ctx: any) => Promise<void>;
2728
}
2829

2930
export type Timings = { [timingName: string]: number };

0 commit comments

Comments
 (0)