import { r as KlawConfig } from "./types.klaw-xKUw_Rz7.js"; import { r as AnyAgentTool } from "./common-BtCut1Uo.js"; import { TSchema } from "typebox"; import { CallToolResult } from "@modelcontextprotocol/sdk/types.js"; //#region src/agents/pi-bundle-mcp-types.d.ts type BundleMcpToolRuntime = { tools: AnyAgentTool[]; dispose: () => Promise; }; type McpServerCatalog = { serverName: string; launchSummary: string; toolCount: number; }; type McpCatalogTool = { serverName: string; safeServerName: string; toolName: string; title?: string; description?: string; inputSchema: TSchema; fallbackDescription: string; }; type McpToolCatalog = { version: number; generatedAt: number; servers: Record; tools: McpCatalogTool[]; }; type SessionMcpRuntime = { sessionId: string; sessionKey?: string; workspaceDir: string; configFingerprint: string; createdAt: number; lastUsedAt: number; activeLeases?: number; acquireLease?: () => () => void; getCatalog: () => Promise; markUsed: () => void; callTool: (serverName: string, toolName: string, input: unknown) => Promise; dispose: () => Promise; }; type SessionMcpRuntimeManager = { getOrCreate: (params: { sessionId: string; sessionKey?: string; workspaceDir: string; cfg?: KlawConfig; }) => Promise; bindSessionKey: (sessionKey: string, sessionId: string) => void; resolveSessionId: (sessionKey: string) => string | undefined; disposeSession: (sessionId: string) => Promise; disposeAll: () => Promise; sweepIdleRuntimes: () => Promise; listSessionIds: () => string[]; }; //#endregion export { SessionMcpRuntime as n, SessionMcpRuntimeManager as r, BundleMcpToolRuntime as t };