- Install @elysia/openapi to auto-generate API docs at /api/openapi - Install @elysia/cron for in-process scheduled jobs (orphan detection at 2am, storage cleanup at 3am) - Add Scalar UI docs with 14 tag groups and Bearer JWT security scheme - Add route-level detail annotations (tags, summaries) to all 30+ route files - Upgrade crud-builder to accept optional tags config - Keep HTTP cron endpoint as manual/admin fallback
20 lines
380 B
TypeScript
20 lines
380 B
TypeScript
import { Elysia } from "elysia"
|
|
|
|
export const healthRoutes = new Elysia({
|
|
prefix: "/health",
|
|
detail: { tags: ["Health"] },
|
|
}).get(
|
|
"/",
|
|
() => ({
|
|
status: "ok",
|
|
timestamp: new Date().toISOString(),
|
|
service: "deckyvault-api",
|
|
}),
|
|
{
|
|
detail: {
|
|
summary: "Health check",
|
|
description: "Returns the current health status of the API.",
|
|
},
|
|
},
|
|
)
|