We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1456b89 commit 79cb413Copy full SHA for 79cb413
src/mcp/shared/httpx_utils.py
@@ -1,7 +1,5 @@
1
"""Utilities for creating standardized httpx AsyncClient instances."""
2
3
-from __future__ import annotations
4
-
5
from typing import Any
6
7
import httpx
@@ -10,7 +8,7 @@
10
8
11
9
12
def create_mcp_http_client(
13
- headers: dict[str, Any] | None = None,
+ headers: dict[str, str] | None = None,
14
timeout: httpx.Timeout | None = None,
15
) -> httpx.AsyncClient:
16
"""Create a standardized httpx AsyncClient with MCP defaults.
@@ -61,4 +59,4 @@ def create_mcp_http_client(
61
59
if headers is not None:
62
60
kwargs["headers"] = headers
63
64
- return httpx.AsyncClient(**kwargs)
+ return httpx.AsyncClient(**kwargs)
0 commit comments