Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

MCP Client

Security covered Under active development 30 sites

Part of the MCP ecosystem · 11 projects

This module allows Drupal to connect to Model Context Protocol (MCP) servers, enabling AI modules to access external tools and data. It supports both HTTP and local process connections and integrates with other Drupal AI modules for seamless tool usage.

Built by a human using an AI assistant: ๐Ÿค– โž• ๐Ÿง 

Note that extensive parts of this module was generating via AI coding agents under human supervision.

INTRODUCTION

The MCP Client module enables Drupal to connect to Model Context Protocol (MCP) servers and expose their tools to AI modules. MCP is a standardized protocol for communication between AI applications and external tools/data sources.

This module integrates with the Drupal AI module or ECA to provide seamless access to MCP server capabilities, allowing AI agents to use external tools like file systems, databases, APIs, and more.

REQUIREMENTS

This module requires the following:

INSTALLATION

Install as you would normally install a contributed Drupal module. For further information, see: https://www.drupal.org/docs/extending-drupal/installing-drupal-modules

composer require drupal/mcp_client
drush en mcp_client -y

CONFIGURATION

HTTP Transport (Remote MCP Server)

Use this transport type for MCP servers accessible via HTTP/HTTPS.

  1. Navigate to Administration > Configuration > AI > MCP Servers (/admin/structure/mcp-server)
  2. Click "Add MCP Server"
  3. Fill in the following fields:
    • Label: A descriptive name (e.g., "GitHub MCP Server")
    • Transport Type: Select "HTTP (Streamable HTTP)"
    • Endpoint URL: Your MCP server URL (e.g., https://example.com/mcp)
    • Timeout: Connection timeout in seconds (default: 30)
  4. Click "Save"
  5. Edit the server configuration to enable specific tools
  6. Enabled tools are now available in the AI API Explorer

STDIO Transport (Local Process)

Use this transport type for running MCP servers as local processes (Node.js, Python, etc.).

  1. Navigate to Administration > Configuration > AI > MCP Servers
  2. Click "Add MCP Server"
  3. Fill in the following fields:
    • Label: A descriptive name
    • Transport Type: Select "STDIO (Process)"
    • Command: Full command to execute (e.g., node /path/to/server.js)
    • Working Directory: Optional working directory for the process
    • Environment Variables: Add environment variables as name-value pairs
      • For sensitive values (API keys, tokens), use Key module references
      • For non-sensitive values, use plain text
  4. Click "Save"
  5. Edit the server configuration to enable specific tools

Environment Variables with Key Module

For secure handling of API keys and other sensitive data:

  1. Install and enable the Key module (automatically required by this module)
  2. Create keys at Administration > Configuration > System > Keys
  3. When configuring environment variables in MCP Server settings:
    • Name: The environment variable name (e.g., API_KEY)
    • Type: Select "Key"
    • Key: Choose the key you created
  4. For non-sensitive variables, select "Plain text" and enter the value directly

FEATURES

  • Multiple Transport Types: Supports both HTTP and STDIO (local process) connections
  • No Middleware Required: Direct connection to MCP servers for HTTP transport
  • AI Module Integration: Seamlessly integrates with Drupal AI module's function calling system
  • Tool Management: Easy-to-use UI for enabling/disabling specific tools per server
  • Multiple Servers: Connect to multiple MCP servers simultaneously
  • Secure Credential Management: Integration with Key module for secure storage of API keys and sensitive environment variables
  • Dynamic Plugin System: Tools from MCP servers are automatically discovered and exposed as AI function call plugins

DOCUMENTATION

For more details, look at the ๐Ÿ“š Complete Documentation.

Ask your assistant about MCP Client

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
4
Tracked since
Apr 2025
Latest release
1 month ago
Releases (12 mo)
3 ▲ from 1
Maintenance
Active

Release Timeline

Releases

Version Type Core PHP Release date
1.0.0-alpha3 Pre-release 10โ€“11 Aug 22, 2026
1.0.0-alpha2 Pre-release 10โ€“11 Jul 20, 2026
1.0.0-alpha1 Pre-release 10โ€“11 Dec 16, 2025
1.0.x-dev Dev 10โ€“11 Apr 9, 2025