Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/concepts/elicitation/samples/server/Elicitation.http
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25

{
"jsonrpc": "2.0",
Expand Down Expand Up @@ -34,7 +34,7 @@ Content-Type: application/json
"capabilities": {
"elicitation": {}
},
"protocolVersion": "2025-06-18"
"protocolVersion": "2025-11-25"
}
}

Expand All @@ -46,7 +46,7 @@ POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
Mcp-Session-Id: {{SessionId}}
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25

{
"jsonrpc": "2.0",
Expand Down
2 changes: 1 addition & 1 deletion docs/concepts/httpcontext/samples/HttpContext.http
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25

{
"jsonrpc": "2.0",
Expand Down
4 changes: 2 additions & 2 deletions docs/concepts/logging/logging.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ uid: logging

MCP servers can expose log messages to clients through the [Logging utility].

[Logging utility]: https://modelcontextprotocol.io/specification/2025-06-18/server/utilities/logging
[Logging utility]: https://modelcontextprotocol.io/specification/2025-11-25/server/utilities/logging

This document describes how to implement logging in MCP servers and how clients can consume log messages.

Expand Down Expand Up @@ -43,7 +43,7 @@ dropped when sending messages to the client.
MCP servers that implement the Logging utility must declare this in the capabilities sent in the
[Initialization] phase at the beginning of the MCP session.

[Initialization]: https://modelcontextprotocol.io/specification/2025-06-18/basic/lifecycle#initialization
[Initialization]: https://modelcontextprotocol.io/specification/2025-11-25/basic/lifecycle#initialization

Servers built with the C# SDK always declare the logging capability. Doing so does not obligate the server
to send log messages—only allows it. Note that stateless MCP servers might not be capable of sending log
Expand Down
4 changes: 2 additions & 2 deletions docs/concepts/logging/samples/server/Logging.http
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Content-Type: application/json
"version": "0.1.0"
},
"capabilities": {},
"protocolVersion": "2025-06-18"
"protocolVersion": "2025-11-25"
}
}

Expand All @@ -27,7 +27,7 @@ Content-Type: application/json
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand Down
2 changes: 1 addition & 1 deletion docs/concepts/progress/progress.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ uid: progress

The Model Context Protocol (MCP) supports [progress tracking] for long-running operations through notification messages.

[progress tracking]: https://modelcontextprotocol.io/specification/2025-06-18/basic/utilities/progress
[progress tracking]: https://modelcontextprotocol.io/specification/2025-11-25/basic/utilities/progress

Typically progress tracking is supported by server tools that perform operations that take a significant amount of time to complete, such as image generation or complex calculations.
However, progress tracking is defined in the MCP specification as a general feature that can be implemented for any request that's handled by either a server or a client.
Expand Down
2 changes: 1 addition & 1 deletion docs/concepts/progress/samples/server/Progress.http
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25

{
"jsonrpc": "2.0",
Expand Down
10 changes: 5 additions & 5 deletions samples/EverythingServer/EverythingServer.http
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Content-Type: application/json
"version": "0.1.0"
},
"capabilities": {},
"protocolVersion": "2025-06-18"
"protocolVersion": "2025-11-25"
}
}

Expand All @@ -25,7 +25,7 @@ Content-Type: application/json
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand All @@ -41,7 +41,7 @@ Mcp-Session-Id: {{SessionId}}
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand All @@ -58,7 +58,7 @@ Mcp-Session-Id: {{SessionId}}
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand All @@ -73,5 +73,5 @@ Mcp-Session-Id: {{SessionId}}
###

DELETE {{HostAddress}}/
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ namespace ModelContextProtocol.AspNetCore;
/// <summary>
/// Represents configuration options for <see cref="M:McpEndpointRouteBuilderExtensions.MapMcp"/>,
/// which implements the Streaming HTTP transport for the Model Context Protocol.
/// See the protocol specification for details on the Streamable HTTP transport. <see href="https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#streamable-http"/>
/// See the protocol specification for details on the Streamable HTTP transport. <see href="https://modelcontextprotocol.io/specification/2025-11-25/basic/transports#streamable-http"/>
/// </summary>
/// <remarks>
/// For details on the Streamable HTTP transport, see the <see href="https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#streamable-http">protocol specification</see>.
/// For details on the Streamable HTTP transport, see the <see href="https://modelcontextprotocol.io/specification/2025-11-25/basic/transports#streamable-http">protocol specification</see>.
/// </remarks>
public class HttpServerTransportOptions
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public static class McpEndpointRouteBuilderExtensions
/// <returns>Returns a builder for configuring additional endpoint conventions like authorization policies.</returns>
/// <exception cref="InvalidOperationException">The required MCP services have not been registered. Ensure <see cref="HttpMcpServerBuilderExtensions.WithHttpTransport"/> has been called during application startup.</exception>
/// <remarks>
/// For details about the Streamable HTTP transport, see the <see href="https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#streamable-http">2025-06-18 protocol specification</see>.
/// For details about the Streamable HTTP transport, see the <see href="https://modelcontextprotocol.io/specification/2025-11-25/basic/transports#streamable-http">2025-11-25 protocol specification</see>.
/// This method also maps legacy SSE endpoints for backward compatibility at the path "/sse" and "/message". For details about the HTTP with SSE transport, see the <see href="https://modelcontextprotocol.io/specification/2024-11-05/basic/transports#http-with-sse">2024-11-05 protocol specification</see>.
/// </remarks>
public static IEndpointConventionBuilder MapMcp(this IEndpointRouteBuilder endpoints, [StringSyntax("Route")] string pattern = "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public required Uri Endpoint
/// When set to <see cref="HttpTransportMode.AutoDetect"/> (the default), the client will first attempt to use
/// Streamable HTTP transport and automatically fall back to SSE transport if the server doesn't support it.
/// </remarks>
/// <seealso href="https://modelcontextprotocol.io/specification/2025-06-18/basic/transports#streamable-http">Streamable HTTP transport specification</seealso>.
/// <seealso href="https://modelcontextprotocol.io/specification/2025-11-25/basic/transports#streamable-http">Streamable HTTP transport specification</seealso>.
/// <seealso href="https://modelcontextprotocol.io/specification/2024-11-05/basic/transports#http-with-sse">HTTP with SSE transport specification</seealso>.
public HttpTransportMode TransportMode { get; set; } = HttpTransportMode.AutoDetect;

Expand Down
3 changes: 2 additions & 1 deletion src/ModelContextProtocol.Core/McpSessionHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,14 @@ internal sealed partial class McpSessionHandler : IAsyncDisposable
"mcp.server.operation.duration", "Measures the duration of inbound message processing.", longBuckets: false);

/// <summary>The latest version of the protocol supported by this implementation.</summary>
internal const string LatestProtocolVersion = "2025-06-18";
internal const string LatestProtocolVersion = "2025-11-25";

/// <summary>All protocol versions supported by this implementation.</summary>
internal static readonly string[] SupportedProtocolVersions =
[
"2024-11-05",
"2025-03-26",
"2025-06-18",
LatestProtocolVersion,
];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,10 +178,10 @@ public async Task StreamableHttpClient_SendsMcpProtocolVersionHeader_AfterInitia

await using var mcpClient = await ConnectAsync(clientOptions: new()
{
ProtocolVersion = "2025-03-26",
ProtocolVersion = "2025-06-18",
});

Assert.Equal("2025-03-26", mcpClient.NegotiatedProtocolVersion);
Assert.Equal("2025-06-18", mcpClient.NegotiatedProtocolVersion);
await mcpClient.ListToolsAsync(cancellationToken: TestContext.Current.CancellationToken);

await mcpClient.DisposeAsync();
Expand All @@ -190,7 +190,7 @@ public async Task StreamableHttpClient_SendsMcpProtocolVersionHeader_AfterInitia
// Stateless mode due to the lack of an Mcp-Session-Id, but the header should be included in the
// initialized notification and the tools/list call at a minimum.
Assert.True(protocolVersionHeaderValues.Count > 1);
Assert.All(protocolVersionHeaderValues, v => Assert.Equal("2025-03-26", v));
Assert.All(protocolVersionHeaderValues, v => Assert.Equal("2025-06-18", v));
}

[Fact]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ public async Task ResumeSessionStartsGetImmediately()
{
const string sessionId = "resume-session-123";
const string resumeInstructions = "Use cached instructions";
const string resumeProtocolVersion = "2025-06-18";
const string resumeProtocolVersion = "2025-11-25";
var resumeServer = await StartResumeServerAsync(sessionId);

await using var transport = new HttpClientTransport(new()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Content-Type: application/json
"version": "0.1.0"
},
"capabilities": {},
"protocolVersion": "2025-06-18"
"protocolVersion": "2025-11-25"
}
}

Expand All @@ -37,7 +37,7 @@ Content-Type: application/json
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand All @@ -51,7 +51,7 @@ Mcp-Session-Id: {{SessionId}}
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand All @@ -65,7 +65,7 @@ Mcp-Session-Id: {{SessionId}}
POST {{HostAddress}}/
Accept: application/json, text/event-stream
Content-Type: application/json
MCP-Protocol-Version: 2025-06-18
MCP-Protocol-Version: 2025-11-25
Mcp-Session-Id: {{SessionId}}

{
Expand Down
4 changes: 2 additions & 2 deletions tests/ModelContextProtocol.Tests/Client/McpClientTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -488,11 +488,11 @@ public async Task AsClientLoggerProvider_MessagesSentToClient()

[Theory]
[InlineData(null)]
[InlineData("2025-03-26")]
[InlineData("2025-06-18")]
public async Task ReturnsNegotiatedProtocolVersion(string? protocolVersion)
{
await using McpClient client = await CreateMcpClientForServer(new() { ProtocolVersion = protocolVersion });
Assert.Equal(protocolVersion ?? "2025-06-18", client.NegotiatedProtocolVersion);
Assert.Equal(protocolVersion ?? "2025-11-25", client.NegotiatedProtocolVersion);
}

[Fact]
Expand Down
Loading