/** * Cursor MCP injector. * * `cursor-agent` auto-loads MCP servers declared in `~/.cursor/mcp.json` * (global) or `.cursor/mcp.json` (per-workspace). The shape matches the * Claude / Gemini / generic MCP-host convention: * * { * "mcpServers": { * "": { "command": "...", "args": [...], "env": {...} } * } * } * * On adapter init we read-modify-write the global file so the `agim` * entry always points at the live approval-bus socket (which rotates * every agim restart — see core/approval-bus.ts). Other entries the * operator already had stay untouched. * * Per-workspace .cursor/mcp.json is left untouched on purpose — that * file belongs to the project the operator opened cursor in, not agim. */ /** Resolves to `${HOME}/.cursor/mcp.json`. Exported so tests can point * at a tmp dir. */ export declare function defaultMcpConfigPath(): string; export interface McpServerSpec { command: string; args?: string[]; env?: Record; } /** * Ensure `~/.cursor/mcp.json` has the agim MCP entry pointing at the * current approval-bus socket. Idempotent: safe to call on every * adapter init or before every spawn. Preserves any other keys / * mcpServers entries the operator already configured. */ export declare function ensureAgimMcp(spec: McpServerSpec, opts?: { path?: string; }): Promise; /** Remove the agim MCP entry. Used by tests / uninstall flows. */ export declare function removeAgimMcp(opts?: { path?: string; }): Promise; //# sourceMappingURL=ensure-mcp-config.d.ts.map