diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/index.ts | 4 | ||||
| -rw-r--r-- | src/sheets.ts | 3 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/index.ts b/src/index.ts index 4edfc2f..3f0c7ef 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,6 +1,7 @@ import { App } from "@tinyhttp/app"; import { logger } from "@tinyhttp/logger"; import config from "./config"; +import { broadcast } from "./sheets"; import { bot } from "./tg"; const app = new App({ @@ -20,7 +21,8 @@ app .get("/", async (_, res) => { res.send({ service: "hommabot2 API" }); }) - .post("/scheduler/trigger", (_req, res) => { + .post("/scheduler/trigger", async (_req, res) => { + await broadcast(); res.send({ scheduler: "trigger" }); }); diff --git a/src/sheets.ts b/src/sheets.ts new file mode 100644 index 0000000..a03e349 --- /dev/null +++ b/src/sheets.ts @@ -0,0 +1,3 @@ +export const broadcast = async (): Promise<void> => { + // TODO +}; |
