/**
 * Health Check Endpoint
 * Provides system health status for monitoring and load balancers.
 * Ported from Python deployment/health_check.py
 */
export type HealthStatus = 'healthy' | 'degraded' | 'unhealthy' | 'unknown';
export interface ComponentHealth {
    status: HealthStatus;
    latency_ms?: number | null;
    error?: string;
    warning?: string | null;
    [key: string]: unknown;
}
export interface MemoryHealth extends ComponentHealth {
    used_percent?: number;
    used_mb?: number;
    free_mb?: number;
    total_mb?: number;
}
export interface DiskHealth extends ComponentHealth {
    used_percent?: number;
    used_gb?: number;
    free_gb?: number;
    total_gb?: number;
}
export interface WebSocketHealth extends ComponentHealth {
    active: number;
    max: number;
    usage_percent: number;
}
export interface FullHealthCheck {
    status: HealthStatus;
    timestamp: number;
    uptime_seconds: number;
    checks: {
        database: ComponentHealth;
        memory: MemoryHealth;
        websockets: WebSocketHealth;
    };
}
/**
 * Performs health checks on various system components.
 */
export declare class HealthChecker {
    private startTime;
    private lastCheck;
    constructor();
    /**
     * Get server uptime in seconds.
     */
    getUptime(): number;
    /**
     * Check database connectivity and performance.
     */
    checkDatabase(): Promise<ComponentHealth>;
    /**
     * Check memory usage.
     */
    checkMemory(): MemoryHealth;
    /**
     * Check WebSocket connection health.
     */
    checkWebSocketConnections(activeConnections: number, maxConnections?: number): WebSocketHealth;
    /**
     * Perform a comprehensive health check.
     */
    performFullCheck(activeConnections?: number): Promise<FullHealthCheck>;
}
export declare function getHealthChecker(): HealthChecker;
/**
 * Simple liveness probe - checks if the service is running.
 */
export declare function livenessProbe(): Promise<boolean>;
/**
 * Readiness probe - checks if the service is ready to accept traffic.
 */
export declare function readinessProbe(activeConnections?: number): Promise<boolean>;
/**
 * Create an Express-compatible health check handler.
 *
 * Usage with Express:
 *   app.get('/health', createHealthHandler());
 */
export declare function createHealthHandler(): (req: {
    query?: {
        connections?: string;
    };
}, res: {
    status: (code: number) => {
        json: (data: unknown) => void;
    };
}) => Promise<void>;
export declare const healthCheck: {
    HealthChecker: typeof HealthChecker;
    getHealthChecker: typeof getHealthChecker;
    livenessProbe: typeof livenessProbe;
    readinessProbe: typeof readinessProbe;
    createHealthHandler: typeof createHealthHandler;
};
//# sourceMappingURL=health_check.d.ts.map