MCPcopy Index your code
hub / github.com/callstack/agent-device / buildUpstreamUrl

Function buildUpstreamUrl

src/remote/daemon-proxy.ts:305–310  ·  view source on GitHub ↗
(upstreamBaseUrl: string, route: string, rawUrl: string)

Source from the content-addressed store, hash-verified

303}
304
305function buildUpstreamUrl(upstreamBaseUrl: string, route: string, rawUrl: string): URL {
306 const upstreamUrl = new URL(buildDaemonHttpUrl(upstreamBaseUrl, route));
307 const rawSearchIndex = rawUrl.indexOf('?');
308 if (rawSearchIndex >= 0) upstreamUrl.search = rawUrl.slice(rawSearchIndex);
309 return upstreamUrl;
310}
311
312function buildUpstreamHeaders(
313 req: Pick<IncomingMessage, 'headers'>,

Callers 1

forwardProxyRequestFunction · 0.85

Calls 1

buildDaemonHttpUrlFunction · 0.90

Tested by

no test coverage detected