MCPcopy Create free account
hub / github.com/EvoMap/evolver / isManagedProxyBaseUrl

Function isManagedProxyBaseUrl

src/proxy/clientSettings.js:136–145  ·  view source on GitHub ↗
(settings, cfg, value, opts = {})

Source from the content-addressed store, hash-verified

134}
135
136function isManagedProxyBaseUrl(settings, cfg, value, opts = {}) {
137 const baseUrl = normalizeUrl(value);
138 if (!isLoopbackProxyUrl(baseUrl)) return false;
139 if (baseUrl === normalizeUrl(opts.url)) return true;
140 if (hasManagedProxyMarker(settings)) return true;
141 if (String(cfg && cfg.EVOMAP_PROXY_AUTO_INJECTED || '') === '1') return true;
142
143 const proxyUrl = normalizeUrl(cfg && cfg.EVOMAP_PROXY_URL);
144 return Boolean(proxyUrl && isLoopbackProxyUrl(proxyUrl) && proxyUrl === baseUrl);
145}
146
147function isManagedProxyClientSettings(settings, cfg, opts = {}) {
148 return isManagedProxyBaseUrl(settings, cfg, cfg && cfg.ANTHROPIC_BASE_URL, opts);

Callers 3

syncClaudeProxySettingsFunction · 0.85

Calls 3

normalizeUrlFunction · 0.85
hasManagedProxyMarkerFunction · 0.85
isLoopbackProxyUrlFunction · 0.70

Tested by

no test coverage detected