Directus MCP Server
A Node.js server implementing Model Context Protocol (MCP) for Directus CMS. Enable AI Clients to interact with the Directus API through the Model Context Protocol (MCP).
ℹ Prerequisites
▶️ Quick start
- Get your Directus API credentials
- Go to your Directus instance
- Create a static access token or get your email and password
- Keep these credentials secure
- Add to your AI editorAlternatively, you can use email/password authentication:CopyFor Cursor:Copy
- Go to Settings → Cursor Settings → MCP
- Click
+ Add New Global MCP Server
- Paste configuration
- Replace placeholder values with your Directus credentials
- Save and restart Cursor
For Claude Desktop:
- Open Settings → Developer
- Click
Edit Config
- Open
claude_desktop_config.json
in a code editor and paste configuration - Replace placeholder values with your Directus credentials
- Save and restart Claude
❓ Troubleshooting
If you are having issues starting the server in your MCP client e.g. Cursor or Claude Desktop, please try the following.
Ensure you have valid Directus credentials
- Verify that your Directus URL is correct and accessible
- Check that your access token or email/password credentials are valid
- Replace the credentials in your MCP client configuration
- Save and restart your MCP client
Ensure you have Node and NPM installed
Run the following commands to confirm you have Node and NPM installed:
Copy
Clear your NPM cache
Sometimes clearing your NPM cache can resolve issues with npx
.
Copy
🛠️ Available tools
Collections and Items
Copy
Files
Copy
Users and Permissions
Copy
System
Copy
🚧 Development mode
If you want to run the server in development mode:
- Clone and install:Copy
- Add your credentials to
.env
:Copy - Start development server:Copy
📄 Directus Developer resources
This server cannot be installed
A Node.js server that enables AI Clients to interact with the Directus CMS API through the Model Context Protocol, allowing for management of collections, items, files, users, and system information.