
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
Complete n8n API integration for Claude Desktop and Cursor - Manage workflows, automate tasks, and control every aspect of n8n directly through AI conversations.
Transform your n8n workflow management with natural language commands. Create complex automations, monitor executions, manage credentials, and orchestrate your entire n8n infrastructure without leaving your IDE.
This server is optimized to minimize token consumption, addressing one of the biggest issues with MCP servers - excessive API token usage.
n8n_list_workflows_summary endpointSee TOKEN_OPTIMIZATION.md for detailed usage guide.
This is the easiest way to get started:
npm install -g mcp-n8n
Get your n8n API credentials:
Configure Claude Desktop:
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (Mac/Linux) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
Option A - Using global installation (if you ran npm install -g mcp-n8n):
{
"mcpServers": {
"n8n": {
"command": "mcp-n8n",
"env": {
"N8N_BASE_URL": "https://your-n8n-instance.com",
"N8N_API_KEY": "your-api-key-here"
}
}
}
}
Option B - Using npx (no installation needed, always latest version):
{
"mcpServers": {
"n8n": {
"command": "npx",
"args": ["-y", "mcp-n8n"],
"env": {
"N8N_BASE_URL": "https://your-n8n-instance.com",
"N8N_API_KEY": "your-api-key-here"
}
}
}
}
Add to Cursor MCP settings (Settings → Extensions → MCP):
Recommended - Using npx (always uses latest version):
{
"mcpServers": {
"n8n": {
"command": "npx",
"args": ["-y", "mcp-n8n"],
"env": {
"N8N_BASE_URL": "https://your-n8n-instance.com",
"N8N_API_KEY": "your-api-key-here"
}
}
}
}
Note: Cursor requires using
npxfor MCP servers. The-yflag automatically installs/updates the package without prompting.
Once configured, interact with n8n using natural language:
"Create a workflow that monitors my Gmail inbox and sends
Slack notifications for important emails"
"Build a daily report workflow that pulls data from my database,
generates charts, and emails them to my team"
"I need a WhatsApp chatbot with AI for customer support"
→ Automatically creates workflow from "WhatsApp AI Response Bot" template
"Create an automated stock analysis workflow"
→ Uses "Automated Stock Analysis with GPT-4" template
"Show me all active workflows in the production project"
→ Uses n8n_list_workflows_summary for efficient token usage
"Show me the details of workflow abc123"
→ Uses n8n_get_workflow to fetch complete details only when needed
"Deactivate the 'Daily Backup' workflow"
"What went wrong with execution abc123?"
"Show me the last 10 failed executions"
"Retry all failed executions from workflow xyz456"
"Delete all successful executions older than 30 days"
n8n_create_workflow - Create new workflowsn8n_list_workflows_summary - ⚡ Token-efficient listing (id, name, active, tags only)n8n_list_workflows - List with full details and optional field filteringn8n_get_workflow - Get detailed workflow informationn8n_update_workflow - Modify existing workflowsn8n_delete_workflow - Remove workflows permanentlyn8n_activate_workflow - Enable workflow executionn8n_deactivate_workflow - Pause workflow executionn8n_transfer_workflow - Move between projectsn8n_get_workflow_tags - View workflow tagsn8n_update_workflow_tags - Modify workflow tagsn8n_list_workflow_templates - Browse available templatesn8n_get_workflow_template - View template detailsn8n_create_workflow_from_template - Create from template100 Included Templates across 13 categories:
n8n_list_executions - Filter by status, workflow, projectn8n_get_execution - Detailed execution datan8n_delete_execution - Remove execution recordsn8n_retry_execution - Retry failed executionsn8n_create_credential - Add new credentialsn8n_delete_credential - Remove credentials (owner only)n8n_get_credential_schema - Discover required fieldsn8n_transfer_credential - Move between projectsTags: Create, list, get, update, delete Variables: Create, list, update, delete Users: List, create, get, delete, change role Projects: Create, list, update, delete, manage users
n8n_generate_audit - Security audit reportsn8n_pull_source_control - Version control integrationTotal: 41 tools for complete n8n management
mcp-n8n/
├── src/
│ ├── index.ts # MCP server implementation
│ ├── n8n-client.ts # n8n API client
│ └── types.ts # TypeScript definitions
├── examples/
│ ├── templates-metadata.json
│ └── *.json # Pre-built workflow templates
├── dist/ # Compiled output
├── QUICKSTART.md # Quick start guide
├── EXAMPLES.md # Usage examples
├── NODE_REFERENCE.md # API documentation
└── package.json
If you want to contribute or test local changes:
# Clone repository
git clone https://github.com/leosepulveda/mcp-n8n.git
cd mcp-n8n
# Install dependencies
npm install
# Build
npm run build
# Development with auto-rebuild
npm run watch
For Claude Desktop, add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"n8n": {
"command": "node",
"args": ["/absolute/path/to/mcp-n8n/dist/index.js"],
"env": {
"N8N_BASE_URL": "https://your-n8n-instance.com",
"N8N_API_KEY": "your-api-key-here"
}
}
}
}
For Cursor, add to MCP settings:
{
"mcpServers": {
"n8n": {
"command": "node",
"args": ["/absolute/path/to/mcp-n8n/dist/index.js"],
"env": {
"N8N_BASE_URL": "https://your-n8n-instance.com",
"N8N_API_KEY": "your-api-key-here"
}
}
}
}
Important: Replace /absolute/path/to/mcp-n8n/ with the actual absolute path to your cloned repository (e.g., /Users/yourname/projects/mcp-n8n/).
# Set environment variables
cp .env.example .env
# Edit .env with your credentials
# Build and test
npm run build
node dist/index.js
To run the main script, execute:
python main.py
To run the tests, execute:
pytest test_main.py
Contributions are welcome! Please feel free to submit a Pull Request.
git checkout -b feature/AmazingFeature)git commit -m 'Add some AmazingFeature')git push origin feature/AmazingFeature)This project is licensed under the MIT License - see the LICENSE file for details.
.env files with credentialsProblem: "Cannot connect to n8n API"
N8N_BASE_URL is correct and accessibleProblem: "Insufficient permissions"
Problem: "Template not found"
examples/ directory is presenttemplates-metadata.json existsFAQs
MCP server for n8n API - Complete integration for workflow automation
The npm package mcp-n8n receives a total of 70 weekly downloads. As such, mcp-n8n popularity was classified as not popular.
We found that mcp-n8n demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.