feat(serve): add Streamable HTTP transport to MCP server (#1143)#1155
Closed
TPAteeq wants to merge 1 commit into
Closed
feat(serve): add Streamable HTTP transport to MCP server (#1143)#1155TPAteeq wants to merge 1 commit into
TPAteeq wants to merge 1 commit into
Conversation
…bs#1143) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Collaborator
|
Landed in 2a683aa. Independent verification confirmed:
Two optional hardening notes for a follow-up: add |
safishamsi
added a commit
that referenced
this pull request
Jun 6, 2026
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a Streamable HTTP transport to the graphify MCP server (
graphify/serve.py)alongside the existing stdio path, so a single shared process (in CI or on a host)
can serve the graph for a whole team — clients point their IDE MCP config at one URL
instead of running graphify locally. Closes #1143.
stdio remains the default; existing setups are unchanged.
What's included
--transport httpserves the same tools/resources over the MCPStreamable HTTP transport (spec 2025-03-26) via
StreamableHTTPSessionManager. Theexisting low-level
Serverand all handlers are reused (refactored into a shared_build_server()), so there is no duplication and stdio behavior is byte-for-byteunchanged.
--api-key(envGRAPHIFY_API_KEY) acceptingAuthorization: Beareror
X-API-Key. Implemented as pure-ASGI middleware (notBaseHTTPMiddleware, whichwould break SSE streaming), constant-time compare, RFC-6750 case-insensitive scheme.
Dockerfile(+.dockerignore, non-root user) builds the server as acontainer image. Builds from source so the image includes the transport before it lands
on PyPI; the graph is mounted at runtime, never baked in.
Flags
--transport {stdio,http}stdio--host127.0.0.10.0.0.0to expose)--port8080--api-keyGRAPHIFY_API_KEYAuthorization: Bearer/X-API-Key--path/mcp--json-response--stateless--session-timeout36000disables)Interface