import type { Orckit } from '../orchestrator/orchestrator.js'; export interface McpServerOptions { /** Port to bind. Use 0 to pick an arbitrary free port (handy for tests). */ port: number; /** Host to bind. Defaults to 127.0.0.1; only override for non-localhost setups. */ host?: string; /** Path component of the MCP endpoint. Defaults to "/mcp". */ path?: string; } export interface McpServerHandle { /** Full URL clients should connect to (e.g. "http://127.0.0.1:7676/mcp"). */ readonly url: string; /** The bound port (resolved if options.port was 0). */ readonly port: number; /** Stop listening, close all open streams, detach event listeners. */ dispose(): Promise; } /** * Attach an in-process MCP server to an Orckit instance. The server exposes * read-only tools (`get_status`, `get_errors`, `get_logs`, `get_build_status`, * `wait_for_build`) over Streamable HTTP and is intended to be hit by Claude * Code or any other MCP client. * * Returns a handle whose `dispose()` cleanly closes the HTTP listener and * tears down the MCP transport. Throws on `EADDRINUSE` so the caller can * surface a useful "port busy" message — does NOT silently fall back to a * random port, since that would break clients with a static URL config. */ export declare function attachMcpServer(orckit: Orckit, opts: McpServerOptions): Promise; //# sourceMappingURL=server.d.ts.map