/** * @license * Copyright 2026 Steven Roussey * SPDX-License-Identifier: Apache-2.0 */ import type { Command } from "commander"; import { type Server } from "node:http"; import { RunRegistry } from "./RunRegistry"; export interface WebServerHandle { readonly server: Server; readonly registry: RunRegistry; readonly url: string; readonly token: string; readonly close: () => Promise; } export interface StartWebServerArgs { readonly port: number; readonly host: string; readonly program: Command; readonly binaryName: string; readonly binary: readonly string[]; readonly cwd: string; readonly logDir: string; readonly token?: string; } /** * `node:http` rather than `Bun.serve`, so one implementation serves both * runtimes: the CLI runs under Bun and the tests run under Node. */ export declare function startWebServer(args: StartWebServerArgs): Promise;