mcp-proxy 5.6.1 → 5.8.0

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.
package/README.md CHANGED
@@ -35,6 +35,7 @@ options:
35
35
  - `--streamEndpoint`: Set the streamable HTTP endpoint path (default: `/mcp`). Overrides `--endpoint` if `server` is set to `stream`.
36
36
  - `--stateless`: Enable stateless mode for HTTP streamable transport (no session management). In this mode, each request creates a new server instance instead of maintaining persistent sessions.
37
37
  - `--port`: Specify the port to listen on (default: 8080)
38
+ - `--requestTimeout`: Timeout in milliseconds for requests to the MCP server (default: 300000, which is 5 minutes)
38
39
  - `--debug`: Enable debug logging
39
40
  - `--shell`: Spawn the server via the user's shell
40
41
  - `--apiKey`: API key for authenticating requests (uses X-API-Key header)
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { Client, InMemoryEventStore, ReadBuffer, Server, __commonJS, __toESM, proxyServer, serializeMessage, startHTTPServer } from "../stdio-D0Lv8ytu.js";
2
+ import { Client, InMemoryEventStore, ReadBuffer, Server, __commonJS, __toESM, proxyServer, serializeMessage, startHTTPServer } from "../stdio-so1-I7Pn.js";
3
3
  import { createRequire } from "node:module";
4
4
  import { basename, dirname, extname, join, normalize, relative, resolve } from "path";
5
5
  import { format, inspect } from "util";
@@ -5044,6 +5044,11 @@ const argv = await yargs_default(hideBin(process.argv)).scriptName("mcp-proxy").
5044
5044
  describe: "The port to listen on",
5045
5045
  type: "number"
5046
5046
  },
5047
+ requestTimeout: {
5048
+ default: 3e5,
5049
+ describe: "The timeout (in milliseconds) for requests to the MCP server (default: 5 minutes)",
5050
+ type: "number"
5051
+ },
5047
5052
  server: {
5048
5053
  choices: ["sse", "stream"],
5049
5054
  describe: "The server type to use (sse or stream). By default, both are enabled",
@@ -5099,6 +5104,7 @@ const proxy = async () => {
5099
5104
  const server$1 = new Server(serverVersion, { capabilities: serverCapabilities });
5100
5105
  proxyServer({
5101
5106
  client,
5107
+ requestTimeout: argv.requestTimeout,
5102
5108
  server: server$1,
5103
5109
  serverCapabilities
5104
5110
  });