# mcp-server-drupal

> MCP Server

This repository provides a TypeScript-based Model Context Protocol (MCP) server for Drupal, designed to work with the STDIO transport, facilitating communication between Drupal and applications like Claude Desktop.

## Overview

- **Category:** Developer Tools
- **Language:** TypeScript
- **Stars:** 51
- **Forks:** 1
- **Owner:** Omedia
- **GitHub:** https://github.com/Omedia/mcp-server-drupal
- **Homepage:** https://www.drupal.org/project/mcp
- **Created:** 2024-12-09T07:12:02+00:00
- **Updated:** 2025-03-26T02:36:08+00:00
- **Source:** https://model-context-protocol.com/servers/typescript-mcp-server-for-drupal-stdio

## Setup

## Setup

- Download the binary for your system from the [releases](https://github.com/Omedia/mcp-server-drupal/releases) page.
- Add the server config in the `claude_desktop_config.json` file, located at `~/Library/Application Support/Claude/claude_desktop_config.json` (MacOS) or `%APPDATA%/Claude/claude_desktop_config.json` (Windows).
- Use the provided JSON configuration snippet, replacing `__BINARY_PATH__` with the path to the downloaded binary and `__DRUPAL_BASE_URL__` with the base URL of your Drupal site.
- `--drupal-url` is a required argument.
- Check the server and sdk version using `mcp-server-drupal --version`.
- Check available commands using `mcp-server-drupal --help`.
- Alternatively, use the server as a deno module via `npx` with the provided JSON configuration.
- Set authentication via environment variables: `DRUPAL_AUTH_TOKEN`, `DRUPAL_AUTH_USER`, and `DRUPAL_AUTH_PASSWORD`.
- Ensure authentication is enabled in the Drupal MCP module settings.
- Install dependencies for development using `deno install`.
- For development with auto-rebuild, use `bun task dev`.
- Build the server using `deno task build --output build/mcp-server-drupal`.
- Verify the binaries using cosign with the provided instructions.

## Tools

## Available Tools

1.  Resources (templates, reads) - Exposes resources defined by the Drupal API during initialization.
2.  Tools (calls) - Exposes tools defined by the Drupal API during initialization.
3.  Authentication - Supports authentication via token or username/password.
4.  MCP Inspector - A tool for debugging MCP servers communicating over stdio.

