MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / loadMcpClientSdk

Function loadMcpClientSdk

packages/plugins/mcp/src/sdk/client-module.ts:30–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

28let loading: Promise<McpClientSdk> | undefined;
29
30export const loadMcpClientSdk = (): Promise<McpClientSdk> =>
31 (loading ??= Promise.all([
32 import("@modelcontextprotocol/client"),
33 import("@modelcontextprotocol/client/validators/cf-worker"),
34 ]).then(([client, validators]) => {
35 loaded = { client, validators };
36 return loaded;
37 }));
38
39export const mcpClientSdkIfLoaded = (): McpClientSdk | undefined => loaded;

Callers 3

connectClientFunction · 0.90
invoke.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected