Skip to content

[Librechat] StreamableHTTPError: Streamable HTTP error: Failed to open SSE stream: Not Found #134

@demian85

Description

@demian85

Hi,

I'm trying to setup this server using Librechat, but it cannot connect to the stream.

LibreChat         | 2025-11-20 12:00:49 info: [MCP][postgres] Creating streamable-http transport: http://localhost:3081/mcp
LibreChat         | 2025-11-20 12:00:49 error: [MCP][postgres] Transport error: fetch failed
LibreChat         | 2025-11-20 12:00:49 info: [MCP][postgres] Streamable-http transport closed
LibreChat         | 2025-11-20 12:00:49 error: [MCP][postgres] Connection failed: fetch failed
LibreChat         | 2025-11-20 12:00:53 info: [MCP][postgres] Creating streamable-http transport: http://localhost:3081/mcp
LibreChat         | 2025-11-20 12:00:53 error: [MCP][postgres] Transport error: fetch failed
LibreChat         | 2025-11-20 12:00:53 info: [MCP][postgres] Streamable-http transport closed
LibreChat         | 2025-11-20 12:00:53 error: [MCP][postgres] Connection failed: fetch failed
LibreChat         | 2025-11-20 12:00:53 error: [MCP][postgres] Failed to connect after 3 attempts fetch failed
LibreChat         | 2025-11-20 12:00:53 error: [MCP][postgres] Failed to initialize: fetch failed
LibreChat         | 2025-11-20 12:00:53 info: MCP servers initialized successfully. Added 0 MCP tools.

And even the MCP inspector shows this error, however, tools work. Ping does not respond.

 MCP Inspector is up and running at http://127.0.0.1:6274 🚀
New StreamableHttp connection request
Query parameters: {"url":"http://localhost:3081/mcp","transportType":"streamable-http"}
Created StreamableHttp server transport
Created StreamableHttp client transport
Client <-> Proxy  sessionId: af07266b-ae0a-4bfc-aef4-abb069bc1d6d
Received POST message for sessionId af07266b-ae0a-4bfc-aef4-abb069bc1d6d
Received GET message for sessionId af07266b-ae0a-4bfc-aef4-abb069bc1d6d
Error from MCP server: StreamableHTTPError: Streamable HTTP error: Failed to open SSE stream: Not Found
    at StreamableHTTPClientTransport._startOrAuthSse (file:///Users/demian/.npm/_npx/5a9d879542beca3a/node_modules/@modelcontextprotocol/sdk/dist/esm/client/streamableHttp.js:106:23)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
  code: 404
}
Error from MCP server: StreamableHTTPError: Streamable HTTP error: Failed to open SSE stream: Not Found
    at StreamableHTTPClientTransport._startOrAuthSse (file:///Users/demian/.npm/_npx/5a9d879542beca3a/node_modules/@modelcontextprotocol/sdk/dist/esm/client/streamableHttp.js:106:23)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
  code: 404
}

I'm running dbhub as a service in the docker-compose file from Librechat:

services:
  dbhub:
    image: bytebase/dbhub:latest
    container_name: dbhub
    ports:
      - "3081:3081"
    restart: unless-stopped
    environment:
      - DBHUB_LOG_LEVEL=info
    command: --transport http --port 3081 --readonly --max-rows 100 --dsn "${POSTGRES_URL}"

Logs from dbhub container:

Max rows limit: 100 (from command line argument)

Configuration source: command line argument

Connecting with DSN: postgres://postgres:*******@host.docker.internal:5432/postgres

Successfully connected to PostgreSQL database

Using transport: http

Transport source: command line argument

Running in READ-ONLY mode - only read only queries allowed


 _____  ____  _   _       _     

|  __ \|  _ \| | | |     | |    

| |  | | |_) | |_| |_   _| |__  

| |  | |  _ <|  _  | | | | '_ \ 

| |__| | |_) | | | | |_| | |_) |

|_____/|____/|_| |_|\__,_|_.__/ 

                                

v0.11.6 [READ-ONLY] - Universal Database MCP Server


Port source: command line argument

DBHub server listening at [http://0.0.0.0:3081⁠](http://0.0.0.0:3081/)

Connect to MCP server at [http://0.0.0.0:3081/mcp⁠](http://0.0.0.0:3081/mcp)

Any ideas what's wrong?

Thanks.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions