MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / installGlobalProxyDispatcher

Function installGlobalProxyDispatcher

packages/agent-core/src/utils/proxy.ts:310–318  ·  view source on GitHub ↗
(
  env: Env = process.env,
  deps: InstallProxyDeps = defaultInstallProxyDeps,
)

Source from the content-addressed store, hash-verified

308 * any network use. No-op (returns `false`) when no proxy variable is set.
309 */
310export function installGlobalProxyDispatcher(
311 env: Env = process.env,
312 deps: InstallProxyDeps = defaultInstallProxyDeps,
313): boolean {
314 const dispatcher = deps.createProxyDispatcher(env);
315 if (dispatcher === undefined) return false;
316 deps.setGlobalDispatcher(dispatcher);
317 return true;
318}
319
320/**
321 * Environment additions for spawned child node processes (e.g. stdio MCP

Callers 2

proxy.test.tsFile · 0.90
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected