/** * @file health.routes.ts * @description HTTP route registration for health and readiness endpoints. */ import type { HealthOptionsInterface } from '../common'; import type { HealthService } from './health.service'; /** * Minimal server interface for route registration. * Avoids importing the full FrontMcpServerInstance to prevent circular dependencies. */ export interface HealthRouteServer { registerRoute(method: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD', path: string, handler: (req: unknown, res: { status(code: number): { json(payload: unknown): void; }; }) => Promise | void): void; } /** * Determine if the readyz endpoint should be enabled based on runtime. * * Auto-detection rules (when readyz.enabled is not explicitly set): * - Edge/Cloudflare/Vercel (serverless): disabled (no persistent connections) * - Node.js, Bun, Deno, Browser: enabled */ export declare function isReadyzEnabled(config: HealthOptionsInterface): boolean; /** * Register health and readiness HTTP routes on the server. * * Registers: * - `GET /healthz` (or custom path) — liveness probe * - `GET /readyz` (or custom path) — readiness probe (runtime-conditional) * - `GET /health` — legacy alias for /healthz (backwards compatibility) */ export declare function registerHealthRoutes(server: HealthRouteServer, healthService: HealthService, config: HealthOptionsInterface): void; //# sourceMappingURL=health.routes.d.ts.map