Large Language ModelsGenerate imagesGenerate videos

n8n MCP Server Trigger: URL, Claude Setup and Examples

The n8n MCP Server Trigger lets Claude run your workflows as tools. See which URL to copy, how to protect it with Bearer auth, how to connect Claude Desktop, Claude Code and claude.ai, and four working examples including an image generation workflow.

n8n MCP Server Trigger: URL, Claude Setup and Examples
Cristian Da Conceicao
Founder of Picasso IA

The n8n MCP Server Trigger turns an ordinary workflow into an MCP server that Claude can call. You add the node, attach a few tool nodes, copy one URL, and Claude can suddenly read a spreadsheet, post to Slack, run a sub-workflow or start an image job, with no server code on your side. Three details decide whether that works or fails silently: which URL you copy, how you protect it, and how Claude connects to it.

This article sorts out all three. You get a config file you can paste, four example workflows, a table of the failures that show up most often, and the exact option names n8n uses in the editor, taken from the node documentation.

What the Trigger Actually Does

Developer hands typing on a laptop in soft morning light

Most n8n triggers start a workflow and pass data to the next node. The MCP Server Trigger works differently. It does not pass data downstream. It only connects to tool nodes, and it exposes those tools to any MCP client that knows its URL. When Claude asks what the server can do, n8n answers with the list of attached tools. When Claude picks one, n8n runs it and sends the result back.

That makes the canvas feel closer to an API definition than to an automation. Each tool is a capability, and the tool name plus its description is what Claude reads to decide when to use it. The node speaks Server-Sent Events (SSE) and streamable HTTP. It does not support stdio, which is why Claude Desktop needs a small bridge, shown later.

One Node, Many Tools

Attach as many tool nodes as you need: Google Sheets Tool, Gmail Tool, HTTP Request Tool, Code Tool, Calculator, or the Custom n8n Workflow Tool that calls another workflow. The last one matters most in practice. It lets you keep the heavy logic in normal workflows and expose only a thin, well-named entry point.

💡 Name tools like verbs and describe each in one plain sentence. "find_order: look up an order by its number and return status and shipping date" beats "orders_tool" every time, because Claude picks tools from that text alone.

Server Trigger vs Client Tool

n8n ships two MCP nodes that people mix up. They point in opposite directions.

NodeDirectionTypical use
MCP Server TriggerOther apps call n8nClaude runs your workflows as tools
MCP Client Tooln8n calls other appsAn n8n AI agent uses tools from an outside MCP server

If you want Claude to use n8n, you need the trigger. If you want an n8n agent to use somebody else's tools, you need the client tool.

Finding the Right MCP URL

Overhead view of a notebook with two hand-drawn lanes and sticky notes

Open the trigger and you see two URLs at the top of the node panel. Copying the wrong one is the most common first mistake, and it produces the most confusing symptom: everything works while the editor is open and stops the moment you close it.

Test URL vs Production URL

Test URLProduction URL
Becomes active whenYou click Listen for Test Event or run an inactive workflowYou publish the workflow
Where you see callsLive in the editor canvasOnly in the Executions tab
Best forTrying one tool call while buildingClaude Desktop, Claude Code and claude.ai
LifetimeOnly while the editor is listeningAs long as the workflow stays published

Point Claude at the test URL and the demo works, then breaks as soon as you leave the tab. Point it at the production URL and the workflow answers around the clock, with every call logged in Executions where you can inspect inputs and outputs.

💡 Copy the URL straight from the node instead of typing it. On most installs the production address looks like https://n8n.example.com/mcp/your-path, and the test address swaps /mcp/ for /mcp-test/. Treat that shape as a hint and trust what the node shows.

Pick a Stable Path

The Path parameter arrives pre-filled with a random string so two workflows never collide. You can replace it with something readable, route parameters included, so your Claude config survives a workflow rebuild. Use one path per assistant: orders-assistant, support-lookup, image-studio.

One more rule that trips people up: an inactive workflow does not serve MCP requests. If Claude connects but sees no tools, check that the workflow is published before anything else.

Lock It Down With Bearer Auth

Brushed steel padlock on a server rack door

The trigger offers three Authentication options: None, Bearer auth and Header auth. None is fine for a throwaway test on your laptop. Anything reachable from outside a trusted network needs one of the other two, because a public MCP URL with no auth is a public button that runs your workflows.

Bearer or Header Auth

With Bearer auth, the client sends an Authorization: Bearer <token> header. With Header auth, you choose the header name and value yourself, for example X-MCP-Token. Pick Bearer unless a gateway in front of n8n already expects a custom header.

  1. Open the trigger and set Authentication to Bearer auth.
  2. Create a credential and paste a long random token. openssl rand -hex 32 produces a good one.
  3. Store the token in a password manager. You need it again for the Claude config.
  4. Save and publish the workflow again so the change goes live.

Keep the Tool List Short

Every attached tool is something a prompt can trigger. A model that can read rows and also delete them will eventually delete one when a request is ambiguous. Give each assistant a narrow set of tools, read-only wherever possible, and hard-code the risky parameters such as the Slack channel or the spreadsheet ID instead of letting Claude choose them.

The model on the other end matters too. Strong tool-calling models such as Claude Sonnet 5 and Claude Fable 5 are good test partners on PicassoIA: paste your tool descriptions into a chat, send ten sample requests, and check which tool the model would pick for each. Rewrite any description that causes a wrong pick before you ever touch the workflow.

Connect Claude to Your Server

Developer in profile at a standing desk beside a monitor with a blurred diagram

Claude reaches an MCP server through three different doors, and each one wants the same production URL in a slightly different wrapper.

Claude surfaceHow it connectsBest for
Claude Desktopmcp-remote bridge in a JSON configPersonal use, local or remote n8n
Claude Codeclaude mcp add with a header flagDevelopers working in a terminal
claude.aiCustom connector in settingsTeams, needs a public HTTPS address

Claude Desktop With mcp-remote

Claude Desktop starts local stdio servers, and the trigger does not speak stdio. The mcp-remote package sits in the middle and translates. Open the config file (on Windows %APPDATA%\Claude\claude_desktop_config.json, on macOS ~/Library/Application Support/Claude/claude_desktop_config.json) and add this entry:

{
  "mcpServers": {
    "n8n": {
      "command": "npx",
      "args": [
        "mcp-remote",
        "https://n8n.example.com/mcp/orders-assistant",
        "--header",
        "Authorization: Bearer ${AUTH_TOKEN}"
      ],
      "env": {
        "AUTH_TOKEN": "paste-your-bearer-token-here"
      }
    }
  }
}

The token lives in env and the header argument references it, so the argument stays one clean string. You need Node.js installed because npx fetches the bridge on first launch. Quit Claude Desktop fully, reopen it, and the tools appear in the tools menu of a new chat.

Claude Code From the Terminal

Developer at a dark terminal in a dim room

Claude Code can talk to remote servers directly, so no bridge is needed:

claude mcp add --transport http n8n https://n8n.example.com/mcp/orders-assistant \
  --header "Authorization: Bearer YOUR_TOKEN"

Use --transport http for streamable HTTP. If your n8n version only exposes the older SSE endpoint, switch the flag to --transport sse. Run claude mcp list to confirm the server shows as connected, then ask Claude Code to "list the n8n tools" as a first check.

claude.ai Custom Connectors

In claude.ai, open your connector settings and add a custom connector with the production URL. Requests come from Anthropic's side, not from your laptop, so the address must be reachable from the internet over HTTPS. A localhost address or a private IP will not work. Put n8n behind a reverse proxy or a tunnel first.

💡 n8n documents one quirk: claude.ai prompts for a sign-in even when the trigger has authentication turned off, because it assumes every MCP endpoint uses user authentication. A sign-in prompt does not mean the trigger is misconfigured.

Four Examples Worth Building

Four colleagues around a wooden table with laptops

Each example below is one tool node attached to the same trigger. Start with the first, confirm Claude can call it, then add the rest one at a time.

Look Up Rows in Sheets

Attach a Google Sheets Tool, set the operation to get rows, and filter the order number column with an expression that lets Claude fill the value:

{{ $fromAI('order_number', 'The order number the customer gave', 'string') }}

Now "Where is order 48213?" becomes a real lookup. Tool description: Look up one order by number and return status and shipping date. It is read-only, so it is the safest first tool to expose.

Post a Slack Summary

Add a Slack Tool with the send message operation. Hard-code the channel and let Claude fill only the text:

{{ $fromAI('summary', 'A two sentence summary to post', 'string') }}

Because the channel is fixed in the node, a confused prompt cannot post anywhere else. That one decision removes most of the risk of giving an assistant write access.

Call a Sub-Workflow

The Custom n8n Workflow Tool runs another workflow that starts with an Execute Workflow Trigger. This is where multi-step jobs belong: enrich a lead, check the CRM, write a Notion page, return a short result. Claude sees one tool with one description, and all the branching stays in a workflow you can test on its own.

Generate Images Through an API

Photographer comparing a monitor with a printed mountain lake photograph

An HTTP Request Tool lets Claude start image jobs from a chat. The PicassoIA API uses a Replicate-style design: you create a prediction, then poll it until the result is ready. The base address is https://api.picassoia.com/v1 and calls use a Bearer token that starts with pia_sk_, created on the PicassoIA API page.

  1. Add an HTTP Request Tool named create_image with the description Create a photorealistic 16:9 image from a text prompt and return the prediction id.
  2. Set the method to POST and the URL to https://api.picassoia.com/v1/models/picassoia/picassoia-image/predictions.
  3. Set authentication to Bearer and paste your pia_sk_ token.
  4. Send a JSON body with an input object whose prompt comes from $fromAI.
  5. Add a second HTTP Request Tool named get_image that sends a GET to https://api.picassoia.com/v1/predictions/ followed by the prediction id Claude passes in.

Claude creates the job, waits a few seconds, polls get_image, and shows you the final URL. The model behind the first call is PicassoIA Image, and PicassoIA Image Editor Pro handles edits with the same pattern. Accounts run up to 5 predictions at once, and prompts can reach 4,000 characters, so write the tool description to tell Claude to send one request at a time. Check the API page for response fields and plan requirements before you rely on this in production.

Fixing Common Failures

Server room corridor with a patch panel and blue ethernet cables

Most MCP Server Trigger problems come from one of a handful of causes. Before changing anything, open the Executions tab. A call that never appears there never reached n8n, which points at the URL, the proxy or the Claude config. A call that appears with an error points at the tool node itself.

SymptomLikely causeFix
Claude connects but lists no toolsWorkflow is not published, or no tool node is attachedPublish it and attach at least one tool
Works during testing, dead laterConfig uses the test URLSwitch to the production URL
401 or 403 errorToken mismatch or wrong auth typeRecreate the credential and update the Claude config
Connection drops after a few secondsProxy buffers the streamApply the nginx settings below
Random failures with many workersRequests land on different replicasRoute /mcp* to one replica
Tools run but results look staleClaude Desktop was not restartedQuit fully and reopen

Connection Drops Behind nginx

SSE and streamable HTTP are long-lived connections. A reverse proxy that buffers responses holds the stream until it fills, and Claude sees a hang. n8n recommends turning off proxy buffering, gzip compression and chunked transfer encoding on the MCP path, and clearing the Connection header:

location /mcp/ {
    proxy_pass http://n8n:5678;
    proxy_http_version 1.1;
    proxy_set_header Connection '';
    proxy_buffering off;
    gzip off;
    chunked_transfer_encoding off;
}

Queue Mode Routing

In queue mode with several webhook replicas, each persistent connection must stay on the instance that opened it. n8n documents routing all /mcp* requests to a single, dedicated webhook replica. Add a rule in your load balancer for that path and the random failures stop.

Try It With Your Own Images

Woman smiling at a monitor showing a bright coastal landscape

You now have the full loop: a trigger node, a production URL, Bearer auth, a Claude config that points at it, and tools that do real work. The image workflow is the most fun to try first, because the result appears right in your chat and you can judge it in seconds.

Open Picasso IA and run a few prompts by hand before you wire up the API. Compare GPT Image 2, Seedream 4.5 and Nano Banana 2 Lite on the same prompt, then keep the style that fits your project. Once you know which prompt shapes work, put them into the tool description so Claude writes better prompts on its own.

Build the first tool today: one trigger, one read-only tool, one Claude connection. Add a second tool only after the first runs cleanly, and your assistant will grow without ever surprising you.

Share this article