feat(backend): scaffold Express API with health and module layout

Add src/routes/notifications, services/pushService, models/device,
scheduler stubs, and entrypoint with GET /health and startup log.
This commit is contained in:
Jose Olarte III
2026-05-11 14:33:32 +08:00
commit 94c38bac74
9 changed files with 1593 additions and 0 deletions

16
src/scheduler.ts Normal file
View File

@@ -0,0 +1,16 @@
let intervalId: ReturnType<typeof setInterval> | undefined;
export function startScheduler(): void {
if (intervalId !== undefined) return;
// TODO: replace with job queue or cron for wake-up checks
intervalId = setInterval(() => {
// placeholder tick
}, 60_000);
}
export function stopScheduler(): void {
if (intervalId !== undefined) {
clearInterval(intervalId);
intervalId = undefined;
}
}