Files
lstV2/server/services/ocme/ocmeService.ts

20 lines
517 B
TypeScript

import {OpenAPIHono} from "@hono/zod-openapi";
// routes
import getInfo from "./route/getInfo.js";
import postRunningNr from "./route/postRunningNumber.js";
const app = new OpenAPIHono();
const routes = [getInfo, postRunningNr] as const;
// app.route("/server", modules);
const appRoutes = routes.forEach((route) => {
app.route("/api/v1", route);
});
app.all("/api/v1/*", (c) => {
return c.json({success: false, message: "you have encounted an ocme route that dose not exist."});
});
export default app;