CognxSafeTrack commited on
Commit ·
b74fcbf
1
Parent(s): bef7a3d
feat(api): add root healthcheck for huggingface proxy
Browse files- apps/api/src/index.ts +4 -0
apps/api/src/index.ts
CHANGED
|
@@ -18,6 +18,10 @@ server.register(adminRoutes, { prefix: '/v1/admin' });
|
|
| 18 |
import { aiRoutes } from './routes/ai';
|
| 19 |
server.register(aiRoutes, { prefix: '/v1/ai' });
|
| 20 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21 |
server.get('/health', async () => {
|
| 22 |
return { status: 'ok', timestamp: new Date().toISOString() };
|
| 23 |
});
|
|
|
|
| 18 |
import { aiRoutes } from './routes/ai';
|
| 19 |
server.register(aiRoutes, { prefix: '/v1/ai' });
|
| 20 |
|
| 21 |
+
server.get('/', async (_req, reply) => {
|
| 22 |
+
return reply.code(200).type('application/json').send({ ok: true });
|
| 23 |
+
});
|
| 24 |
+
|
| 25 |
server.get('/health', async () => {
|
| 26 |
return { status: 'ok', timestamp: new Date().toISOString() };
|
| 27 |
});
|