This repository has been archived on 2024-10-29. You can view files and clone it, but cannot push or open issues or pull requests.
Liam cb7143ed3d
Some checks failed
Deploy Backend / deploy (push) Successful in 3m38s
Deploy Website / deploy (push) Has been cancelled
should be all good now (and added api status notifications)
2024-10-16 08:15:11 +01:00

27 lines
534 B
TypeScript

import { Controller, Get } from "elysia-decorators";
import { getAppVersion } from "../common/app-utils";
import { AppService } from "../service/app.service";
@Controller()
export default class AppController {
@Get("/")
public async index() {
return {
app: "backend",
version: await getAppVersion(),
};
}
@Get("/health")
public async getHealth() {
return {
status: "OK",
};
}
@Get("/statistics")
public async getStatistics() {
return await AppService.getAppStatistics();
}
}