Skip to content

SEP-2598: Pluggable Transports - #2598

Open
kurtisvg wants to merge 2 commits into
modelcontextprotocol:mainfrom
kurtisvg:sep-pluggable-transports
Open

kurtisvg wants to merge 2 commits into
modelcontextprotocol:mainfrom
kurtisvg:sep-pluggable-transports

Conversation

@kurtisvg

@kurtisvg kurtisvg commented Apr 17, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds a draft SEP proposing pluggable transports at the SDK layer as the
alternative to expanding the core transport set. The proposal splits
transport support into two layers:

  • SDK core — every Tier 1 SDK ships a public Transport interface plus
    a reusable conformance test harness.
  • Transport implementations — distributed as independent packages, with
    the most widely-adopted eligible for promotion to official SEP-2133
    Extensions. Neither tier factors into SDK conformance tiering.

It also relaxes the current MUST ... preserve the JSON-RPC message format
requirement for custom transports, in exchange for a bidirectional
JSON-RPC mapping that makes generic translating proxies tractable.

Key design choices

  • Small Standard set is load-bearing. stdio and Streamable HTTP remain
    the only Standard transports. Every core addition compounds spec
    complexity and SDK maintainer burden; this SEP argues for a firm
    default of "no" and a supported extension point instead.
  • Interface vs. implementations split. Resolves the bootstrap paradox
    of Extensions negotiating over initialize, and aligns with SEP-2133's
    carve-out of Extensions from SDK conformance tiering.
  • Grandfathering. SDKs already at a stable major version retain Tier 1
    status until their next major version bump; new SDKs comply from their
    first stable release.

Related proposals this addresses

@kurtisvg kurtisvg added SEP draft SEP proposal with a sponsor. labels Apr 17, 2026
@kurtisvg kurtisvg self-assigned this Apr 17, 2026
Formalizes pluggable transports at the SDK layer rather than expanding
the core spec. Splits transport support into two layers: a Transport
interface and conformance harness in SDK core (Tier 1 requirement),
and concrete transport implementations distributed as independent
packages or formalized SEP-2133 Extensions. Relaxes the JSON-RPC
wire-format requirement for custom transports in exchange for a
bidirectional JSON-RPC mapping that enables generic translating
proxies.
@kurtisvg
kurtisvg force-pushed the sep-pluggable-transports branch from db639fb to 50ea008 Compare April 17, 2026 23:56
@kurtisvg kurtisvg changed the title SEP-XXXX: Pluggable Transports SEP-2598: Pluggable Transports Apr 17, 2026
@kurtisvg
kurtisvg requested review from a team as code owners April 18, 2026 00:01
@kurtisvg
kurtisvg force-pushed the sep-pluggable-transports branch from 21882c4 to 2d90abe Compare April 18, 2026 00:04

@markdroth markdroth left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for writing this up, Kurtis!

I like the overall direction here, but I think the proposal is a bit too strict about what custom transports will support. I think we need to loosen the requirements there to allow custom transports to innovate or to decide not to support certain parts of the MCP spec.

Happy to chat further about this.

MUST expose it ([SEP-1730](./1730-sdks-tiering-system.md)).
- Concrete **transport implementations** (WebSocket, gRPC, SSH, …) live
outside SDK core as separate packages. Most ship simply as third-party
packages that consume the §4 interface; only the most widely-adopted

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume that §4 should be a link to section 4 below? Maybe use a hyperlink here instead?

Same thing in various places that use the § notation.

Comment on lines +175 to +179
> **MAY** use any on-the-wire encoding. A custom transport **MAY**
> transcode JSON-RPC messages into a different serialization (e.g.,
> Protobuf, CBOR, a custom binary framing) provided every MCP method,
> parameter, result, notification, and error is faithfully
> round-tripped and no MCP semantics are lost or added.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this may be a little too strong. I think we want the ability for custom transports to innovate a bit, or to decide that they aren't going to support certain protocol features.

As an example, the gRPC transport will probably want to not support progress notifications for anything except tasks.

Comment on lines +195 to +197
(e.g., `id` when JSON-RPC allows string/number/null but the custom
encoding uses a fixed type; binary payloads in fields typed as
strings; error codes and error data).

@markdroth markdroth Apr 21, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is another example of where I think this proposal is a bit too strict. As an example, the gRPC transport doesn't have a request ID at all, nor does it need one. This means that it's not really feasible for us to translate this field.

I would argue that within a pluggable transport framework, the request ID should be added by the JSON-RPC-based transports and not exposed as part of the general JSON-RPC format for MCP, so that the request ID is not even relevant to this translation in the first place. (Note that with all of the statelessness changes we're making for the June spec, the request ID will technically no longer be useful even in the streamable HTTP transport -- it will actually be necessary only for the stdio transport.)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Related: The gRPC transport will also not support the notifications/cancelled method, which I think is the only thing that actually depends on the JSON-RPC request ID. (That method is also basically useless in the streamable HTTP transport once all of the statelessness changes are in place.)

mapping **MUST**:

1. Cover every MCP method, notification, result, and error the transport
supports, including `initialize` and shutdown.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're getting rid of initialize in one of the other SEPs, so should just assume it's already gone here?

Note that the gRPC transport does not support initialize, because it's inherently stateless, so this isn't something we're going to be able to provide a mapping for.

Comment on lines +235 to +237
4. Is transport-agnostic in shape: the interface **MUST NOT** leak
stdio-specific or Streamable-HTTP-specific concepts (e.g., `stderr`,
HTTP status codes) into its public surface.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we may want to spell out the desired API semantics a bit more clearly here, but I also don't want to be too prescriptive, so I'm not sure exactly how to phrase it.

As an example of the kind of issue I'm concerned about here, one of the issues that we've been discussing in the context of the python SDK is that on the server side, we need an API that inherently matches up responses to the corresponding requests without relying on something like a request ID.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that the JSON-RPC request ID is now essentially a transport-specific detail, it would also be nice to mandate that the request ID should not be part of the transport API, nor should it be exposed outside of that API.


## Reference Implementation

TODO — to be completed before this SEP reaches `Final`. Planned scope:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines +26 to +27
conformance test harness — lives in SDK **core**. Every Tier 1 MCP SDK
MUST expose it ([SEP-1730](./1730-sdks-tiering-system.md)).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These will both be a significant burden on tier 1 SDK maintainers, which is quite different from how we've handled extensions so far. For instance, we don't require Tier 1 SDK's to implement any extensions today (or even "experimental" features).

These will also both be fairly difficult to enforce. Since each implementation and each test harness will be language specific, it means this will need to be qualitatively evaluated at tiering time as to whether they've actually done the extension points "properly".

I'd prefer we treat this more like an extension. E.g. the gRPC transport can ship conformance tests in the official suite that SDK's can connect to as an optional test they can report on passing or not.

@danielsmithdevelopment

Copy link
Copy Markdown

Hi @kurtisvg and team,
This SEP is excellent and exactly the right direction. Keeping only stdio + Streamable HTTP as standard while providing a clean pluggable Transport interface + conformance harness removes a ton of future friction.

I’ve already shipped a production-grade pluggable gRPC transport that aligns closely with the spirit (and much of the letter) of this proposal:
• Package: mcp-grpc-transport (TypeScript, reusable, works with any MCP server)
• Repo: https://github.com/danielsmithdevelopment/ClawQL/tree/main/packages/mcp-grpc-transport
• Features:
• Native Protobuf service (model_context_protocol.Mcp) with unary + streaming RPCs (aligned with the Google Cloud / community protobuf design)
• Optional bidirectional JSON-RPC fallback stream (mcp.transport.v1.Mcp.Session) for easy proxying
• mTLS support, health checks, protocol version metadata, etc.

It deliberately makes the same pragmatic trade-offs discussed in the reviews here (no request ID on the wire for the protobuf path, stateless by design, etc.) while still providing full MCP semantics and a clean JSON-RPC mapping option.

Happy to:
• Add it as a reference implementation in the SEP
• Contribute to / align with the official conformance test harness once it lands

Thanks for driving this!
— Daniel Smith (@danielsmithdev)


SDKs that have already shipped a **stable major version** at the time
this SEP is accepted **MAY** retain Tier 1 status without implementing
§4.1 and §4.2 until their next major version bump. This is a one-time

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that we're likely going to have to release a 2.0 anyway to the other breaking changes coming to the protocol at the end of June, I don't think this buys anything for at least the C# SDK.

At the same time, looking at section 4.1 "The Transport interface", I think the current ITransport and IClientTransport interfaces in the C# SDK already meet all the requirements.

That is, unless the push back is really about just having things like "JsonRpc" in type names, but I think the pluggable transports would be overreaching by quite a bit if it started demanding certain names for types/methods/functions across SDKs.

@markdroth suggested the following additional requirement ion section 4.1.

Given that the JSON-RPC request ID is now essentially a transport-specific detail, it would also be nice to mandate that the request ID should not be part of the transport API, nor should it be exposed outside of that API.

This is the type of overly prescriptive language that I would not want in the pluggable transport language.

The focus of this should be to unblock scenarios mentioned in the "Motivation" section. If we can achieve those goals, I think that should be considered a success.

I think it would be wrong to mandate that "The Transport interface" be made completely incompatible with old revisions of the protocol. If there's a transport design that can optionally expose JSON-RPC request IDs for transport implementations that can implement them and wan to by easily-proxyable to the older more JSON-RPC focused iterations of the protocol, we should not use the specification to bully SDK maintainers into making this impossible or difficult.

What I think would be helpful is a reference implementation for a transport interface that everyone agrees meets the ideals set out in section 4.1, "The Transport interface". I expect people will want this in either TypeScript or Python first.

I'm open to creating a new transport interface with less JSON-RPCisms, but I want to know what I'm getting for this. If I can unblock all the scenarios mentioned in the "Motivation" section by extending the existing ITransport and IClientTransport interfaces we shipped in version 1.0 of the C# SDK, I want to be given an opportunity to do that.

@pja-ant

pja-ant commented May 5, 2026

Copy link
Copy Markdown
Contributor

This was reviewed by the Core Maintainers and the decision was to Defer.

@pja-ant pja-ant added deferred SEP deferred and removed draft SEP proposal with a sponsor. labels May 5, 2026
@kurtisvg

Copy link
Copy Markdown
Contributor Author

Just a quick update, this SEP is going to try to be broken down into 3 discrete parts before re-voting:

  1. Separating Data Model from Transport Representation - (Currently at WG level: SEP-XXXX: Separating Data Model from Transport Representation transports-wg#58)
  2. Removing the requirement for custom transports to use JSON-RPC on the wire
  3. This SEP, to make a pluggable transport interface a requirement for Tier 1 SDKs

Here is also a slide deck I presented on this topic as Amsterdam's MCPCon:
Why Pluggable Transports.pdf

This branch has not been deployed

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

Labels

deferred SEP deferred SEP transport Related to MCP transports

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

7 participants