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
- Node.js
- NPM
- A Directus Instance
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 editor
{
"mcpServers": {
"directus": {
"command": "npx",
"args": ["-y", "@pixelsock/directus-mcp@latest"],
"env": {
"DIRECTUS_URL": "https://your-directus-instance.com",
"DIRECTUS_ACCESS_TOKEN": "YOUR_ACCESS_TOKEN"
}
}
}
}
Alternatively, you can use email/password authentication:
{
"mcpServers": {
"directus": {
"command": "npx",
"args": ["-y", "@pixelsock/directus-mcp@latest"],
"env": {
"DIRECTUS_URL": "https://your-directus-instance.com",
"DIRECTUS_EMAIL": "your-email@example.com",
"DIRECTUS_PASSWORD": "your-password"
}
}
}
}
For Cursor:
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 configurationReplace 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
- Node.js
- NPM
Run the following commands to confirm you have Node and NPM installed:
node -v
npm -v
Clear your NPM cache
Sometimes clearing your NPM cache can resolve issues with npx
.
npm cache clean --force
Available tools
Collections and Items
getItems // Get items from a collection
getItem // Get a single item from a collection by ID
createItem // Create a new item in a collection
updateItem // Update an existing item in a collection
deleteItem // Delete an item from a collection
getCollections // Get all collection schemas
getFields // Get fields for a collection
getRelations // Get relations for a collection
Files
getFiles // Get files from Directus
uploadFile // Upload a file to Directus
Users and Permissions
login // Login to Directus and get an access token
getUsers // Get users from Directus
getCurrentUser // Get the current user info
getRoles // Get roles from Directus
getPermissions // Get permissions from Directus
System
getSystemInfo // Get system information from Directus
getActivity // Get activity logs from Directus
getConfig // Get current configuration information
Development mode
If you want to run the server in development mode:
- Clone and install:
git clone https://github.com/pixelsock/directus-mcp.git
cd directus-mcp
npm install
- Add your credentials to
.env
:
# .env
DIRECTUS_URL=https://your-directus-instance.com
DIRECTUS_ACCESS_TOKEN=your_token_here
# Or use email/password
DIRECTUS_EMAIL=your-email@example.com
DIRECTUS_PASSWORD=your-password
- Start development server:
npm run dev
Directus Developer resources
- Directus API Documentation
- Directus API Endpoints
- Directus JavaScript SDK
Directus MCP Server
Project Details
- pixelsock/directus-mcp
- Last Updated: 4/14/2025
Categories
Recomended MCP Servers
Execute SQL queries and manage databases seamlessly with Timeplus. Leverage powerful tools to interact with your data, Kafka...
Dify 1.0 Plugin Convert your Dify tools's API to MCP compatible API
OmniMCP uses Microsoft OmniParser and Model Context Protocol (MCP) to provide AI models with rich UI context and...
A Model Context Protocol (MCP) implementation for Splunk Enterprise and Cloud integration with Cursor IDE or Claude
Nautobot plugin that enables AI assistants to interact with network data through the Model Context Protocol (MCP).
This tool is a cutting-edge memory engine that blends real-time learning, persistent three-tier context awareness, and seamless plug-n-play...
A simple and clear example for implementation and understanding Anthropic MCP (on AWS Bedrock).
Model Context Protocol server for KiCad on Mac, Windows, and Linux

Augment LLMs with Todoist features