import type { ToolsInput } from '@mastra/core/agent'; import { MCPServerBase } from '@mastra/core/mcp'; import type { MCPToolExecutionResultV2, MCPToolType, ServerDetailInfo, ServerInfo } from '@mastra/core/mcp'; import type { InternalMastraMCPClient } from './client.js'; type ToolInfo = { id: string; name: string; description?: string; inputSchema: unknown; outputSchema?: unknown; toolType?: MCPToolType; _meta?: Record; }; /** * Wraps a single MCPClient server connection as an `MCPServerBase` so external * (non-Mastra) MCP servers connected through MCPClient can be registered in Mastra's * `mcpServers` config and appear in Studio alongside local MCPServer instances. * * Tool and resource operations are delegated lazily to the underlying connection. * The proxy has no transport of its own: it is not served over stdio or HTTP. */ export declare class MCPClientServerProxy extends MCPServerBase { readonly mcpVersion: 2; private clientGetter; private cachedClient; private cachedToolList; constructor(config: { name: string; version?: string; id?: string; description?: string; }, clientGetter: () => Promise); /** The remote catalogue is fetched lazily; nothing is converted locally. */ convertTools(_tools: ToolsInput): {}; private getClient; private convertSchema; private fetchToolList; getToolListInfo(): { tools: ToolInfo[]; } | Promise<{ tools: ToolInfo[]; }>; getToolInfo(toolId: string): ToolInfo | undefined | Promise; executeTool(toolId: string, input: unknown, context?: Parameters[2]): Promise; listResources(): Promise<{ resources: Array<{ uri: string; name: string; description?: string; mimeType?: string; _meta?: Record; }>; }>; readResource(uri: string): Promise<{ contents: Array<{ uri: string; text?: string; blob?: string; mimeType?: string; _meta?: Record; }>; }>; startStdio(): Promise; startHTTP(): Promise; close(): Promise; getServerInfo(): ServerInfo; getServerDetail(): ServerDetailInfo; } export {}; //# sourceMappingURL=server-proxy.d.ts.map