Skip to content

feat: MCP 2025-11-25 spec compliance (HTTP + SSE transports)#5

Merged
Codestz merged 3 commits intomainfrom
feat/mcp-spec-compliance
Mar 14, 2026
Merged

feat: MCP 2025-11-25 spec compliance (HTTP + SSE transports)#5
Codestz merged 3 commits intomainfrom
feat/mcp-spec-compliance

Conversation

@Codestz
Copy link
Owner

@Codestz Codestz commented Mar 14, 2026

Summary

  • Streamable HTTP transport (transport: http) — the MCP spec's primary remote transport, with JSON and SSE response handling, session management, and 404 re-init
  • Legacy SSE transport (transport: sse) — persistent GET stream + POST requests for older MCP servers
  • Protocol compliance fixes — version 2025-11-25, server capabilities parsing, paginated tools/list, ping method, expanded content types (image/audio/resource), server notification handling
  • Config & authtransport: "http" validation, headers map, bearer token auth (auth.type: bearer), init maps streamable-http type

Test plan

  • go test -race ./... — 146 tests pass, 0 races
  • go vet ./... — clean
  • Integration tested against @modelcontextprotocol/server-everything (Streamable HTTP on port 3100, SSE on port 3200)
    • ping — both transports respond with 13 tools
    • --help — tool discovery works on both
    • echo --message — tool calls work on both
    • get-sum --a --b — numeric args work on both
    • get-tiny-image — image content type renders correctly
    • --json output mode — correct JSON on both
    • <tool> --help — flag discovery on both
  • Stdio regression — serena (daemon) still works identically

🤖 Generated with Claude Code

Codestz and others added 3 commits March 13, 2026 21:59
Brings mcpx into full compliance with the MCP 2025-11-25 specification.

Transports:
- Streamable HTTP transport (transport: http) — POST-based JSON-RPC with
  dual content-type handling (application/json + text/event-stream),
  session management via Mcp-Session-Id, and DELETE on close
- Legacy SSE transport (transport: sse) — persistent GET stream for
  responses with POST for requests, endpoint discovery via SSE events

Protocol fixes:
- Protocol version updated from 2024-11-05 to 2025-11-25
- Server capabilities and info parsed from Initialize response
- Paginated tools/list with cursor support
- Proper ping method on Client
- Expanded content types: image, audio, resource (with base64 display)
- Server notification handling via NotificationHandler callback

Config & wiring:
- transport: "http" with url validation
- Headers and bearer auth support (auth.type: bearer, auth.token)
- init command maps "streamable-http" → "http" transport
- Variable resolution for URL and headers via existing resolver

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Fixes GO-2026-4601 (net/url IPv6 parsing), GO-2026-4600 and
GO-2026-4599 (crypto/x509 certificate validation) flagged by govulncheck.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Codestz Codestz merged commit 729d331 into main Mar 14, 2026
4 checks passed
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.

1 participant