From 64d381d41a8a206667b9167a1489219c302402d0 Mon Sep 17 00:00:00 2001 From: Hari Date: Sat, 6 Jun 2026 19:27:53 -0400 Subject: [PATCH] Update litellm/proxy/_experimental/mcp_server/mcp_context.py Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- litellm/proxy/_experimental/mcp_server/mcp_context.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/litellm/proxy/_experimental/mcp_server/mcp_context.py b/litellm/proxy/_experimental/mcp_server/mcp_context.py index 3cee6e190e6..51918509441 100644 --- a/litellm/proxy/_experimental/mcp_server/mcp_context.py +++ b/litellm/proxy/_experimental/mcp_server/mcp_context.py @@ -20,6 +20,8 @@ _mcp_gateway_initialize_instructions: ContextVar[Optional[str]] = ContextVar( "_mcp_gateway_initialize_instructions", default=None ) +# Per-request scoped server name; set in MCP HTTP/SSE handlers when the path +# identifies exactly one upstream server. Never populated from client-supplied headers. _mcp_gateway_server_name: ContextVar[Optional[str]] = ContextVar( "_mcp_gateway_server_name", default=None )