The Vendure MCP Server enables programmatic interaction with your local Vendure project's CLI and configuration. It operates directly within your project context for intelligent tooling.
Key capabilities:
Project Modification: Add plugins, entities, services, API extensions (GraphQL), job queues, and Admin UI extensions to your project
Database Management: Generate, run, or revert database migrations
Project Analysis: Analyze project structure and list plugins, entities, and services
CLI Integration: Access and execute Vendure CLI commands programmatically
Dual Connectivity: Connect via STDIO (recommended for local clients) or HTTP (for networked clients)
Environment Verification: Check Vendure installation status and dependencies
Dynamic CLI Tooling: Automatically reflects CLI changes with type safety and correctness
The server provides context-aware operation, ensuring access to the correct dependencies and project context.
Enables cloning and working with the source code repository for development purposes.
Supports accessing and contributing to the MCP server's codebase through GitHub repository integration.
Allows installation and execution of the MCP server through npm, supporting both global and local installation patterns.
Provides full TypeScript integration with proper parameter validation, ensuring type safety for all MCP tools.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Vendure MCP Serveradd a new payment plugin to the project"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Features
Project Integration: Operates directly within your Vendure project, providing context-aware tooling.
CLI Integration: Direct access to Vendure CLI
addandmigratecommands.Project Analysis: Analyze project structure, list plugins, entities, and services.
Dual Transport Support: Connect via standard I/O (STDIO) for local clients like Cursor or via HTTP for networked clients.
Environment Check: Verify Vendure installation and dependencies within the project.
Access to Docs: The MCP can fetch the official Vendure docs to use as context whenever it needs to.
Real-time: Works with any local Vendure project without modification.
Related MCP server: Lodestar MCP Server
Dynamic CLI Integration
The server dynamically generates MCP tools from your project's installed Vendure CLI command definitions. This ensures:
Single Source of Truth: CLI changes automatically reflect in MCP tools.
Future-proof: New CLI commands and options become available automatically.
No Hallucinations: The code generated by the tools will always be correct, as it's based on the actual CLI definitions in your project.
Installation and Setup Workflow
To use the CLI command orchestration capabilities of the MCP. The target project should be running a version of the@vendure/cli package that is > 3.4.0 or later. Currently, this would be in our minor branch.
To change the version of your package, open the package.json of your project and change the "@vendure/cli" version to "minor", then delete your package-lock.json file and node_modules folder and run npm install.
The server is designed to be installed and run directly from your Vendure project. This ensures it always has access to the correct dependencies and project context.
Configure Your MCP Client (e.g., Cursor)
Create or update the mcp.json file used by your MCP client. This file is typically located at .cursor/mcp.json inside your project's root folder.
Below are configurations for both STDIO and HTTP connections.
You must restart your MCP client, e.g., Cursor IDE or Claude Code, to apply the changes.
Option 1: STDIO Connection (Recommended for Local Clients)
This is the simplest and most direct way to connect.
You must replace/path/to/your/vendure-project with the absolute path to your Vendure project's root directory. The same path as your vendure-config.ts.
Option 2: HTTP Connection
If your client does not support STDIO or you need to connect over a network, you can run the server in HTTP mode.
First, start the server from your terminal in your Vendure project's root directory:
This will start the server on the default port (8000), you can explicitly define the port by using the --port <0000> flag.
Then, configure your mcp.json to connect to the running server's URL:
Option 3: Docker
This will start a Docker container and the server will run through in stdio mode. Refer to the Docker Guide for more information about running with Docker.
You must replace/path/to/your/vendure-project with the absolute path to your Vendure project's root directory. The same path as your vendure-config.ts.
Development
If you are contributing to the Vendure MCP server itself, you'll want to run it from the source code.
Build from Source
Development Mode
To connect an MCP client to your local development server, use the npm run dev script and point it to a test Vendure project. You can run it in either STDIO or HTTP mode.
STDIO Mode:
npm run dev -- --projectPath /path/to/your/test-vendure-projectHTTP Mode:
npm run dev:http -- --projectPath /path/to/your/test-vendure-project
Configure your mcp.json as described in the setup section to connect to your development server. The -- is required to pass arguments to the npm script correctly.
Trouble-shooting and issue reporting
If you run into problems while using/running the MCP, we would appreciate any issue with information that would help us reproduce your issue.
you can provide us withMCP Logs created by your MCP-Client.
In Cursor, you could find them by looking for Developer: Open Log File... > MCP Logs in your command palette (Shift+Cmd/Ctrl/Super+P) by default.