### Manual Installation and Build for n8n Workflow Builder Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Steps for cloning the repository, installing dependencies, building the project, and starting the server locally. Requires Node.js and npm. ```bash git clone https://github.com/makafeli/n8n-workflow-builder.git cd n8n-workflow-builder npm install npm run build npm start ``` -------------------------------- ### Install and Use Node.js with NVM Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Install Node Version Manager (nvm) and use it to install and manage Node.js versions, recommended for avoiding permission issues. ```bash # Install nvm and use it to manage Node.js curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash nvm install 18 nvm use 18 ``` -------------------------------- ### Install n8n Workflow Builder Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/COMPARISON.md Install the n8n workflow builder CLI tool using npm. This is the first step to getting started with AI-powered automation. ```bash npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### Install and Run n8n-workflow-builder Locally Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/GETTING_STARTED.md Use npx to install and run the n8n-workflow-builder command-line tool for local development. Alternatively, install it globally using npm for system-wide access. ```bash # Install and run npx @makafeli/n8n-workflow-builder # Or install globally npm install -g @makafeli/n8n-workflow-builder n8n-workflow-builder ``` -------------------------------- ### Simplify Workflow Request Example Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md When facing workflow creation issues, try simplifying the request to isolate the problem. This example creates a basic webhook workflow. ```text "Create a simple webhook workflow with just a trigger and HTTP response" ``` -------------------------------- ### List, Get, and Execute Workflows Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Demonstrates basic operations for listing, retrieving details of, and executing workflows. ```javascript // List all workflows await callTool("list_workflows", {}); // Get detailed information about a workflow await callTool("get_workflow", { id: "workflow-123" }); // Execute a workflow manually await callTool("execute_workflow", { id: "workflow-123" }); ``` -------------------------------- ### Testing Published Package in Node.js Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/RELEASE_SETUP.md Demonstrates how to install and use the published package in a Node.js project. ```bash # Install globally npm install -g @makafeli/n8n-workflow-builder # Test the CLI n8n-workflow-builder --help # Or install locally in a project npm install @makafeli/n8n-workflow-builder # Use in Node.js const { N8nWorkflowBuilder } = require('@makafeli/n8n-workflow-builder'); ``` -------------------------------- ### Connection Issues Debug Log Example Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Example debug output indicating a connection refused error. This often points to the server not running or network accessibility issues. ```text DEBUG: Attempting connection to https://your-n8n.com DEBUG: Request headers: { 'X-N8N-API-KEY': 'n8n_api_...' } ERROR: ECONNREFUSED - Connection refused ``` -------------------------------- ### Manage Workflow Activation and Updates Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Provides examples for activating, deactivating, and updating existing workflows, as well as creating and activating a workflow in one step. ```javascript // Activate a workflow await callTool("activate_workflow", { id: "workflow-123" }); // Update a workflow await callTool("update_workflow", { id: "workflow-123", workflow: { name: "Updated Workflow Name" } }); // Deactivate a workflow await callTool("deactivate_workflow", { id: "workflow-123" }); // Create and immediately activate await callTool("create_workflow_and_activate", { workflow: { /* workflow configuration */ } }); ``` -------------------------------- ### Authentication Issues Debug Log Example Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Example debug output showing an unauthorized error. This typically means the API key is invalid, expired, or lacks the necessary permissions. ```text DEBUG: API request to /api/v1/workflows DEBUG: Response status: 401 ERROR: Unauthorized - Invalid API key ``` -------------------------------- ### Smithery Configuration Schema Example Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/SMITHERY_DEPLOYMENT.md Defines the configuration schema for the n8n-workflow-builder MCP server, specifying required parameters like n8nHost and n8nApiKey. ```yaml configSchema: type: "object" properties: n8nHost: type: "string" description: "n8n instance URL (e.g., http://localhost:5678)" default: "http://localhost:5678" n8nApiKey: type: "string" description: "n8n API key for authentication" required: ["n8nHost", "n8nApiKey"] ``` -------------------------------- ### Claude Desktop MCP Configuration Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/SMITHERY_DEPLOYMENT.md Example configuration for connecting to the n8n-workflow-builder MCP server from Claude Desktop, including environment variables for n8n connection details. ```json { "mcpServers": { "n8n-workflow-builder": { "command": "smithery", "args": ["run", "@makafeli/n8n-workflow-builder"], "env": { "N8N_HOST": "http://your-n8n-instance:5678", "N8N_API_KEY": "your-api-key" } } } } ``` -------------------------------- ### Check Node.js Version Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Ensure you have Node.js version 18.0.0 or higher installed for the MCP server. ```bash node --version # Must be 18.0.0 or higher ``` -------------------------------- ### Describe Zapier Workflow to AI Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/COMPARISON.md Use natural language to instruct the AI to recreate a Zapier workflow. This prompt example outlines a common lead management automation. ```text "Create an n8n workflow that replicates my Zapier automation: when a new lead comes from our website form, add them to our CRM, send a welcome email, and notify our sales team on Slack" ``` -------------------------------- ### Configure npm to Use a Different Directory Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Fix 'EACCES' permission errors during global npm installations by configuring npm to use a user-owned directory. ```bash # Configure npm to use different directory mkdir ~/.npm-global npm config set prefix '~/.npm-global' echo 'export PATH=~/.npm-global/bin:$PATH' >> ~/.bashrc source ~/.bashrc ``` -------------------------------- ### Reinstall n8n Workflow Builder Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Uninstall and then reinstall the n8n workflow builder package globally to fix installation problems. ```bash npm uninstall -g @makafeli/n8n-workflow-builder npm install -g @makafeli/n8n-workflow-builder ``` -------------------------------- ### Gather Environment and Debug Information Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Collect essential environment details and debug logs for effective bug reporting. This includes Node.js version, package installation status, and builder debug output. ```bash # Include output from these commands node --version npm list -g @makafeli/n8n-workflow-builder DEBUG=n8n-workflow-builder npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### Enable Debug Mode Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Enable debug mode for the n8n-workflow-builder to get detailed logs for troubleshooting. This is useful for diagnosing issues. ```bash DEBUG=n8n-workflow-builder ``` -------------------------------- ### Generate Security Audit Report Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Provides an example of generating a comprehensive security audit report with custom options for categories and abandoned workflow days. ```javascript // Generate comprehensive security audit await callTool("generate_audit", { additionalOptions: { daysAbandonedWorkflow: 30, categories: ["credentials", "database", "nodes"] } }); ``` -------------------------------- ### List Workflows Summary Tool Call and Response Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Call the `list_workflows` tool to get a summary of all workflows, including ID, name, status, tags, and node count. The response provides a concise overview. ```json // Tool call (no parameters required) { "tool": "list_workflows", "arguments": {} } // Expected response { "count": 3, "workflows": [ { "id": "wf-001", "name": "Daily Report Generator", "active": true, "tags": ["production", "reports"], "nodeCount": 7, "createdAt": "2024-01-10T08:00:00.000Z", "updatedAt": "2024-06-15T12:30:00.000Z" }, { "id": "wf-002", "name": "Slack Notification Handler", "active": false, "tags": ["staging"], "nodeCount": 3, "createdAt": "2024-03-01T10:00:00.000Z", "updatedAt": "2024-03-01T10:00:00.000Z" } ] } ``` -------------------------------- ### AI Assistant Diagnostic Commands Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md These commands can be used to diagnose the n8n MCP setup, test tools, check configuration, and verify API key permissions. ```text "Run a full diagnostic of my n8n MCP setup" ``` ```text "Test all my n8n workflow tools" ``` ```text "Show me my current n8n configuration" ``` ```text "Verify my API key permissions" ``` -------------------------------- ### Get Workflow by ID Tool Call and Response Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Call the `get_workflow` tool with a workflow ID to retrieve its details. By default, it returns a summary; set `full: true` for complete node and connection data. Use `download_workflow` to save the workflow JSON to disk. ```json { "tool": "get_workflow", "arguments": { "id": "wf-001", "full": true } } // Summary response (full: false, default) { "id": "wf-001", "name": "Daily Report Generator", "active": true, "tags": ["production"], "nodeCount": 7, "nodes": [ { "name": "Schedule Trigger", "type": "n8n-nodes-base.scheduleTrigger" }, { "name": "Fetch Data", "type": "n8n-nodes-base.httpRequest" }, { "name": "Send Email", "type": "n8n-nodes-base.emailSend" } ], "createdAt": "2024-01-10T08:00:00.000Z", "updatedAt": "2024-06-15T12:30:00.000Z" } ``` -------------------------------- ### Automate Employee Onboarding Processes Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Create an onboarding workflow to set up new employee accounts, send welcome emails, schedule orientation, and create manager task lists. ```bash Create an onboarding workflow that sets up new employee accounts in all our systems, sends welcome emails, schedules orientation meetings, and creates task lists for managers ``` -------------------------------- ### Clear npm Cache Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Force clear the npm cache to resolve potential installation issues. ```bash npm cache clean --force ``` -------------------------------- ### Create and Activate Workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Use this tool to create a new workflow and immediately activate it in a single atomic call. This is useful for deploying production-ready workflows in one step. ```json { "tool": "create_workflow_and_activate", "arguments": { "workflow": { "name": "Live Webhook Handler", "nodes": [ { "id": "webhook", "name": "Webhook", "type": "n8n-nodes-base.webhook", "typeVersion": 1, "position": [240, 300], "parameters": { "path": "order-events", "httpMethod": "POST" } }, { "id": "respond", "name": "Respond to Webhook", "type": "n8n-nodes-base.respondToWebhook", "typeVersion": 1, "position": [460, 300], "parameters": { "respondWith": "json", "responseBody": "{\"status\":\"ok\"}" } } ], "connections": { "Webhook": { "main": [[{ "node": "Respond to Webhook", "type": "main", "index": 0 }]] } } } } } ``` ```json { "success": true, "message": "Workflow created and activated", "workflowId": "wf-100", "name": "Live Webhook Handler", "active": true } ``` -------------------------------- ### Automate Infrastructure Monitoring and Scaling Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Set up a workflow to monitor server CPU and memory usage, and automatically trigger scaling actions when thresholds are exceeded. ```bash Set up a workflow that monitors server CPU and memory usage, and automatically triggers scaling actions when thresholds are exceeded ``` -------------------------------- ### Create a Simple Workflow Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Shows how to create a new workflow with a schedule trigger and an HTTP request node, including defining connections between nodes. ```javascript // Create a simple workflow await callTool("create_workflow", { workflow: { name: "My Automation Workflow", nodes: [ { id: "trigger", name: "Schedule Trigger", type: "n8n-nodes-base.scheduleTrigger", typeVersion: 1, position: [240, 300], parameters: { interval: [{ field: "unit", value: "hours" }] } }, { id: "action", name: "HTTP Request", type: "n8n-nodes-base.httpRequest", typeVersion: 4, position: [460, 300], parameters: { url: "https://api.example.com/webhook", method: "POST" } } ], connections: { "Schedule Trigger": { "main": [[{ "node": "HTTP Request", "type": "main", "index": 0 }]] } } } }); ``` -------------------------------- ### execute_workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Manually trigger a workflow. Starts an on-demand execution regardless of the workflow's normal trigger configuration. ```APIDOC ## execute_workflow — Manually trigger a workflow ### Description Manually trigger a workflow. Starts an on-demand execution regardless of the workflow's normal trigger configuration. ### Method POST (Assumed, based on execution operation) ### Endpoint /workflows/{id}/execute ### Parameters #### Path Parameters - **id** (string) - Required - The ID of the workflow to execute. ### Request Example ```json { "tool": "execute_workflow", "arguments": { "id": "wf-001" } } ``` ### Response #### Success Response (200) - **success** (boolean) - Indicates if the execution was triggered successfully. - **message** (string) - A confirmation message. - **executionId** (string) - The ID of the triggered execution. - **status** (string) - The initial status of the execution. #### Response Example ```json { "success": true, "message": "Workflow wf-001 executed", "executionId": "exec-4512", "status": "started" } ``` ``` -------------------------------- ### download_workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Fetches a workflow and writes it to a local file, avoiding large JSON output in chat. The directory './workflows/' is created automatically if absent. ```APIDOC ## download_workflow ### Description Fetches a workflow and writes it to a local file, avoiding large JSON output in chat. The directory `./workflows/` is created automatically if absent. ### Arguments - **id** (string) - Required - The ID of the workflow to download. - **filePath** (string) - Required - The local path where the workflow JSON should be saved. ### Request Example ```json { "tool": "download_workflow", "arguments": { "id": "wf-001", "filePath": "./backups/daily_report.json" } } ``` ### Response Example ```json { "success": true, "message": "Workflow saved to ./backups/daily_report.json", "workflowId": "wf-001", "workflowName": "Daily Report Generator", "filePath": "./backups/daily_report.json", "nodeCount": 7 } ``` ``` -------------------------------- ### Manual NPM Publishing Commands Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/RELEASE_SETUP.md Commands to manually build, verify, and publish the package to the npm registry. ```bash # 1. Ensure you're logged into npm npm login # 2. Build the package npm run build # 3. Verify package contents npm pack --dry-run # 4. Publish to npm npm publish ``` -------------------------------- ### Automate System Health Monitoring and Alerts Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Create a monitoring workflow to check API endpoints, track response times, and send Slack alerts for service outages or slowdowns. ```bash Create a monitoring workflow that checks our API endpoints every 5 minutes, monitors response times, and sends Slack alerts if any service is down or slow ``` -------------------------------- ### Automate Inventory Management Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Set up a workflow to monitor inventory levels and automatically create purchase orders when stock falls below a specified threshold. ```bash Set up a workflow that checks inventory levels daily and automatically creates purchase orders when stock is below threshold ``` -------------------------------- ### Configure Claude Desktop for n8n-workflow-builder Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/GETTING_STARTED.md Add this configuration to your 'claude_desktop_config.json' file to enable the n8n-workflow-builder MCP server. Ensure N8N_HOST and N8N_API_KEY are set to your n8n instance details. ```json { "mcpServers": { "n8n-workflow-builder": { "command": "npx", "args": ["@makafeli/n8n-workflow-builder"], "env": { "N8N_HOST": "https://your-n8n-instance.com", "N8N_API_KEY": "your-api-key-here" } } } } ``` -------------------------------- ### Retrieve Credential Schema Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Call this to get the schema for a specific n8n credential type before creating a credential. This ensures you supply the correct data fields. ```json { "tool": "get_credential_schema", "arguments": { "credentialType": "httpHeaderAuth" } } ``` ```json { "success": true, "credentialType": "httpHeaderAuth", "schema": { "properties": { "name": { "type": "string", "displayName": "Name" }, "value": { "type": "string", "displayName": "Value", "typeOptions": { "password": true } } } }, "message": "Schema for credential type 'httpHeaderAuth' retrieved successfully" } ``` -------------------------------- ### Automate Payment Processing and Notifications Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Set up a workflow to process payment webhooks, update customer subscription status, and send receipt emails with invoice attachments. ```bash Set up a workflow that processes payment webhooks, updates customer subscription status, and sends receipt emails with invoice attachments ``` -------------------------------- ### Get Tags Assigned to an n8n Workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Retrieves all tags currently assigned to a specific workflow, identified by its `workflowId`. Useful for understanding a workflow's categorization. ```json { "tool": "get_workflow_tags", "arguments": { "workflowId": "wf-001" } } ``` -------------------------------- ### create_workflow_and_activate Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Combines workflow creation and activation in a single atomic tool call. Useful for deploying production-ready workflows in one step. ```APIDOC ## create_workflow_and_activate — Create and immediately activate a workflow ### Description Combines workflow creation and activation in a single atomic tool call. Useful for deploying production-ready workflows in one step. ### Method POST (Assumed, based on creation and activation operation) ### Endpoint /workflows/activate ### Request Body - **workflow** (object) - Required - The workflow object containing name, nodes, and connections. - **name** (string) - Required - The name of the workflow. - **nodes** (array) - Required - An array of node objects defining the workflow structure. - **connections** (object) - Optional - Defines the connections between nodes. ### Request Example ```json { "tool": "create_workflow_and_activate", "arguments": { "workflow": { "name": "Live Webhook Handler", "nodes": [ { "id": "webhook", "name": "Webhook", "type": "n8n-nodes-base.webhook", "typeVersion": 1, "position": [240, 300], "parameters": { "path": "order-events", "httpMethod": "POST" } }, { "id": "respond", "name": "Respond to Webhook", "type": "n8n-nodes-base.respondToWebhook", "typeVersion": 1, "position": [460, 300], "parameters": { "respondWith": "json", "responseBody": "{\"status\":\"ok\"}" } } ], "connections": { "Webhook": { "main": [[{ "node": "Respond to Webhook", "type": "main", "index": 0 }]] } } } } } ``` ### Response #### Success Response (200) - **success** (boolean) - Indicates if the operation was successful. - **message** (string) - A confirmation message. - **workflowId** (string) - The ID of the created and activated workflow. - **name** (string) - The name of the workflow. - **active** (boolean) - Indicates if the workflow is active. #### Response Example ```json { "success": true, "message": "Workflow created and activated", "workflowId": "wf-100", "name": "Live Webhook Handler", "active": true } ``` ``` -------------------------------- ### Configure Environment Variables for Local Mode Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Set N8N_HOST and N8N_API_KEY environment variables for the server to connect to your n8n instance. Run the server directly or via npx after setting these. ```bash export N8N_HOST="http://localhost:5678" export N8N_API_KEY="n8n_api_xxxxxxxxxxxxxxxxxxxx" # Run directly (after build) node build/server.cjs # Or via npx npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### Programmatic Server Creation with Smithery Mode Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Instantiate the n8n Workflow Builder MCP Server programmatically using the createServer function. Configure it with your n8n instance details. ```typescript import createServer, { configSchema } from "@makafeli/n8n-workflow-builder"; const serverInstance = createServer({ config: { n8nHost: "https://my-n8n.example.com", n8nApiKey: "n8n_api_xxxxxxxxxxxxxxxxxxxx" } }); // serverInstance is a raw MCP Server ready to connect to any transport ``` -------------------------------- ### Get Specific n8n Execution Details Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Fetches detailed metadata for a single execution. Set `includeData` to `true` to retrieve full node-level run data. Useful for debugging specific execution failures. ```json { "tool": "get_execution", "arguments": { "id": "exec-4510", "includeData": true } } ``` -------------------------------- ### Create Workflow with Nodes and Connections Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Use this tool to create a new workflow with specified nodes, connections, settings, and tags. It returns the full n8n response including the workflow ID. ```json { "tool": "create_workflow", "arguments": { "workflow": { "name": "Hourly API Sync", "nodes": [ { "id": "trigger", "name": "Schedule Trigger", "type": "n8n-nodes-base.scheduleTrigger", "typeVersion": 1, "position": [240, 300], "parameters": { "rule": { "interval": [{ "field": "hours", "hoursInterval": 1 }] } } }, { "id": "fetch", "name": "Fetch Orders", "type": "n8n-nodes-base.httpRequest", "typeVersion": 4, "position": [460, 300], "parameters": { "url": "https://api.example.com/orders", "method": "GET", "authentication": "headerAuth" } } ], "connections": { "Schedule Trigger": { "main": [[{ "node": "Fetch Orders", "type": "main", "index": 0 }]] } }, "settings": { "saveManualExecutions": true }, "tags": ["sync", "production"] } } } ``` ```json { "id": "wf-099", "name": "Hourly API Sync", "active": false, "nodes": [...], "connections": {...}, "createdAt": "2024-07-01T09:00:00.000Z", "updatedAt": "2024-07-01T09:00:00.000Z" } ``` -------------------------------- ### Automate Multi-Platform Content Publishing Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Create a workflow to publish content from a CMS to multiple social media platforms with platform-specific formatting. ```bash Create a workflow that takes a blog post from our CMS and automatically publishes it to Twitter, LinkedIn, and Facebook with appropriate formatting for each platform ``` -------------------------------- ### Smithery Configuration File Structure Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/SMITHERY_DEPLOYMENT.md This illustrates the expected file structure for a Smithery-compatible MCP server project. ```tree ├── smithery.yaml # Smithery configuration ├── src/ │ ├── index.ts # Smithery-compatible entry point │ └── server.ts # Original CLI server (optional) ├── package.json # Node.js dependencies └── tsconfig.json # TypeScript configuration ``` -------------------------------- ### Automate ETL Pipeline Management Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Set up a workflow to extract data from a database, transform it according to business rules, and load it into a data warehouse nightly. ```bash Set up a workflow that extracts data from our database, transforms it according to our business rules, and loads it into our data warehouse every night ``` -------------------------------- ### Deployment Pipeline Workflow Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Automate code deployment and testing. This AI command creates a workflow that triggers on code push, runs tests, deploys to staging, and promotes to production after approval. ```text "Create a deployment workflow that triggers when code is pushed to main branch, runs tests, deploys to staging, and promotes to production after approval" ``` -------------------------------- ### Automate Data Synchronization Across Platforms Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Create a workflow to synchronize customer information between CRM, email marketing, and support systems whenever a customer profile is updated. ```bash Create a workflow that syncs customer information between our CRM, email marketing platform, and support system whenever a customer profile is updated ``` -------------------------------- ### Automate Lead Management and Enrichment Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Build a workflow to capture leads from various sources, enrich the data, and add them to a CRM with lead scoring. ```bash Build a workflow that captures leads from our website forms, LinkedIn ads, and trade shows, then enriches the data and adds them to our CRM with proper lead scoring ``` -------------------------------- ### upload_workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Reads a workflow JSON file, strips the `id` so n8n assigns a new one, creates the workflow, and optionally activates it immediately. ```APIDOC ## upload_workflow ### Description Reads a workflow JSON file, strips the `id` so n8n assigns a new one, creates the workflow, and optionally activates it immediately. ### Arguments - **filePath** (string) - Required - The path to the local JSON file containing the workflow. - **activate** (boolean) - Optional - Whether to activate the workflow immediately after creation. ### Request Example ```json { "tool": "upload_workflow", "arguments": { "filePath": "./backups/daily_report.json", "activate": true } } ``` ### Response Example ```json { "success": true, "message": "Workflow uploaded and activated", "workflowId": "wf-103", "workflowName": "Daily Report Generator", "active": true, "filePath": "./backups/daily_report.json" } ``` ``` -------------------------------- ### Smithery API Request to List Workflows Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/SMITHERY_DEPLOYMENT.md Demonstrates how to call the `list_workflows` tool of the n8n-workflow-builder MCP server via the Smithery API, including authorization and configuration payload. ```bash curl -X POST https://api.smithery.ai/v1/servers/@makafeli/n8n-workflow-builder/tools/list_workflows \ -H "Authorization: Bearer YOUR_SMITHERY_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "config": { "n8nHost": "http://your-n8n-instance:5678", "n8nApiKey": "your-api-key" } }' ``` -------------------------------- ### Set n8n Connection Environment Variables Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Configure the N8N_HOST and N8N_API_KEY environment variables for local testing. These are required for the server to connect to your n8n instance. ```bash # For local testing export N8N_HOST="http://localhost:5678" export N8N_API_KEY="your-api-key-here" # Then run the server npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### Enable n8n-workflow-builder Debug Mode Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Run the n8n-workflow-builder with the DEBUG environment variable set to 'n8n-workflow-builder' for detailed logging specific to this package. ```bash DEBUG=n8n-workflow-builder npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### Automate Daily Sales Reporting Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Build a workflow to aggregate data from CRM, payment processors, and analytics platforms to generate and email daily sales reports. ```bash Build a workflow that pulls data from our CRM, payment processor, and analytics platform, then generates a daily sales report and emails it to the management team ``` -------------------------------- ### Event Management Workflow Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Automate event registration and follow-up. This AI command builds a workflow to manage registrations, send confirmations, handle waitlists, and conduct post-event follow-ups. ```text "Build an event workflow that handles registrations, sends confirmation emails, manages waitlists, and follows up with attendees post-event" ``` -------------------------------- ### List Workflows Full Data Tool Call Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Use the `list_workflows_full` tool to retrieve complete data for all workflows, including detailed node configurations and connection maps. This is token-intensive; prefer `list_workflows` for general discovery. ```json { "tool": "list_workflows_full", "arguments": {} } // Response includes full nodes[] and connections{} for every workflow ``` -------------------------------- ### Automate Security Monitoring and Account Locking Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Build a security workflow to monitor login attempts, detect suspicious patterns, automatically lock accounts, and notify the security team. ```bash Build a security workflow that monitors login attempts, detects unusual patterns, and automatically locks accounts while notifying the security team ``` -------------------------------- ### Backup Management Workflow Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Automate database backups and verification. This AI command builds a workflow for daily backups, integrity checks, and multi-location storage with retention policies. ```text "Build a backup workflow that creates daily database backups, verifies backup integrity, and stores them in multiple locations with retention policies" ``` -------------------------------- ### Download Workflow JSON to Disk Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Use this tool to save a workflow's JSON definition to a local file. The target directory is created if it doesn't exist. Avoids large JSON output in chat interfaces. ```json { "tool": "download_workflow", "arguments": { "id": "wf-001", "filePath": "./backups/daily_report.json" } } ``` ```json { "success": true, "message": "Workflow saved to ./backups/daily_report.json", "workflowId": "wf-001", "workflowName": "Daily Report Generator", "filePath": "./backups/daily_report.json", "nodeCount": 7 } ``` -------------------------------- ### Package JSON Configuration Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/RELEASE_SETUP.md Defines the package name, version, publish configuration, and files to include in the npm package. ```json { "name": "@makafeli/n8n-workflow-builder", "version": "0.10.1", "publishConfig": { "access": "public" }, "files": [ "build/**/*", "README.md", "LICENSE" ] } ``` -------------------------------- ### Upload Workflow JSON from File Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Create a new n8n workflow by reading a JSON file. The `id` is removed to allow n8n to assign a new one. The workflow can be activated immediately upon creation. ```json { "tool": "upload_workflow", "arguments": { "filePath": "./backups/daily_report.json", "activate": true } } ``` ```json { "success": true, "message": "Workflow uploaded and activated", "workflowId": "wf-103", "workflowName": "Daily Report Generator", "active": true, "filePath": "./backups/daily_report.json" } ``` -------------------------------- ### Enable Full Debug Output Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Set the DEBUG environment variable to '*' to capture all debug logs from all modules. This is useful for comprehensive troubleshooting. ```bash DEBUG=* npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### list_workflows_full Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Returns the full n8n API response including all node configurations and connection maps. This is a high token usage operation; prefer `list_workflows` for discovery. ```APIDOC ## list_workflows_full ### Description Returns the full n8n API response including all node configurations and connection maps. High token usage — prefer `list_workflows` for discovery. ### Method MCP Tool Call ### Parameters #### Arguments - **None**: No parameters are required for this tool. ### Request Example ```json { "tool": "list_workflows_full", "arguments": {} } ``` ### Response #### Success Response - **workflows** (array) - An array of workflow objects, each containing full node and connection data. ### Response Example ```json // Response includes full nodes[] and connections{} for every workflow ``` ``` -------------------------------- ### Manage Workflow Tags Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Shows how to list all available workflow tags with pagination and how to create a new tag for organizing workflows. ```javascript // List all workflow tags await callTool("list_tags", { limit: 50 }); // Create a new tag for organization await callTool("create_tag", { name: "production" }); ``` -------------------------------- ### Enable Axios Network Debugging Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md To debug network requests made by the builder, set the DEBUG environment variable to 'axios'. This will show detailed information about HTTP requests and responses. ```bash DEBUG=axios npx @makafeli/n8n-workflow-builder ``` -------------------------------- ### Configure n8n Workflow Builder for Claude Desktop Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Add this JSON configuration to your Claude Desktop settings to enable the n8n-workflow-builder MCP server. Ensure N8N_HOST and N8N_API_KEY are correctly set. ```json { "mcpServers": { "n8n-workflow-builder": { "command": "npx", "args": ["@makafeli/n8n-workflow-builder"], "env": { "N8N_HOST": "http://localhost:5678", "N8N_API_KEY": "your-api-key-here" } } } } ``` -------------------------------- ### Manage Workflow Executions Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/README.md Demonstrates how to list recent executions with filtering, retrieve detailed execution information including data, and delete execution records. ```javascript // List recent executions await callTool("list_executions", { limit: 10, status: "error" }); // Get detailed execution information await callTool("get_execution", { id: "execution-123", includeData: true }); // Clean up old execution records await callTool("delete_execution", { id: "execution-123" }); ``` -------------------------------- ### Customer Behavior Analysis Workflow Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Analyze customer behavior patterns and trigger actions. This AI command builds a workflow to track behavior, identify at-risk customers, and initiate retention campaigns. ```text "Build an analysis workflow that tracks customer behavior, identifies at-risk customers, and automatically triggers retention campaigns" ``` -------------------------------- ### Automate Customer Support Ticket Routing Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Create a workflow to analyze incoming support tickets, categorize them by urgency, and assign them to the appropriate team member. ```bash Create a workflow that analyzes incoming support tickets, categorizes them by urgency, and assigns them to the appropriate team member ``` -------------------------------- ### Check Workflow Configuration Command Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Use this command to retrieve the configuration of a specific n8n workflow. Replace '[workflow-name]' with the actual workflow name. ```text "Show me the configuration of my [workflow-name] workflow" ``` -------------------------------- ### AI Assistant Prompt for Workflow Creation Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/GETTING_STARTED.md Provide this detailed prompt to your AI assistant to create a specific n8n workflow. The workflow includes a time-based trigger, an HTTP request, and a notification for site downtime. ```text "Create a simple n8n workflow that: 1. Triggers every hour 2. Makes an HTTP request to check a website 3. Sends a notification if the site is down" ``` -------------------------------- ### Automate E-commerce Order Processing Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/USE_CASES.md Use this command to create an n8n workflow that handles new orders, updates inventory, sends customer confirmations, and generates shipping labels. ```bash Create an n8n workflow that triggers when a new order comes in, updates inventory in our database, sends a confirmation email to the customer, and creates a shipping label ``` -------------------------------- ### list_workflows Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Returns a token-efficient summary of every workflow, including ID, name, active status, tags, node count, and timestamps. Use `list_workflows_full` when full node/connection data is needed. ```APIDOC ## list_workflows ### Description Returns a token-efficient summary of every workflow: id, name, active status, tags, node count, and timestamps. Use `list_workflows_full` when full node/connection data is needed. ### Method MCP Tool Call ### Parameters #### Arguments - **None**: No parameters are required for this tool. ### Request Example ```json { "tool": "list_workflows", "arguments": {} } ``` ### Response #### Success Response - **count** (integer) - The total number of workflows. - **workflows** (array) - An array of workflow summary objects. - **id** (string) - The unique identifier for the workflow. - **name** (string) - The name of the workflow. - **active** (boolean) - Indicates if the workflow is currently active. - **tags** (array of strings) - Tags associated with the workflow. - **nodeCount** (integer) - The number of nodes in the workflow. - **createdAt** (string) - The timestamp when the workflow was created (ISO 8601 format). - **updatedAt** (string) - The timestamp when the workflow was last updated (ISO 8601 format). ### Response Example ```json { "count": 3, "workflows": [ { "id": "wf-001", "name": "Daily Report Generator", "active": true, "tags": ["production", "reports"], "nodeCount": 7, "createdAt": "2024-01-10T08:00:00.000Z", "updatedAt": "2024-06-15T12:30:00.000Z" }, { "id": "wf-002", "name": "Slack Notification Handler", "active": false, "tags": ["staging"], "nodeCount": 3, "createdAt": "2024-03-01T10:00:00.000Z", "updatedAt": "2024-03-01T10:00:00.000Z" } ] } ``` ``` -------------------------------- ### get_workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Retrieves a specific workflow by its ID. By default, it returns a summary; passing `full: true` includes the complete node and connection graph. Use `download_workflow` to save the workflow JSON to disk. ```APIDOC ## get_workflow ### Description Returns a workflow summary by default; pass `full: true` to receive the complete node and connection graph. Use `download_workflow` to persist the JSON to disk without printing it to chat. ### Method MCP Tool Call ### Parameters #### Arguments - **id** (string) - Required - The unique identifier of the workflow to retrieve. - **full** (boolean) - Optional - If true, returns the complete workflow data including nodes and connections. Defaults to false. ### Request Example ```json { "tool": "get_workflow", "arguments": { "id": "wf-001", "full": true } } ``` ### Response #### Success Response (Default - `full: false`) - **id** (string) - The unique identifier for the workflow. - **name** (string) - The name of the workflow. - **active** (boolean) - Indicates if the workflow is currently active. - **tags** (array of strings) - Tags associated with the workflow. - **nodeCount** (integer) - The number of nodes in the workflow. - **nodes** (array) - An array of node summary objects (when `full` is false). - **name** (string) - The name of the node. - **type** (string) - The type of the node. - **createdAt** (string) - The timestamp when the workflow was created (ISO 8601 format). - **updatedAt** (string) - The timestamp when the workflow was last updated (ISO 8601 format). #### Success Response (Full - `full: true`) - Includes all fields from the default response, plus: - **nodes** (array) - A detailed array of node objects. - **connections** (array) - An array detailing the connections between nodes. ### Response Example (Summary) ```json { "id": "wf-001", "name": "Daily Report Generator", "active": true, "tags": ["production"], "nodeCount": 7, "nodes": [ { "name": "Schedule Trigger", "type": "n8n-nodes-base.scheduleTrigger" }, { "name": "Fetch Data", "type": "n8n-nodes-base.httpRequest" }, { "name": "Send Email", "type": "n8n-nodes-base.emailSend" } ], "createdAt": "2024-01-10T08:00:00.000Z", "updatedAt": "2024-06-15T12:30:00.000Z" } ``` ``` -------------------------------- ### Run Diagnostic Commands for n8n Source: https://github.com/makafeli/n8n-workflow-builder/blob/main/TROUBLESHOOTING.md Use these commands with your AI assistant to quickly diagnose n8n connection and status issues. ```bash "Test my n8n connection" ``` ```bash "Show me the server status" ``` ```bash "List my workflows" (basic connectivity test) ``` ```bash "What's my n8n instance information?" ``` -------------------------------- ### create_workflow Source: https://context7.com/makafeli/n8n-workflow-builder/llms.txt Creates a new workflow with the provided nodes, connections, settings, and optional tags. Returns the full n8n response including the assigned workflow ID. ```APIDOC ## create_workflow — Create a new workflow ### Description Creates a workflow with the provided nodes, connections, settings, and optional tags. Returns the full n8n response including the assigned workflow ID. ### Method POST (Assumed, based on creation operation) ### Endpoint /workflows ### Request Body - **workflow** (object) - Required - The workflow object containing name, nodes, connections, settings, and tags. - **name** (string) - Required - The name of the workflow. - **nodes** (array) - Required - An array of node objects defining the workflow structure. - **connections** (object) - Optional - Defines the connections between nodes. - **settings** (object) - Optional - Workflow settings. - **tags** (array) - Optional - An array of tags for the workflow. ### Request Example ```json { "tool": "create_workflow", "arguments": { "workflow": { "name": "Hourly API Sync", "nodes": [ { "id": "trigger", "name": "Schedule Trigger", "type": "n8n-nodes-base.scheduleTrigger", "typeVersion": 1, "position": [240, 300], "parameters": { "rule": { "interval": [{ "field": "hours", "hoursInterval": 1 }] } } }, { "id": "fetch", "name": "Fetch Orders", "type": "n8n-nodes-base.httpRequest", "typeVersion": 4, "position": [460, 300], "parameters": { "url": "https://api.example.com/orders", "method": "GET", "authentication": "headerAuth" } } ], "connections": { "Schedule Trigger": { "main": [[{ "node": "Fetch Orders", "type": "main", "index": 0 }]] } }, "settings": { "saveManualExecutions": true }, "tags": ["sync", "production"] } } } ``` ### Response #### Success Response (200) - **id** (string) - The unique identifier of the created workflow. - **name** (string) - The name of the workflow. - **active** (boolean) - Indicates if the workflow is currently active. - **nodes** (array) - The nodes of the workflow. - **connections** (object) - The connections between nodes. - **createdAt** (string) - The timestamp when the workflow was created. - **updatedAt** (string) - The timestamp when the workflow was last updated. #### Response Example ```json { "id": "wf-099", "name": "Hourly API Sync", "active": false, "nodes": [...], "connections": {...}, "createdAt": "2024-07-01T09:00:00.000Z", "updatedAt": "2024-07-01T09:00:00.000Z" } ``` ```