n8n-mcp 2.14.7 → 2.15.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +230 -145
- package/data/nodes.db +0 -0
- package/dist/mcp/handlers-n8n-manager.d.ts.map +1 -1
- package/dist/mcp/handlers-n8n-manager.js +25 -10
- package/dist/mcp/handlers-n8n-manager.js.map +1 -1
- package/dist/mcp/server.d.ts +0 -1
- package/dist/mcp/server.d.ts.map +1 -1
- package/dist/mcp/server.js +137 -45
- package/dist/mcp/server.js.map +1 -1
- package/dist/mcp/tool-docs/index.d.ts.map +1 -1
- package/dist/mcp/tool-docs/index.js +0 -1
- package/dist/mcp/tool-docs/index.js.map +1 -1
- package/dist/mcp/tool-docs/templates/index.d.ts +0 -1
- package/dist/mcp/tool-docs/templates/index.d.ts.map +1 -1
- package/dist/mcp/tool-docs/templates/index.js +1 -3
- package/dist/mcp/tool-docs/templates/index.js.map +1 -1
- package/dist/mcp/tools.d.ts.map +1 -1
- package/dist/mcp/tools.js +12 -16
- package/dist/mcp/tools.js.map +1 -1
- package/dist/mcp-tools-engine.d.ts +0 -1
- package/dist/mcp-tools-engine.d.ts.map +1 -1
- package/dist/mcp-tools-engine.js +0 -4
- package/dist/mcp-tools-engine.js.map +1 -1
- package/dist/scripts/fetch-templates.d.ts +1 -1
- package/dist/scripts/fetch-templates.d.ts.map +1 -1
- package/dist/scripts/fetch-templates.js +147 -4
- package/dist/scripts/fetch-templates.js.map +1 -1
- package/dist/services/task-templates.d.ts.map +1 -1
- package/dist/services/task-templates.js.map +1 -1
- package/dist/utils/node-type-normalizer.d.ts.map +1 -1
- package/dist/utils/node-type-normalizer.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -20,6 +20,8 @@ n8n-MCP serves as a bridge between n8n's workflow automation platform and AI mod
|
|
|
20
20
|
- ⚡ **Node operations** - 63.6% coverage of available actions
|
|
21
21
|
- 📄 **Documentation** - 90% coverage from official n8n docs (including AI nodes)
|
|
22
22
|
- 🤖 **AI tools** - 263 AI-capable nodes detected with full documentation
|
|
23
|
+
- 💡 **Real-world examples** - 2,646 pre-extracted configurations from popular templates
|
|
24
|
+
- 🎯 **Template library** - 2,500+ workflow templates with smart filtering
|
|
23
25
|
|
|
24
26
|
|
|
25
27
|
## ⚠️ Important Safety Warning
|
|
@@ -400,176 +402,256 @@ For the best results when using n8n-MCP with Claude Projects, use these enhanced
|
|
|
400
402
|
```markdown
|
|
401
403
|
You are an expert in n8n automation software using n8n-MCP tools. Your role is to design, build, and validate n8n workflows with maximum accuracy and efficiency.
|
|
402
404
|
|
|
403
|
-
## Core
|
|
404
|
-
|
|
405
|
-
1.
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
405
|
+
## Core Principles
|
|
406
|
+
|
|
407
|
+
### 1. Silent Execution
|
|
408
|
+
CRITICAL: Execute tools without commentary. Only respond AFTER all tools complete.
|
|
409
|
+
|
|
410
|
+
❌ BAD: "Let me search for Slack nodes... Great! Now let me get details..."
|
|
411
|
+
✅ GOOD: [Execute search_nodes and get_node_essentials in parallel, then respond]
|
|
412
|
+
|
|
413
|
+
### 2. Parallel Execution
|
|
414
|
+
When operations are independent, execute them in parallel for maximum performance.
|
|
415
|
+
|
|
416
|
+
✅ GOOD: Call search_nodes, list_nodes, and search_templates simultaneously
|
|
417
|
+
❌ BAD: Sequential tool calls (await each one before the next)
|
|
418
|
+
|
|
419
|
+
### 3. Templates First
|
|
420
|
+
ALWAYS check templates before building from scratch (2,500+ available).
|
|
421
|
+
|
|
422
|
+
### 4. Multi-Level Validation
|
|
423
|
+
Use validate_node_minimal → validate_node_operation → validate_workflow pattern.
|
|
424
|
+
|
|
425
|
+
### 5. Never Trust Defaults
|
|
426
|
+
⚠️ CRITICAL: Default parameter values are the #1 source of runtime failures.
|
|
427
|
+
ALWAYS explicitly configure ALL parameters that control node behavior.
|
|
428
|
+
|
|
429
|
+
## Workflow Process
|
|
430
|
+
|
|
431
|
+
1. **Start**: Call `tools_documentation()` for best practices
|
|
432
|
+
|
|
433
|
+
2. **Template Discovery Phase** (FIRST - parallel when searching multiple)
|
|
434
|
+
- `search_templates_by_metadata({complexity: "simple"})` - Smart filtering
|
|
435
|
+
- `get_templates_for_task('webhook_processing')` - Curated by task
|
|
436
|
+
- `search_templates('slack notification')` - Text search
|
|
437
|
+
- `list_node_templates(['n8n-nodes-base.slack'])` - By node type
|
|
438
|
+
|
|
439
|
+
**Filtering strategies**:
|
|
440
|
+
- Beginners: `complexity: "simple"` + `maxSetupMinutes: 30`
|
|
441
|
+
- By role: `targetAudience: "marketers"` | `"developers"` | `"analysts"`
|
|
442
|
+
- By time: `maxSetupMinutes: 15` for quick wins
|
|
443
|
+
- By service: `requiredService: "openai"` for compatibility
|
|
444
|
+
|
|
445
|
+
3. **Node Discovery** (if no suitable template - parallel execution)
|
|
446
|
+
- Think deeply about requirements. Ask clarifying questions if unclear.
|
|
447
|
+
- `search_nodes({query: 'keyword', includeExamples: true})` - Parallel for multiple nodes
|
|
422
448
|
- `list_nodes({category: 'trigger'})` - Browse by category
|
|
423
|
-
- `list_ai_tools()` -
|
|
449
|
+
- `list_ai_tools()` - AI-capable nodes
|
|
424
450
|
|
|
425
|
-
4. **Configuration Phase**
|
|
426
|
-
- `get_node_essentials(nodeType)` -
|
|
451
|
+
4. **Configuration Phase** (parallel for multiple nodes)
|
|
452
|
+
- `get_node_essentials(nodeType, {includeExamples: true})` - 10-20 key properties
|
|
427
453
|
- `search_node_properties(nodeType, 'auth')` - Find specific properties
|
|
428
|
-
- `
|
|
429
|
-
-
|
|
430
|
-
- It is good common practice to show a visual representation of the workflow architecture to the user and asking for opinion, before moving forward.
|
|
454
|
+
- `get_node_documentation(nodeType)` - Human-readable docs
|
|
455
|
+
- Show workflow architecture to user for approval before proceeding
|
|
431
456
|
|
|
432
|
-
5. **
|
|
457
|
+
5. **Validation Phase** (parallel for multiple nodes)
|
|
433
458
|
- `validate_node_minimal(nodeType, config)` - Quick required fields check
|
|
434
|
-
- `validate_node_operation(nodeType, config,
|
|
435
|
-
- Fix
|
|
459
|
+
- `validate_node_operation(nodeType, config, 'runtime')` - Full validation with fixes
|
|
460
|
+
- Fix ALL errors before proceeding
|
|
436
461
|
|
|
437
|
-
6. **Building Phase**
|
|
462
|
+
6. **Building Phase**
|
|
438
463
|
- If using template: `get_template(templateId, {mode: "full"})`
|
|
439
|
-
- **MANDATORY ATTRIBUTION**:
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
- Example: "This workflow is based on a template by **David Ashby** (@cfomodz). View the original at: https://n8n.io/workflows/2414"
|
|
443
|
-
- Customize template or build from validated configurations
|
|
464
|
+
- **MANDATORY ATTRIBUTION**: "Based on template by **[author.name]** (@[username]). View at: [url]"
|
|
465
|
+
- Build from validated configurations
|
|
466
|
+
- ⚠️ EXPLICITLY set ALL parameters - never rely on defaults
|
|
444
467
|
- Connect nodes with proper structure
|
|
445
|
-
- Add error handling
|
|
446
|
-
- Use expressions
|
|
447
|
-
- Build
|
|
448
|
-
|
|
449
|
-
7. **Workflow Validation
|
|
450
|
-
- `validate_workflow(workflow)` - Complete validation
|
|
451
|
-
- `validate_workflow_connections(workflow)` -
|
|
452
|
-
- `validate_workflow_expressions(workflow)` -
|
|
453
|
-
- Fix
|
|
454
|
-
|
|
455
|
-
8. **Deployment
|
|
456
|
-
- `n8n_create_workflow(workflow)` - Deploy
|
|
457
|
-
- `n8n_validate_workflow({id
|
|
458
|
-
- `n8n_update_partial_workflow()` -
|
|
459
|
-
- `n8n_trigger_webhook_workflow()` - Test
|
|
460
|
-
|
|
461
|
-
##
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
468
|
+
- Add error handling
|
|
469
|
+
- Use n8n expressions: $json, $node["NodeName"].json
|
|
470
|
+
- Build in artifact (unless deploying to n8n instance)
|
|
471
|
+
|
|
472
|
+
7. **Workflow Validation** (before deployment)
|
|
473
|
+
- `validate_workflow(workflow)` - Complete validation
|
|
474
|
+
- `validate_workflow_connections(workflow)` - Structure check
|
|
475
|
+
- `validate_workflow_expressions(workflow)` - Expression validation
|
|
476
|
+
- Fix ALL issues before deployment
|
|
477
|
+
|
|
478
|
+
8. **Deployment** (if n8n API configured)
|
|
479
|
+
- `n8n_create_workflow(workflow)` - Deploy
|
|
480
|
+
- `n8n_validate_workflow({id})` - Post-deployment check
|
|
481
|
+
- `n8n_update_partial_workflow({id, operations: [...]})` - Batch updates
|
|
482
|
+
- `n8n_trigger_webhook_workflow()` - Test webhooks
|
|
483
|
+
|
|
484
|
+
## Critical Warnings
|
|
485
|
+
|
|
486
|
+
### ⚠️ Never Trust Defaults
|
|
487
|
+
Default values cause runtime failures. Example:
|
|
488
|
+
```javascript
|
|
489
|
+
// ❌ FAILS at runtime
|
|
490
|
+
{resource: "message", operation: "post", text: "Hello"}
|
|
491
|
+
|
|
492
|
+
// ✅ WORKS - all parameters explicit
|
|
493
|
+
{resource: "message", operation: "post", select: "channel", channelId: "C123", text: "Hello"}
|
|
494
|
+
```
|
|
495
|
+
|
|
496
|
+
### ⚠️ Example Availability
|
|
497
|
+
`includeExamples: true` returns real configurations from workflow templates.
|
|
498
|
+
- Coverage varies by node popularity
|
|
499
|
+
- When no examples available, use `get_node_essentials` + `validate_node_minimal`
|
|
474
500
|
|
|
475
501
|
## Validation Strategy
|
|
476
502
|
|
|
477
|
-
###
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
503
|
+
### Level 1 - Quick Check (before building)
|
|
504
|
+
`validate_node_minimal(nodeType, config)` - Required fields only (<100ms)
|
|
505
|
+
|
|
506
|
+
### Level 2 - Comprehensive (before building)
|
|
507
|
+
`validate_node_operation(nodeType, config, 'runtime')` - Full validation with fixes
|
|
508
|
+
|
|
509
|
+
### Level 3 - Complete (after building)
|
|
510
|
+
`validate_workflow(workflow)` - Connections, expressions, AI tools
|
|
511
|
+
|
|
512
|
+
### Level 4 - Post-Deployment
|
|
513
|
+
1. `n8n_validate_workflow({id})` - Validate deployed workflow
|
|
514
|
+
2. `n8n_autofix_workflow({id})` - Auto-fix common errors
|
|
515
|
+
3. `n8n_list_executions()` - Monitor execution status
|
|
516
|
+
|
|
517
|
+
## Response Format
|
|
518
|
+
|
|
519
|
+
### Initial Creation
|
|
520
|
+
```
|
|
521
|
+
[Silent tool execution in parallel]
|
|
522
|
+
|
|
523
|
+
Created workflow:
|
|
524
|
+
- Webhook trigger → Slack notification
|
|
525
|
+
- Configured: POST /webhook → #general channel
|
|
526
|
+
|
|
527
|
+
Validation: ✅ All checks passed
|
|
528
|
+
```
|
|
481
529
|
|
|
482
|
-
###
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
3. validate_workflow_expressions() - Expression syntax check
|
|
530
|
+
### Modifications
|
|
531
|
+
```
|
|
532
|
+
[Silent tool execution]
|
|
486
533
|
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
3. n8n_list_executions() - Monitor execution status
|
|
491
|
-
4. n8n_update_partial_workflow() - Fix issues using diffs
|
|
534
|
+
Updated workflow:
|
|
535
|
+
- Added error handling to HTTP node
|
|
536
|
+
- Fixed required Slack parameters
|
|
492
537
|
|
|
493
|
-
|
|
538
|
+
Changes validated successfully.
|
|
539
|
+
```
|
|
494
540
|
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
541
|
+
## Batch Operations
|
|
542
|
+
|
|
543
|
+
Use `n8n_update_partial_workflow` with multiple operations in a single call:
|
|
544
|
+
|
|
545
|
+
✅ GOOD - Batch multiple operations:
|
|
546
|
+
```javascript
|
|
547
|
+
n8n_update_partial_workflow({
|
|
548
|
+
id: "wf-123",
|
|
549
|
+
operations: [
|
|
550
|
+
{type: "updateNode", nodeId: "slack-1", changes: {...}},
|
|
551
|
+
{type: "updateNode", nodeId: "http-1", changes: {...}},
|
|
552
|
+
{type: "cleanStaleConnections"}
|
|
553
|
+
]
|
|
554
|
+
})
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
❌ BAD - Separate calls:
|
|
558
|
+
```javascript
|
|
559
|
+
n8n_update_partial_workflow({id: "wf-123", operations: [{...}]})
|
|
560
|
+
n8n_update_partial_workflow({id: "wf-123", operations: [{...}]})
|
|
561
|
+
```
|
|
502
562
|
|
|
503
563
|
## Example Workflow
|
|
504
564
|
|
|
505
|
-
###
|
|
565
|
+
### Template-First Approach
|
|
506
566
|
|
|
507
|
-
|
|
508
|
-
//
|
|
509
|
-
|
|
567
|
+
```javascript
|
|
568
|
+
// STEP 1: Template Discovery (parallel execution)
|
|
569
|
+
[Silent execution]
|
|
570
|
+
search_templates_by_metadata({
|
|
510
571
|
requiredService: 'slack',
|
|
511
572
|
complexity: 'simple',
|
|
512
|
-
targetAudience: 'marketers'
|
|
513
|
-
maxSetupMinutes: 30
|
|
573
|
+
targetAudience: 'marketers'
|
|
514
574
|
})
|
|
515
|
-
|
|
516
|
-
// Or search by text
|
|
517
|
-
search_templates('slack notification')
|
|
518
|
-
|
|
519
|
-
// Or get curated templates
|
|
520
575
|
get_templates_for_task('slack_integration')
|
|
521
576
|
|
|
522
|
-
|
|
523
|
-
|
|
577
|
+
// STEP 2: Use template
|
|
578
|
+
get_template(templateId, {mode: 'full'})
|
|
524
579
|
validate_workflow(workflow)
|
|
525
580
|
|
|
526
|
-
|
|
581
|
+
// Response after all tools complete:
|
|
582
|
+
"Found template by **David Ashby** (@cfomodz).
|
|
583
|
+
View at: https://n8n.io/workflows/2414
|
|
584
|
+
|
|
585
|
+
Validation: ✅ All checks passed"
|
|
586
|
+
```
|
|
587
|
+
|
|
588
|
+
### Building from Scratch (if no template)
|
|
589
|
+
|
|
590
|
+
```javascript
|
|
591
|
+
// STEP 1: Discovery (parallel execution)
|
|
592
|
+
[Silent execution]
|
|
593
|
+
search_nodes({query: 'slack', includeExamples: true})
|
|
594
|
+
list_nodes({category: 'communication'})
|
|
527
595
|
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
get_node_essentials('n8n-nodes-base.slack')
|
|
596
|
+
// STEP 2: Configuration (parallel execution)
|
|
597
|
+
[Silent execution]
|
|
598
|
+
get_node_essentials('n8n-nodes-base.slack', {includeExamples: true})
|
|
599
|
+
get_node_essentials('n8n-nodes-base.webhook', {includeExamples: true})
|
|
531
600
|
|
|
532
|
-
|
|
533
|
-
|
|
601
|
+
// STEP 3: Validation (parallel execution)
|
|
602
|
+
[Silent execution]
|
|
603
|
+
validate_node_minimal('n8n-nodes-base.slack', config)
|
|
534
604
|
validate_node_operation('n8n-nodes-base.slack', fullConfig, 'runtime')
|
|
535
605
|
|
|
536
|
-
|
|
537
|
-
//
|
|
606
|
+
// STEP 4: Build
|
|
607
|
+
// Construct workflow with validated configs
|
|
608
|
+
// ⚠️ Set ALL parameters explicitly
|
|
538
609
|
|
|
539
|
-
|
|
610
|
+
// STEP 5: Validate
|
|
611
|
+
[Silent execution]
|
|
540
612
|
validate_workflow(workflowJson)
|
|
541
|
-
validate_workflow_connections(workflowJson)
|
|
542
|
-
validate_workflow_expressions(workflowJson)
|
|
543
613
|
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
614
|
+
// Response after all tools complete:
|
|
615
|
+
"Created workflow: Webhook → Slack
|
|
616
|
+
Validation: ✅ Passed"
|
|
617
|
+
```
|
|
618
|
+
|
|
619
|
+
### Batch Updates
|
|
547
620
|
|
|
548
|
-
|
|
621
|
+
```javascript
|
|
622
|
+
// ONE call with multiple operations
|
|
549
623
|
n8n_update_partial_workflow({
|
|
550
|
-
|
|
624
|
+
id: "wf-123",
|
|
551
625
|
operations: [
|
|
552
|
-
{type:
|
|
626
|
+
{type: "updateNode", nodeId: "slack-1", changes: {position: [100, 200]}},
|
|
627
|
+
{type: "updateNode", nodeId: "http-1", changes: {position: [300, 200]}},
|
|
628
|
+
{type: "cleanStaleConnections"}
|
|
553
629
|
]
|
|
554
630
|
})
|
|
631
|
+
```
|
|
555
632
|
|
|
556
633
|
## Important Rules
|
|
557
634
|
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
-
|
|
562
|
-
-
|
|
563
|
-
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
- **
|
|
571
|
-
- **
|
|
572
|
-
- **
|
|
635
|
+
### Core Behavior
|
|
636
|
+
1. **Silent execution** - No commentary between tools
|
|
637
|
+
2. **Parallel by default** - Execute independent operations simultaneously
|
|
638
|
+
3. **Templates first** - Always check before building (2,500+ available)
|
|
639
|
+
4. **Multi-level validation** - Quick check → Full validation → Workflow validation
|
|
640
|
+
5. **Never trust defaults** - Explicitly configure ALL parameters
|
|
641
|
+
|
|
642
|
+
### Attribution & Credits
|
|
643
|
+
- **MANDATORY TEMPLATE ATTRIBUTION**: Share author name, username, and n8n.io link
|
|
644
|
+
- **Template validation** - Always validate before deployment (may need updates)
|
|
645
|
+
|
|
646
|
+
### Performance
|
|
647
|
+
- **Batch operations** - Use diff operations with multiple changes in one call
|
|
648
|
+
- **Parallel execution** - Search, validate, and configure simultaneously
|
|
649
|
+
- **Template metadata** - Use smart filtering for faster discovery
|
|
650
|
+
|
|
651
|
+
### Code Node Usage
|
|
652
|
+
- **Avoid when possible** - Prefer standard nodes
|
|
653
|
+
- **Only when necessary** - Use code node as last resort
|
|
654
|
+
- **AI tool capability** - ANY node can be an AI tool (not just marked ones)
|
|
573
655
|
```
|
|
574
656
|
|
|
575
657
|
Save these instructions in your Claude Project for optimal n8n workflow assistance with intelligent template discovery.
|
|
@@ -588,11 +670,11 @@ This tool was created to benefit everyone in the n8n community without friction.
|
|
|
588
670
|
## Features
|
|
589
671
|
|
|
590
672
|
- **🔍 Smart Node Search**: Find nodes by name, category, or functionality
|
|
591
|
-
- **📖 Essential Properties**: Get only the 10-20 properties that matter
|
|
592
|
-
-
|
|
673
|
+
- **📖 Essential Properties**: Get only the 10-20 properties that matter
|
|
674
|
+
- **💡 Real-World Examples**: 2,646 pre-extracted configurations from popular templates
|
|
593
675
|
- **✅ Config Validation**: Validate node configurations before deployment
|
|
594
676
|
- **🔗 Dependency Analysis**: Understand property relationships and conditions
|
|
595
|
-
-
|
|
677
|
+
- **🎯 Template Discovery**: 2,500+ workflow templates with smart filtering
|
|
596
678
|
- **⚡ Fast Response**: Average query time ~12ms with optimized SQLite
|
|
597
679
|
- **🌐 Universal Compatibility**: Works with any Node.js version
|
|
598
680
|
|
|
@@ -618,8 +700,8 @@ Once connected, Claude can use these powerful tools:
|
|
|
618
700
|
- **`tools_documentation`** - Get documentation for any MCP tool (START HERE!)
|
|
619
701
|
- **`list_nodes`** - List all n8n nodes with filtering options
|
|
620
702
|
- **`get_node_info`** - Get comprehensive information about a specific node
|
|
621
|
-
- **`get_node_essentials`** - Get only essential properties
|
|
622
|
-
- **`search_nodes`** - Full-text search across all node documentation
|
|
703
|
+
- **`get_node_essentials`** - Get only essential properties (10-20 instead of 200+). Use `includeExamples: true` to get top 3 real-world configurations from popular templates
|
|
704
|
+
- **`search_nodes`** - Full-text search across all node documentation. Use `includeExamples: true` to get top 2 real-world configurations per node from templates
|
|
623
705
|
- **`search_node_properties`** - Find specific properties within nodes
|
|
624
706
|
- **`list_ai_tools`** - List all AI-capable nodes (ANY node can be used as AI tool!)
|
|
625
707
|
- **`get_node_as_tool_info`** - Get guidance on using any node as an AI tool
|
|
@@ -633,8 +715,6 @@ Once connected, Claude can use these powerful tools:
|
|
|
633
715
|
- **`get_templates_for_task`** - Curated templates for common automation tasks
|
|
634
716
|
|
|
635
717
|
### Advanced Tools
|
|
636
|
-
- **`get_node_for_task`** - Pre-configured node settings for common tasks
|
|
637
|
-
- **`list_tasks`** - Discover available task templates
|
|
638
718
|
- **`validate_node_operation`** - Validate node configurations (operation-aware, profiles support)
|
|
639
719
|
- **`validate_node_minimal`** - Quick validation for just required fields
|
|
640
720
|
- **`validate_workflow`** - Complete workflow validation including AI tool connections
|
|
@@ -674,14 +754,17 @@ These powerful tools allow you to manage n8n workflows directly from Claude. The
|
|
|
674
754
|
### Example Usage
|
|
675
755
|
|
|
676
756
|
```typescript
|
|
677
|
-
// Get essentials
|
|
678
|
-
get_node_essentials(
|
|
679
|
-
|
|
680
|
-
//
|
|
681
|
-
|
|
757
|
+
// Get essentials with real-world examples from templates
|
|
758
|
+
get_node_essentials({
|
|
759
|
+
nodeType: "nodes-base.httpRequest",
|
|
760
|
+
includeExamples: true // Returns top 3 configs from popular templates
|
|
761
|
+
})
|
|
682
762
|
|
|
683
|
-
//
|
|
684
|
-
|
|
763
|
+
// Search nodes with configuration examples
|
|
764
|
+
search_nodes({
|
|
765
|
+
query: "send email gmail",
|
|
766
|
+
includeExamples: true // Returns top 2 configs per node
|
|
767
|
+
})
|
|
685
768
|
|
|
686
769
|
// Validate before deployment
|
|
687
770
|
validate_node_operation({
|
|
@@ -772,12 +855,14 @@ npm run dev:http # HTTP dev mode
|
|
|
772
855
|
|
|
773
856
|
## 📊 Metrics & Coverage
|
|
774
857
|
|
|
775
|
-
Current database coverage (n8n v1.
|
|
858
|
+
Current database coverage (n8n v1.113.3):
|
|
776
859
|
|
|
777
|
-
- ✅ **
|
|
860
|
+
- ✅ **536/536** nodes loaded (100%)
|
|
778
861
|
- ✅ **528** nodes with properties (98.7%)
|
|
779
862
|
- ✅ **470** nodes with documentation (88%)
|
|
780
863
|
- ✅ **267** AI-capable tools detected
|
|
864
|
+
- ✅ **2,646** pre-extracted template configurations
|
|
865
|
+
- ✅ **2,500+** workflow templates available
|
|
781
866
|
- ✅ **AI Agent & LangChain nodes** fully documented
|
|
782
867
|
- ⚡ **Average response time**: ~12ms
|
|
783
868
|
- 💾 **Database size**: ~15MB (optimized)
|
package/data/nodes.db
CHANGED
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"handlers-n8n-manager.d.ts","sourceRoot":"","sources":["../../src/mcp/handlers-n8n-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE1D,OAAO,EAML,eAAe,EAGhB,MAAM,kBAAkB,CAAC;AAiB1B,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,eAAe,EAA2B,MAAM,2BAA2B,CAAC;AAuDrF,wBAAgB,0BAA0B,IAAI,MAAM,CAEnD;AAMD,wBAAgB,uBAAuB,gDAEtC;AAKD,wBAAgB,kBAAkB,IAAI,IAAI,CAIzC;AAED,wBAAgB,eAAe,CAAC,OAAO,CAAC,EAAE,eAAe,GAAG,YAAY,GAAG,IAAI,CAgF9E;AAgGD,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,
|
|
1
|
+
{"version":3,"file":"handlers-n8n-manager.d.ts","sourceRoot":"","sources":["../../src/mcp/handlers-n8n-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE1D,OAAO,EAML,eAAe,EAGhB,MAAM,kBAAkB,CAAC;AAiB1B,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,eAAe,EAA2B,MAAM,2BAA2B,CAAC;AAuDrF,wBAAgB,0BAA0B,IAAI,MAAM,CAEnD;AAMD,wBAAgB,uBAAuB,gDAEtC;AAKD,wBAAgB,kBAAkB,IAAI,IAAI,CAIzC;AAED,wBAAgB,eAAe,CAAC,OAAO,CAAC,EAAE,eAAe,GAAG,YAAY,GAAG,IAAI,CAgF9E;AAgGD,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CA8E7G;AAED,wBAAsB,iBAAiB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAiC1G;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAoDjH;AAED,wBAAsB,0BAA0B,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAmDnH;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAyCjH;AAED,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CA6D7G;AAED,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAiC7G;AAED,wBAAsB,mBAAmB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CA4D5G;AAED,wBAAsB,sBAAsB,CAC1C,IAAI,EAAE,OAAO,EACb,UAAU,EAAE,cAAc,EAC1B,OAAO,CAAC,EAAE,eAAe,GACxB,OAAO,CAAC,eAAe,CAAC,CAwF1B;AAED,wBAAsB,qBAAqB,CACzC,IAAI,EAAE,OAAO,EACb,UAAU,EAAE,cAAc,EAC1B,OAAO,CAAC,EAAE,eAAe,GACxB,OAAO,CAAC,eAAe,CAAC,CAkK1B;AAID,wBAAsB,4BAA4B,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAsErH;AAED,wBAAsB,kBAAkB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CA4F3G;AAED,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAgD7G;AAED,wBAAsB,qBAAqB,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAiC9G;AAID,wBAAsB,iBAAiB,CAAC,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAyC3F;AAED,wBAAsB,wBAAwB,CAAC,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAwDlG;AAGD,wBAAsB,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,eAAe,CAAC,CAsGxG"}
|
|
@@ -31,7 +31,6 @@ const zod_1 = require("zod");
|
|
|
31
31
|
const workflow_validator_1 = require("../services/workflow-validator");
|
|
32
32
|
const enhanced_config_validator_1 = require("../services/enhanced-config-validator");
|
|
33
33
|
const instance_context_1 = require("../types/instance-context");
|
|
34
|
-
const node_type_normalizer_1 = require("../utils/node-type-normalizer");
|
|
35
34
|
const workflow_auto_fixer_1 = require("../services/workflow-auto-fixer");
|
|
36
35
|
const expression_format_validator_1 = require("../services/expression-format-validator");
|
|
37
36
|
const handlers_workflow_diff_1 = require("./handlers-workflow-diff");
|
|
@@ -196,17 +195,37 @@ async function handleCreateWorkflow(args, context) {
|
|
|
196
195
|
try {
|
|
197
196
|
const client = ensureApiConfigured(context);
|
|
198
197
|
const input = createWorkflowSchema.parse(args);
|
|
199
|
-
const
|
|
200
|
-
|
|
198
|
+
const shortFormErrors = [];
|
|
199
|
+
input.nodes?.forEach((node, index) => {
|
|
200
|
+
if (node.type?.startsWith('nodes-base.') || node.type?.startsWith('nodes-langchain.')) {
|
|
201
|
+
const fullForm = node.type.startsWith('nodes-base.')
|
|
202
|
+
? node.type.replace('nodes-base.', 'n8n-nodes-base.')
|
|
203
|
+
: node.type.replace('nodes-langchain.', '@n8n/n8n-nodes-langchain.');
|
|
204
|
+
shortFormErrors.push(`Node ${index} ("${node.name}") uses SHORT form "${node.type}". ` +
|
|
205
|
+
`The n8n API requires FULL form. Change to "${fullForm}"`);
|
|
206
|
+
}
|
|
207
|
+
});
|
|
208
|
+
if (shortFormErrors.length > 0) {
|
|
209
|
+
telemetry_1.telemetry.trackWorkflowCreation(input, false);
|
|
210
|
+
return {
|
|
211
|
+
success: false,
|
|
212
|
+
error: 'Node type format error: n8n API requires FULL form node types',
|
|
213
|
+
details: {
|
|
214
|
+
errors: shortFormErrors,
|
|
215
|
+
hint: 'Use n8n-nodes-base.* instead of nodes-base.* for standard nodes'
|
|
216
|
+
}
|
|
217
|
+
};
|
|
218
|
+
}
|
|
219
|
+
const errors = (0, n8n_validation_1.validateWorkflowStructure)(input);
|
|
201
220
|
if (errors.length > 0) {
|
|
202
|
-
telemetry_1.telemetry.trackWorkflowCreation(
|
|
221
|
+
telemetry_1.telemetry.trackWorkflowCreation(input, false);
|
|
203
222
|
return {
|
|
204
223
|
success: false,
|
|
205
224
|
error: 'Workflow validation failed',
|
|
206
225
|
details: { errors }
|
|
207
226
|
};
|
|
208
227
|
}
|
|
209
|
-
const workflow = await client.createWorkflow(
|
|
228
|
+
const workflow = await client.createWorkflow(input);
|
|
210
229
|
telemetry_1.telemetry.trackWorkflowCreation(workflow, true);
|
|
211
230
|
return {
|
|
212
231
|
success: true,
|
|
@@ -413,8 +432,7 @@ async function handleUpdateWorkflow(args, context) {
|
|
|
413
432
|
...updateData
|
|
414
433
|
};
|
|
415
434
|
}
|
|
416
|
-
const
|
|
417
|
-
const errors = (0, n8n_validation_1.validateWorkflowStructure)(normalizedWorkflow);
|
|
435
|
+
const errors = (0, n8n_validation_1.validateWorkflowStructure)(fullWorkflow);
|
|
418
436
|
if (errors.length > 0) {
|
|
419
437
|
return {
|
|
420
438
|
success: false,
|
|
@@ -422,9 +440,6 @@ async function handleUpdateWorkflow(args, context) {
|
|
|
422
440
|
details: { errors }
|
|
423
441
|
};
|
|
424
442
|
}
|
|
425
|
-
if (updateData.nodes) {
|
|
426
|
-
updateData.nodes = normalizedWorkflow.nodes;
|
|
427
|
-
}
|
|
428
443
|
}
|
|
429
444
|
const workflow = await client.updateWorkflow(id, updateData);
|
|
430
445
|
return {
|