diff --git a/src/ModelContextProtocol.AspNetCore/HttpServerTransportOptions.cs b/src/ModelContextProtocol.AspNetCore/HttpServerTransportOptions.cs index b88cfb762..677606eb6 100644 --- a/src/ModelContextProtocol.AspNetCore/HttpServerTransportOptions.cs +++ b/src/ModelContextProtocol.AspNetCore/HttpServerTransportOptions.cs @@ -6,7 +6,7 @@ namespace ModelContextProtocol.AspNetCore; /// /// Configuration options for . /// which implements the Streaming HTTP transport for the Model Context Protocol. -/// See the protocol specification for details on the Streamable HTTP transport. +/// See the protocol specification for details on the Streamable HTTP transport. /// public class HttpServerTransportOptions { diff --git a/src/ModelContextProtocol.AspNetCore/McpEndpointRouteBuilderExtensions.cs b/src/ModelContextProtocol.AspNetCore/McpEndpointRouteBuilderExtensions.cs index a65994c44..e7c5f97c5 100644 --- a/src/ModelContextProtocol.AspNetCore/McpEndpointRouteBuilderExtensions.cs +++ b/src/ModelContextProtocol.AspNetCore/McpEndpointRouteBuilderExtensions.cs @@ -15,7 +15,7 @@ public static class McpEndpointRouteBuilderExtensions { /// /// Sets up endpoints for handling MCP Streamable HTTP transport. - /// See the 2025-03-26 protocol specification for details about the Streamable HTTP transport. + /// See the 2025-06-18 protocol specification for details about the Streamable HTTP transport. /// Also maps legacy SSE endpoints for backward compatibility at the path "/sse" and "/message". the 2024-11-05 protocol specification for details about the HTTP with SSE transport. /// /// The web application to attach MCP HTTP endpoints. diff --git a/src/ModelContextProtocol.Core/Client/SseClientTransportOptions.cs b/src/ModelContextProtocol.Core/Client/SseClientTransportOptions.cs index cd522c42d..9b4af6db5 100644 --- a/src/ModelContextProtocol.Core/Client/SseClientTransportOptions.cs +++ b/src/ModelContextProtocol.Core/Client/SseClientTransportOptions.cs @@ -39,7 +39,7 @@ public required Uri Endpoint /// Streamable HTTP transport and automatically fall back to SSE transport if the server doesn't support it. /// /// - /// Streamable HTTP transport specification. + /// Streamable HTTP transport specification. /// HTTP with SSE transport specification. /// /// diff --git a/src/ModelContextProtocol.Core/McpSession.cs b/src/ModelContextProtocol.Core/McpSession.cs index 225971fa6..47c4d212b 100644 --- a/src/ModelContextProtocol.Core/McpSession.cs +++ b/src/ModelContextProtocol.Core/McpSession.cs @@ -29,12 +29,13 @@ internal sealed partial class McpSession : IDisposable "mcp.server.operation.duration", "Measures the duration of inbound message processing.", longBuckets: false); /// The latest version of the protocol supported by this implementation. - internal const string LatestProtocolVersion = "2025-03-26"; + internal const string LatestProtocolVersion = "2025-06-18"; /// All protocol versions supported by this implementation. internal static readonly string[] SupportedProtocolVersions = [ "2024-11-05", + "2025-03-26", LatestProtocolVersion, ]; diff --git a/tests/ModelContextProtocol.AspNetCore.Tests/MapMcpStreamableHttpTests.cs b/tests/ModelContextProtocol.AspNetCore.Tests/MapMcpStreamableHttpTests.cs index b1c1a89da..f14cc10a6 100644 --- a/tests/ModelContextProtocol.AspNetCore.Tests/MapMcpStreamableHttpTests.cs +++ b/tests/ModelContextProtocol.AspNetCore.Tests/MapMcpStreamableHttpTests.cs @@ -171,7 +171,10 @@ public async Task StreamableHttpClient_SendsMcpProtocolVersionHeader_AfterInitia await app.StartAsync(TestContext.Current.CancellationToken); - await using var mcpClient = await ConnectAsync(); + await using var mcpClient = await ConnectAsync(clientOptions: new() + { + ProtocolVersion = "2025-03-26", + }); await mcpClient.ListToolsAsync(cancellationToken: TestContext.Current.CancellationToken); // The header should be included in the GET request, the initialized notification, and the tools/list call.