overview

A guide to n8n-decanter’s setup for coding agents, including shared AGENTS.md instructions and automated checks. n8n is a tool for building connected, automated workflows.

In plain words
What is it for?
Scaffolding agent instructions, checking n8n node edits, and detecting broken references after workflow nodes are renamed.
Why use it?
It keeps different coding agents aligned with the same repository rules and catches unsafe workflow or code changes early.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/buttjer/n8n-decanter/overview
Clone the repo
git clone --depth 1 https://github.com/buttjer/n8n-decanter
Per session 18 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,966 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00018 $0.02966
Opus 5 $0.00009 $0.01483
Sonnet 5 $0.00004 $0.00593
Haiku 4.5 $0.00002 $0.00297

Measured yesterday against content hash 2f28774af4d7, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

overview scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

| Agent started at | `<syncdir>/.mcp.json` | `<syncdir>/.claude/settings.json` | repo root's `.claude/settings.json` |
docs/agents/overview.md · 165 lines

How it starts

The opening of the file, as written. The whole thing — 165 lines — stays where its author put it; the contents beside it link to each section on GitHub.

n8n-decanter is built to let AI coding agents work on workflows safely. A scaffolded sync dir (init) contains everything an agent needs to behave:

  • AGENTS.md — the tool-agnostic contract for the repo: how code is stored here (placeholders, code/, markers), the file-ownership rules, the rename checklist, and how to verify changes. Codex and opencode read it natively; Claude Code reads it through a one-line import in CLAUDE.md.
  • Per-agent configs — Claude Code, Cursor, Codex, opencode — kept as thin pointers to AGENTS.md, so every agent follows the same rules.
  • Guard hooks — on Claude Code and opencode, edits that would break a hard invariant are blocked before the write happens; a Claude Code PostToolUse hook runs preflight --offline after node edits. A second PostToolUse hook watches MCP update_workflow calls and speaks up when a renameNode leaves $('Old Name') references behind — n8n's rename rewrites the node name and connections only, so those refs are the caller's to repair (see pull). It scans for the old name rather than running preflight, because it fires before the background snapshot refresh, while every reference still resolves. The same rules are enforced by the CLI at push time regardless of who made the edit. Each hook finds the sync dir from its own installed location, so it behaves the same whether the agent was started in the sync dir or above it. On Claude Code these live in .claude/settings.jsonproject scope, meant to be committed, so everyone who clones the repo gets the same permissions and hooks. .claude/settings.local.json stays yours for machine-specific rules: permission lists merge across the two and a deny beats an allow, so your local file can add to the policy but cannot unblock what the project denies.

Restart the agent after init. MCP servers, permission rules and hooks are read at agent startup, and init is normally run from inside the very session it configures — so that session has no n8n-instance tools and no deny rules until it restarts (or /reloads). There is no hot-reload; init prints the reminder when it first scaffolds those files, and the scaffolded AGENTS.md tells the agent to ask for a restart rather than route around the missing guard.

But a restart is only half the diagnosis. ".mcp.json declares n8n-instance and the tools aren't there" has two causes, and they need opposite answers:

Cause Symptom is Fix
The wiring is newinit ran inside this very session temporary restart / /reload
The wiring is below the launch dir — nested sync dir, agent started at the repo root permanent start the agent in the sync dir, or wire the root (below)

The discriminator is a path comparison: is the .mcp.json in question below the directory the agent was started in? If it is, no restart can ever load it — startup only reads the launch dir and its ancestors (next section), so restarting reruns exactly the discovery that already missed the file. Advising a restart there costs the user a session and teaches them nothing. The scaffolded AGENTS.md carries both branches, so an agent that reads it can tell them apart; init names the one you are actually in when it scaffolds.

Where the agent wiring loads from

init scaffolds .mcp.json, .claude/settings.json and the hook scripts into the sync dir. When the sync dir is where you start the agent, that is the end of the story. When it is a subfolder of a bigger repo, what actually loads depends on where the agent was started — and the files disagree about it (matrix verified against Claude Code 2.1.x):

Agent started at <syncdir>/.mcp.json <syncdir>/.claude/settings.json repo root's .claude/settings.json
the repo root not loaded not loaded loaded
the sync dir loaded (merged with the repo root's) loaded not loaded

Read the full file on GitHub · 165 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 165 lines · 18 tokens per session scan B 2f28774af4d7

Subscribe to this mod's changes

overview is an agent published in the GitHub repository buttjer/n8n-decanter (2 stars, last pushed yesterday), licensed MIT. It adds 18 tokens to every session and 2,966 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other agents, from other repositories

linear-issue-triager

Use this agent proactively when a Linear issue is created, updated, or needs comprehensive analysis. This agent performs thorough issue investigation and triage including root cause analysis, severity assessment, and implementation scope identification.

n8n-io/n8n · 47 tokens

AGENTS

Conventions for the @n8n/agents package.

n8n-io/n8n · 0 tokens

developer

Use this agent for any n8n development task - frontend (Vue 3), backend (Node.js/TypeScript), workflow engine, node creation, or full-stack features. The agent automatically applies n8n conventions and best practices. Examples: user: 'Add a new button to the workflow editor' assistant: 'I'll use the developer agent to…

n8n-io/n8n · 0 tokens

form

FORM — Design. Visual system, UI architecture, motion, accessibility, design PRDs. Use when a human will see the work, when a landing page or product UI is requested, or when Forge is about to invent a look. Use proactively for any user-facing surface.

jmenzies722/shua-labs · 57 tokens

aria

ARIA — AI engineering. New agents, skills, evals, MCP wiring, department growth. Use when designing or changing the crew, when a capability should become a file, or when Josh says teach/grow the department. Use proactively when a one-off prompt is about to become a standing job.

jmenzies722/shua-labs · 62 tokens

axis

AXIS — Architecture. System design, ADRs, irreversible calls, architectural review. Use when the shape of the system is unset, when a shortcut would lock us in, or before Forge writes a feature that spans boundaries. Use proactively for any new product or service.

jmenzies722/shua-labs · 56 tokens