align-mcp-remote 0.1.43 → 0.1.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15632,7 +15632,7 @@ var Client = class extends Protocol {
15632
15632
  };
15633
15633
 
15634
15634
  // package.json
15635
- var version2 = "0.1.42";
15635
+ var version2 = "0.1.44";
15636
15636
 
15637
15637
  // node_modules/pkce-challenge/dist/index.node.js
15638
15638
  var crypto;
@@ -18194,11 +18194,11 @@ async function connectToRemoteServer(client, serverUrl, authProvider, headers, a
18194
18194
  const sseTransport = transportStrategy === "sse-only" || transportStrategy === "sse-first";
18195
18195
  const fetchWithDownstreamHeader = async (input, init) => {
18196
18196
  const downstreamHeader = await resolveDownstreamHeader();
18197
- log(`[downstream-fetch] header keys: ${Object.keys(downstreamHeader).join(",") || "none"}`);
18198
18197
  const existingHeaders = init?.headers instanceof Headers2 ? Object.fromEntries(init.headers.entries()) : init?.headers || {};
18198
+ log(`[downstream-fetch] downstream keys: ${Object.keys(downstreamHeader).join(",") || "none"}, existing auth: ${!!existingHeaders["authorization"]}`);
18199
18199
  return fetch2(input, {
18200
18200
  ...init,
18201
- headers: { ...existingHeaders, ...headers, ...downstreamHeader }
18201
+ headers: { ...existingHeaders, ...downstreamHeader }
18202
18202
  });
18203
18203
  };
18204
18204
  const transport = sseTransport ? new SSEClientTransport(url2, {
@@ -18220,7 +18220,7 @@ async function connectToRemoteServer(client, serverUrl, authProvider, headers, a
18220
18220
  await transport.start();
18221
18221
  if (!sseTransport) {
18222
18222
  debugLog("Creating test transport for HTTP-only connection test");
18223
- const testTransport = new StreamableHTTPClientTransport(url2, { authProvider, requestInit: { headers } });
18223
+ const testTransport = new StreamableHTTPClientTransport(url2, { authProvider, requestInit: { headers }, fetch: fetchWithDownstreamHeader });
18224
18224
  const testClient = new Client({ name: "mcp-remote-fallback-test", version: "0.0.0" }, { capabilities: {} });
18225
18225
  await testClient.connect(testTransport);
18226
18226
  }
package/dist/client.js CHANGED
@@ -13,7 +13,7 @@ import {
13
13
  performDownstreamAuth,
14
14
  setupSignalHandlers,
15
15
  version
16
- } from "./chunk-6LSKSRH2.js";
16
+ } from "./chunk-P4FBHJSL.js";
17
17
 
18
18
  // src/client.ts
19
19
  import { EventEmitter } from "events";
package/dist/proxy.js CHANGED
@@ -11,7 +11,7 @@ import {
11
11
  parseCommandLineArgs,
12
12
  performDownstreamAuth,
13
13
  setupSignalHandlers
14
- } from "./chunk-6LSKSRH2.js";
14
+ } from "./chunk-P4FBHJSL.js";
15
15
 
16
16
  // src/proxy.ts
17
17
  import { EventEmitter } from "events";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "align-mcp-remote",
3
- "version": "0.1.43",
3
+ "version": "0.1.45",
4
4
  "description": "Remote proxy for Model Context Protocol, allowing local-only clients to connect to remote servers using oAuth",
5
5
  "keywords": [
6
6
  "mcp",