节点 / builtin / ai / aidependencies / tools
HTTP Request Tool
Let an agent send HTTP requests — with a user approval gate on every call.
此内容尚不支持你的语言。
Let an AI agent call web APIs, with your approval before every request is sent.
What it does
Section titled “What it does”HTTP Request Tool is a tool for an agent, not a step in the flow. It has no output port: you connect it to the Tools slot of a Tools Agent, and the agent’s model can call it while it works.
The model chooses the method (GET, POST, PUT, DELETE, PATCH, OPTIONS or HEAD), the URL, optional headers and an optional body. A JSON object body is sent as JSON; any other body is wrapped and sent as {"raw": "..."}. The request is sent the same way as the Http Request node, with the Authentication credential you chose added.
Before anything is sent, an approval row appears in the Executions pane, for example “send a POST request to api.example.com”. It shows the method and host only, never headers, body or credential. You approve or reject. A rejected request is never sent, and the model is told you declined. If nobody answers within 2 minutes, the request is rejected.
When to use it
Section titled “When to use it”- An agent should look up or update a record in an API as part of a task: an order status, a ticket, a webhook.
- The model should decide whether to call the API and with what values.
- You want to see and confirm every outgoing request.
When the call is always the same, use the Http Request node in the flow instead: no model, no approval step.
Inputs and settings
Section titled “Inputs and settings”| 设置项 | 类型 | 作用 |
|---|---|---|
| Authentication | Credential | The authentication to use for requests made by this tool. |
Authentication is the only setting, and it applies to every request the agent makes. Everything else comes from the model on each call, so describe the API in the agent’s Prompt or System message: the base URL, the endpoints and what they return.
Outputs
Section titled “Outputs”This node has no output port. It plugs into a slot on another node instead of passing items along.
- Tools slot of Tools Agent
The API’s response goes back to the model, not to the next node. The agent’s steps output lists each call it made, and its response holds the final answer.
Dependencies and credentials
Section titled “Dependencies and credentials”- Authentication (connection): optional. See Create a connection.
Use the same kinds of credential as the Http Request node, for example a Bearer token or Basic Auth username and password from the API provider. Leave it empty for public APIs. See Create a credential. Never put keys in the prompt.
Example workflow
Section titled “Example workflow”- Get Selected Text reads an order number you highlighted, with Output field name
text. - Tools Agent with Prompt
Find the status of order {{ $input.text }} with GET https://api.example-shop.com/orders/ID, a Chat OpenAI model in Model, and HTTP Request Tool connected to Tools with your shop’s Bearer token in Authentication. - Run it and approve “send a GET request to api.example-shop.com” in the Executions pane.
- Display Markdown shows
{{ $input.response }}.
Common issues
Section titled “Common issues”- The request is never sent. It is waiting for your approval in the Executions pane, or it was rejected after 2 minutes without an answer.
- “Action denied: invalid or blocked URL”. Only
httpandhttpsaddresses on public hosts are allowed.localhost, private network addresses and cloud metadata addresses are refused. - The API answers 401 or 403. Set Authentication, or check that the token is still valid and has access to that endpoint.
- The model calls the wrong URL. Give it the exact base URL and endpoint paths in the Prompt.
Related nodes
Section titled “Related nodes”- Tools Agent: the agent this tool plugs into.
- Http Request: a fixed request as a step in the flow.
- MCP Client Tool: give the agent ready-made tools from an MCP server.
- Action Approval: how the approval gate protects you.