Skip to content
Automation
Agent

BUILT_IN_TOOLS

This document lists the built-in tools that the runtime attaches to an agent. It explains what each tool does and when the runtime attaches it.

From plugin
n8n
211k10 skills10 agents2 commands

Claude Code

> /plugin marketplace add n8n-io/n8n
> /plugin install n8n@n8n

Agent definition

BUILT_IN_TOOLS.md

Built-in agent tools

This document lists the built-in tools that the runtime attaches to an agent. It explains what each tool does and when the runtime attaches it.

The runtime attaches these tools in [`agent-runtime-reconstruction.service.ts`](./agent-runtime-reconstruction.service.ts). The main entry points are `injectRuntimeDependencies` and `attachTopLevelTools`.

Before you add a built-in tool

Keep the number of built-in tools low. A long tool list costs tokens and makes tool selection harder for the model. Native tool search can defer definitions. Unsupported routes load the full catalog into the model context.

  • Check the list in this document first.
  • Extend an existing tool when it covers the use case. Do not add a similar tool.
  • Update this document when you add, remove, or change a built-in tool.

Tool visibility

The runtime enables native tool deferral during agent reconstruction. Direct OpenAI Responses routes use native tool search from GPT-5.4, except GPT-5.4 Nano. Direct Anthropic Messages routes use it from Claude 4.5. Numeric version rules include later versions and dated snapshots. See the [native deferral policy](../../../../@n8n/agents/docs/prompt-caching.md#native-tool-deferral). The runtime checks the selected model and effective endpoint before each run. Other providers, older versions, unknown model ID formats, Chat Completions, custom endpoints, and Gateway credits use the complete eager catalog.

These local tools stay eager when they are attached:

  • `workspace_read_file`
  • `workspace_read_files`
  • `workspace_read_tool_result`
  • `workspace_write_file`
  • `workspace_str_replace_file`
  • `workspace_edit_files`
  • `workspace_execute_command`
  • `load_skill`
  • `mark_session_failed`
  • `create_plan`
  • `read_plan`
  • `update_plan`
  • `close_plan`
  • `background_jobs`

Planning and Continue must not depend on tool discovery. Their schemas stay in model context when the tools are attached. The existing feature flags and runtime rules still control whether the tools are attached.

Other eligible local tools are deferred. This includes built-in, custom, workflow, node, integration, knowledge, memory, and MCP tools. Provider-native tools stay eager. A local tool also stays eager when it has an explicit cache marker or `deferLoading: false`.

The channel tool `do_not_respond` also stays eager when attached. Its definition sets `deferLoading: false` for both supported native search providers.

Deferral changes model visibility only. All authorized handlers stay in the execution registry. Validation, approval, and cancellation use the same paths. The catalog, tool order, and instructions stay stable during discovery. Search results stay in conversation history through memory and approval resume.

The same policy applies to inline and delegated children. The runtime checks each child's selected model. There is no feature flag or Agent Builder setting.

Tools attached to every agent

`get_environment`

  • Purpose: Returns the current date and time in ISO format, the instance timezone (IANA), and the day of week. The model calls it when it reasons about "today", deadlines, or schedules.
  • Attach condition: Always attached.
  • Source: [`tools/environment-tool.ts`](./tools/environment-tool.ts).

`read_binary_data`

  • Purpose: Reads a file by its fileId, or by `sandbox:<path>` for a file of `outputs/`. The tool checks that the thread can read the file and that its bytes are still in storage. Other types than images, PDFs and text return an error.
  • Images and PDFs go to the model as file parts. The model must support the type: PNG, JPEG, GIF and WebP for images. The limit is the chat attachment size (10 MB). The file stays attached in later model calls, under the same budget as user files. A file outside the budget shows the text `[File "<name>" (fileId: <id>) is not attached now.]`.
  • The tool description tells the model to read a file that is not attached now again, and not to read a file that is already attached.
  • Text files (up to 200 KB) go into the tool result as text, one time. The tool result size guard applies to them, and later model calls do not load them again.
  • Attach condition: The agent is not an inline agent.
  • Source: [`tools/read-binary-data.tool.ts`](./tools/read-binary-data.tool.ts).

Workspace and knowledge tools

Attach condition: The sandbox is on and the agent is not an inline agent. The runtime attaches them through `agent.workspace(...)` in `attachWorkspaceAndKnowledge`. A delegated sub-agent gets the same tools scoped to its own folder in the parent workspace.

Source: [`packages/@n8n/agents/src/workspace/tools/`](../../../../@n8n/agents/src/workspace/tools/).

| Tool | Purpose | | --- | --- | | `workspace_read_file` | Reads a file from the workspace. | | `workspace_read_files` | Reads several files, or line ranges of them, in one call. | | `workspace_read_tool_result` | Reads the full result of an earlier tool call. | | `workspace_write_file` | Writes a file to the workspace. | | `workspace_str_replace_file` | Replaces a string in a workspace file. | | `workspace_edit_files` | Applies several writes and replacements in one call, and reports each result. | | `workspace_append_file` | Appends content to a workspace file. | | `workspace_list_files` | Lists the files in the workspace. | | `workspace_file_stat` | Returns metadata for a workspace file. | | `workspace_mkdir` | Creates a directory in the workspace. | | `workspace_delete_file` | Deletes a file from the workspace. | | `workspace_copy_file` | Copies a file in the workspace. | | `workspace_move_file` | Moves a file in the workspace. | | `workspace_rmdir` | Removes a directory from the workspace. | | `workspace_execute_command` | Runs a shell command in the sandbox. | | `workspace_list_processes` | Lists the processes that run in the sandbox. | | `workspace_kill_process` | Stops a process in the sandbox. |

`import_files`

  • Purpose: Copies conversation files by fileId
Read more
@n8n-io
Ships withn8n

Fair-code platform to build and deploy AI agents and workflows. Combine a visual canvas with custom code, run it self-hosted or in the cloud, and connect to 1500+ integrations. AI automation you can trust with real work, from prototype to production.

211k12 skills10 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
210.9k
Star history of n8n-io/n8n on GitHub, a chart by star-history.com

Other agents on n8n.

developer

developer

Agent

Use this agent for any n8n development task - frontend (Vue 3), backend (Node.js/TypeScript), workflow engine, node creation, or…

@n8n-io@n8n-ioInstall Agent
linear-issue-triager

linear-issue-triager

Agent

Use this agent proactively when a Linear issue is created, updated, or needs comprehensive analysis. This agent performs thorough…

@n8n-io@n8n-ioInstall Agent
episodic-memory-capture

episodic-memory-captur…

Agent

Capture-capable memory backends must implement `EpisodicMemoryCaptureMethods`. This includes `getEntriesByContentHashes(scope,…

@n8n-io@n8n-ioInstall Agent
observation-log-storage

observation-log-storag…

Agent

Observational memory requires a `BuiltObservationLogStore` backend. The backend must implement `commitObservationLogBatch`. The…

@n8n-io@n8n-ioInstall Agent
prompt-caching

prompt-caching

Agent

`Agent.promptCaching()` generates provider-specific `providerOptions` for Anthropic, Claude on OpenRouter and Vertex, and OpenAI.…

@n8n-io@n8n-ioInstall Agent
PLAN_TASK_STATUS

PLAN_TASK_STATUS

Agent

Each task has one source of status. A parent-run task stores its status and timestamps in the plan. A delegated task stores one…

@n8n-io@n8n-ioInstall Agent

More agents from other plugins.

aris-fanout-leaf

aris-fanout-leaf

Agent

Read-only leaf worker for one bounded ARIS fan-out shard. Never delegates, writes files, or renders verdicts.

aris2w18k
@wanshuiyin@wanshuiyinInstall Agent
GLOBAL

GLOBAL

Agent

本文件包含所有 Agent 必须遵守的通用规则。各 Agent 的 SOUL.md 可覆盖此处设定。

edict7w17k
@cft0808@cft0808Install Agent
code-reviewer
Auto-invoked

code-reviewer

Agent

Expert code review specialist. Proactively reviews code for quality, security, and maintainability. Use immediately after writing…

@galaxy-dawn@galaxy-dawnInstall Agent

Questions about BUILT_IN_TOOLS.

Which coding agents can use BUILT_IN_TOOLS?
BUILT_IN_TOOLS installs in Claude Code and Cursor: each loads subagents from .claude/agents, so copy the file there. Flowy's auto-invocation runs in Claude Code only.