n8n Workflow Builder MCP Server
n8n Workflow Builder MCP Server
This project provides an MCP server for managing n8n workflows. It offers functionality to list, create, update, delete, activate, and deactivate workflows through a set of defined tools.
Important:
This version exclusively supports npm for package management and running the server. (npx support will be reintroduced in a future update.)
Requirements
- Node.js (v14+ recommended)
- npm
Extensive Installation Guide
1. Clone the Repository
Clone the repository from your preferred source. For example:
Then, navigate to the project directory:
2. Install Dependencies
Install the necessary dependencies using npm:
This command will download and install all required packages as defined in the package.json
file.
3. Build and Test
For testing and getting the server online, use the following commands:
- Build the project:
This compiles the TypeScript files and produces the executable JavaScript in thebuild
directory.Copy - Start the MCP Server:
Launch the server using:Copy
The server will start and connect via stdio. You can check the console to see messages confirming that the server has started correctly.
4. Deployment
For testing purposes and to get the server online, use the build and start commands mentioned above. This basic workflow (install, build, start) is currently the recommended method.
5. Additional Configuration
Server configuration is managed via the cline_mcp_settings.json
file. Ensure that the following environment variables are correctly set:
N8N_HOST
: Your n8n API host URL.N8N_API_KEY
: Your n8n API key.
Example configuration in cline_mcp_settings.json
:
Available Tools
The following tools are defined in the server and can be accessed through your MCP client:
- list_workflows: Lists all workflows from n8n.
- create_workflow: Creates a new workflow in n8n.
- get_workflow: Retrieves a workflow by its ID.
- update_workflow: Updates an existing workflow.
- delete_workflow: Deletes a workflow by its ID.
- activate_workflow: Activates a workflow by its ID.
- deactivate_workflow: Deactivates a workflow by its ID.
Troubleshooting
- Ensure you are using npm (this version does not support npx).
- If you encounter any issues, try cleaning the build directory and rebuilding:Copy
- Verify that your environment variables in
cline_mcp_settings.json
are correct.
Future Enhancements
- Reintroduction of npx support.
- Additional tools and workflow features.
- Further enhancements to deployment and scaling.
License
This project is licensed under the MIT License.
You must be authenticated.
A server for programmatically creating and managing n8n workflows with a REST API interface, supporting workflow creation, validation, and export.