MCP
The MCP Drupal module implements the Model Context Protocol (MCP), enabling your Drupal site to act as an MCP server.
This module is planned to integrate deeply with the existing AI ecosystem, enabling AI agents to implement MCP plugins and seamlessly interact with the MCP server, fostering a unified, flexible and extensible context-aware AI experience from your Drupal website.
Dependencies
- PHP ^8.3
- Drupal ^10 || ^11
- For development:
- Bun ^0.1.0
Installation and Configuration
- Install the module using Composer:
composer require drupal/mcp
- Enable the module:
drush en mcp
- Configure the
mcp-server-drupal
- Download the MCP Server Drupal binary.
- Place the binary in somewhere in your local machine and make it executable:
chmod +x mcp-server-drupal
- Configure the mcp client, for example modify the Claude desktop client configuration file and add the Drupal server:
{ "mcpServers": { "mcp-server-drupal": { "command": "__BINARY_PATH__", "args": ["--drupalBaseUrl", "__DRUPAL_BASE_URL__"], "env": {} } } }
Important Notes
- ⚠️ Currently the module not yet have authentication and authorization mechanisms. ⚠️
- This module is under active development and is not yet ready for production use.
- Use at your own risk.
- Everything is subject to change.