Skip to content

Commit 70210dd

Browse files
committed
docs(tools): clarify default httpx client behavior in factory docstrings
- Replace vague "today's behaviour"/"unchanged" with a concrete description of what None does.
1 parent d2bb078 commit 70210dd

2 files changed

Lines changed: 6 additions & 5 deletions

File tree

src/google/adk/tools/openapi_tool/openapi_spec_parser/openapi_toolset.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,8 +139,9 @@ def __init__(
139139
``ssl_verify`` can't reach (proxies, HTTP/2, custom transports such as
140140
request signing). The returned client is used as an async context
141141
manager and closed after each request, so the factory must return a
142-
fresh client on every call. Defaults to ``None``, which preserves
143-
today's behaviour. Mirrors the pattern exposed for MCP by
142+
fresh client on every call. Defaults to ``None``, in which case each
143+
generated tool constructs its own ``httpx.AsyncClient`` per request.
144+
Mirrors the pattern exposed for MCP by
144145
``StreamableHTTPConnectionParams.httpx_client_factory``.
145146
preserve_property_names: If True, preserve the original property names
146147
from the OpenAPI spec instead of converting them to snake_case. This

src/google/adk/tools/openapi_tool/openapi_spec_parser/rest_api_tool.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -161,9 +161,9 @@ def __init__(
161161
request completes, so the factory must return a fresh client on each
162162
call. This lets callers configure proxies, HTTP/2, custom transports
163163
(e.g. request signing), or any other ``httpx.AsyncClient`` option
164-
that ``ssl_verify`` can't reach. When ``None`` (default), behaviour
165-
is unchanged: a fresh ``httpx.AsyncClient(verify=..., timeout=None)``
166-
is created per request. Mirrors the pattern exposed for MCP by
164+
that ``ssl_verify`` can't reach. When ``None`` (default), a fresh
165+
``httpx.AsyncClient(verify=..., timeout=None)`` is created per
166+
request. Mirrors the pattern exposed for MCP by
167167
``StreamableHTTPConnectionParams.httpx_client_factory``.
168168
credential_key: Optional stable key used for interactive auth and
169169
credential caching.

0 commit comments

Comments
 (0)