Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/tools-custom/openapi-tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ The process involves these main steps when you use `OpenAPIToolset`:

4. **`RestApiTool` Functionality**: Each generated `RestApiTool`:
* **Schema Generation**: Dynamically creates a `FunctionDeclaration` based on the operation's parameters and request body. This schema tells the LLM how to call the tool (what arguments are expected).
* **Execution**: When called by the LLM, it constructs the correct HTTP request (URL, headers, query params, body) using the arguments provided by the LLM and the details from the OpenAPI spec. It handles authentication (if configured) and executes the API call using the `requests` library.
* **Execution**: When called by the LLM, it constructs the correct HTTP request (URL, headers, query params, body) using the arguments provided by the LLM and the details from the OpenAPI spec. It handles authentication (if configured) and executes the API call using the `httpx` library. By default, `RestApiTool` executes HTTP requests with no timeout (`timeout=None`), which means the agent will wait indefinitely for a response. This accommodates long-running services, but you should be aware of the potential for the agent to hang if the external service is unresponsive.
* **Response Handling**: Returns the API response (typically JSON) back to the agent flow.

5. **Authentication**: You can configure global authentication (like API keys or OAuth - see [Authentication](/adk-docs/tools/authentication/) for details) when initializing `OpenAPIToolset`. This authentication configuration is automatically applied to all generated `RestApiTool` instances.
Expand Down
Loading