/** * Port Management Utilities * * Functions for checking port availability, cleanup, and HTTP shutdown. */ declare function canBind(port: number): Promise; declare function attemptHttpShutdown(port: number): Promise; declare function killPidBestEffort(pid: number, opts: { force: boolean; }): void; /** * Ensure a TCP port is available by attempting graceful shutdown of any process holding it, * then force-killing as a last resort. */ declare function ensurePortAvailable(port: number, opts?: { attemptGraceful?: boolean; restartInPlaceOnly?: boolean; }): Promise<'available' | 'handled_existing_server'>; export { ensurePortAvailable, killPidBestEffort, canBind, attemptHttpShutdown };