MCP Call Tool
Controlled node
Overview
The MCP Call Tool node connects to a Model Context Protocol (MCP) server and executes tools. It supports both single tool execution and batch processing of multiple sequential tool calls. This node handles connection lifecycle management, authentication via custom headers, timeout configuration, and comprehensive error handling for MCP operations.
The node operates in two mutually exclusive modes:
- Single Tool Mode: Call one tool using the
nameandargumentsinputs - Batch Mode: Execute multiple tools sequentially using the
instructionsinput array
You must provide either the name input (for single tool calls) OR the instructions input (for batch calls), but not both. Providing both will result in an error.
Inputs
| Input | Type | Description | Default |
|---|---|---|---|
| Run | Event | Fires when the node starts running | - |
| URL | Text | The MCP server endpoint URL | - |
| Headers | Dictionary | Optional HTTP headers for authentication or custom configuration (e.g., API keys) | {} |
| Name | Text | The name of the tool to call (required for single tool mode) | - |
| Arguments | Dictionary | Arguments to pass to the tool (for single tool mode) | {} |
| Instructions | Dictionary | Array of tool call objects for batch execution. Each object requires a name property and optionally an arguments property | - |
| Timeout | Number | Request timeout in milliseconds | 60000 |
Outputs
| Output | Type | Description |
|---|---|---|
| Done | Event | Fires when the node has finished executing |
| Result | Data | For single mode: the MCP tool result. For batch mode: an object containing results (array of execution results) and totalSteps (count of executed steps) |
Runtime Behavior and Defaults
- Connection Lifecycle: The node automatically creates and closes the MCP client connection for each execution
- Timeout Handling: If the timeout is not specified or invalid, defaults to 30000ms (30 seconds) at runtime, though the UI default is 60000ms
- Batch Execution: When using
instructions, tools execute sequentially with a 500ms delay between calls to prevent server overload - Error Handling: In batch mode, execution stops immediately when any tool call fails. The result will contain error details for the failed step
- Result Structure: Successful batch results include
success: true, theresultdata, andstepnumber. Failed steps includesuccess: falseanderrormessage
Example
Single Tool Call
Connect a Start node to the Run input, provide the MCP server URL, tool name, and arguments:
URL: "https://api.example.com/mcp"
Name: "get_weather"
Arguments: { "city": "London", "units": "metric" }
Batch Tool Calls
Provide an array of instructions to execute multiple tools in sequence:
URL: "https://api.example.com/mcp"
Instructions: [
{ "name": "create_file", "arguments": { "filename": "report.txt" } },
{ "name": "write_content", "arguments": { "content": "Hello World" } }
]
The result will contain an array with the outcome of each step, including success status and any returned data.