Skip to content

Conversation

@RussellZager
Copy link

SSE Transport Support - Support for Server-Sent Events transport protocol

  • Requires type: "sse" in server config
  • Enables connection to MCP servers using SSE (e.g. LangChain, remote servers)

google-labs-jules bot and others added 7 commits February 3, 2026 22:07
This commit adds support for Server-Sent Events (SSE) transport for MCP servers.
- Updates `HttpServerConfig` to include an optional `transport` field, defaulting to 'http'.
- Updates `connectToServer` to use `SSEClientTransport` when `transport` is set to 'sse'.
- Uses `@modelcontextprotocol/sdk/client/sse.js` for SSE transport.
- Adds test coverage for the new configuration option.

Co-authored-by: Zman771 <605281+Zman771@users.noreply.github.com>
This commit introduces support for the SSE (Server-Sent Events) transport protocol in mcp-cli.

- **Config**: Added `SseServerConfig` interface. SSE servers must be explicitly configured with `"type": "sse"`.
- **Client**: Added `createSseTransport` which automatically appends `/sse` to the URL if not present, adhering to common conventions for SSE endpoints.
- **Client**: Updated `connectToServer` to route connections to the appropriate transport (SSE, HTTP, or Stdio) based on the configuration.
- **Tests**: Added unit tests for the new configuration type and type guards.

This aligns the implementation with the provided design document, ensuring backward compatibility for existing HTTP server configurations.

Co-authored-by: Zman771 <605281+Zman771@users.noreply.github.com>
- Updated `README.md` to include a new "SSE Transport (Legacy)" section.
- Added configuration examples for enabling SSE transport with `"type": "sse"`.
- Included a deprecation note advising users to prefer Streamable HTTP transport for new servers.

Co-authored-by: Zman771 <605281+Zman771@users.noreply.github.com>
- Update version in package.json and src/version.ts
- Update CHANGELOG.md with SSE Transport Support details

Co-authored-by: Zman771 <605281+Zman771@users.noreply.github.com>
- Update version in package.json and src/version.ts
- Update CHANGELOG.md with SSE Transport Support details

Co-authored-by: Zman771 <605281+Zman771@users.noreply.github.com>
…1264656097342

Release 0.3.1: SSE Support
@philschmid
Copy link
Owner

Shouldn't this work with streamable http?

@RussellZager
Copy link
Author

The mcp server I'm using doesn't support streamable http unfortunately. The only way I got it to work was to use SSE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants