[BUG] HTTP MCP connection fails with Snap Lens Studio - protocol version mismatch (2024-11-05 vs 2025-06-18)
Description
Claude Code cannot connect to Snap Lens Studio's MCP server. The health check reports "Failed to connect" and the server returns "Unsupported protocol version" error.
After investigating, I found that Lens Studio 5.17.1 only accepts MCP protocol version 2025-06-18 and rejects all other versions. Claude Code appears to be sending a different protocol version during initialization.
Environment
- Claude Code: 2.1.3
- OS: Windows 11
- Lens Studio: 5.17.1
- Transport: HTTP
- Server URL: http://localhost:50049/mcp
Configuration
{
"mcpServers": {
"lens-studio": {
"type": "http",
"url": "http://localhost:50049/mcp",
"headers": {
"Authorization": "Bearer <token>"
}
}
}
}
Steps to Reproduce
- Install Lens Studio 5.17.1
- Start MCP server via AI Assistant > MCP > Configure Server > Start Server
- Add the server to Claude Code using
claude mcp add-json - Run
claude mcp list - Status shows "Failed to connect"
Investigation
I tested the server directly with curl using different protocol versions:
curl -X POST "http://localhost:50049/mcp" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"test","version":"1.0"}},"id":1}'
Results:
- 2024-10-07: Error - Unsupported protocol version
- 2024-11-05: Error - Unsupported protocol version
- 2025-03-26: Error - Unsupported protocol version
- 2025-06-18: Success - Server responds with capabilities and 41 tools
- 2025-11-25: Error - Unsupported protocol version
When using protocol version 2025-06-18, the server responds correctly:
{
"id": 1,
"jsonrpc": "2.0",
"result": {
"serverInfo": {
"name": "Lens Studio MCP Server",
"version": "1.0.0"
},
"protocolVersion": "2025-06-18",
"capabilities": {...}
}
}
Expected Behavior
Claude Code should connect to the MCP server and expose the available tools.
Actual Behavior
lens-studio: http://localhost:50049/mcp (HTTP) - Failed to connect
Additional Notes
This also affects VS Code's native MCP client with the same error. The server is functional and exposes 41 tools when the correct protocol version is used.
I understand Lens Studio should ideally support multiple protocol versions for backward compatibility, and I am reporting this to Snap as well. However, since 2025-06-18 is a published MCP specification version, it would help if Claude Code's HTTP transport could support it.
Related Issues
- #7404 - Protocol violation in health checker
- #768 - protocolVersion validation error with stdio servers
- #1611 - MCP servers fail to connect despite correct configuration
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗