The Unraid MCP Server provides an interface for interacting with an Unraid server's GraphQL API through the Model Context Protocol (MCP), allowing AI assistants like Claude to directly communicate with your Unraid system.
Set up your environment file:
cp .env.example .env
Edit the .env
file with your Unraid details:
UNRAID_API_URL=http://your-unraid-ip/graphql
UNRAID_API_KEY=your-unraid-api-key
UNRAID_MCP_TRANSPORT=streamable-http
UNRAID_MCP_HOST=0.0.0.0
UNRAID_MCP_PORT=6970
UNRAID_MCP_LOG_LEVEL=INFO
UNRAID_MCP_LOG_FILE=unraid-mcp.log
UNRAID_VERIFY_SSL=true
Install required dependencies:
pip install fastmcp python-dotenv httpx
Run the server:
python unraid-mcp-server.py
Create a .env.local
file with your configuration:
UNRAID_API_URL=http://your-unraid-ip/graphql
UNRAID_API_KEY=your-unraid-api-key
Run using Docker Compose:
docker-compose up -d
Or manually with Docker:
docker build -t unraid-mcp-server .
docker run -d --name unraid-mcp --restart unless-stopped -p 6970:6970 --env-file .env.local unraid-mcp-server
Add the following to your Claude Desktop MCP settings file at ~/.config/claude/claude_mcp_settings.jsonc
:
{
"mcp_servers": {
"unraid": {
"url": "http://localhost:6970/mcp",
"disabled": false,
"timeout": 60,
"transport": "streamable-http"
}
}
}
The MCP server provides several tools for interacting with your Unraid system:
get_system_info()
: Retrieves system, OS, CPU, memory, and hardware informationget_array_status()
: Gets storage array status, capacity, and disk detailsget_network_config()
: Retrieves network configuration detailsget_unraid_variables()
: Retrieves Unraid system variables and settingslist_docker_containers(skip_cache: Optional[bool] = False)
: Lists all Docker containersmanage_docker_container(container_id: str, action: str)
: Controls Docker containers (start/stop)get_docker_container_details(container_identifier: str)
: Gets detailed container infolist_vms()
: Lists all Virtual Machinesmanage_vm(vm_id: str, action: str)
: Controls VMs (start, stop, pause, etc.)get_vm_details(vm_identifier: str)
: Gets VM detailslist_physical_disks()
: Lists all physical disksget_disk_details(disk_id: str)
: Retrieves SMART info for a specific diskget_shares_info()
: Retrieves information about user sharesget_notifications_overview()
: Gets system notification summarylist_notifications(type: str, offset: int, limit: int, importance: Optional[str] = None)
: Lists notificationslist_available_log_files()
: Lists available log filesget_logs(log_file_path: str, tail_lines: Optional[int] = 100)
: Retrieves log contentget_registration_info()
: Retrieves Unraid registration detailsget_connect_settings()
: Retrieves Unraid Connect settingsView logs:
docker logs unraid-mcp
Follow logs in real-time:
docker logs -f unraid-mcp
Stop and remove container:
docker stop unraid-mcp
docker rm unraid-mcp
To add this MCP server to Claude Code, run this command in your terminal:
claude mcp add-json "unraid" '{"url":"http://localhost:6970/mcp","disabled":false,"timeout":60,"transport":"sse"}'
See the official Claude Code MCP documentation for more details.
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"unraid": {
"url": "http://localhost:6970/mcp",
"disabled": false,
"timeout": 60,
"transport": "sse"
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.
To add this MCP server to Claude Desktop:
1. Find your configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%\Claude\claude_desktop_config.json
~/.config/Claude/claude_desktop_config.json
2. Add this to your configuration file:
{
"mcpServers": {
"unraid": {
"url": "http://localhost:6970/mcp",
"disabled": false,
"timeout": 60,
"transport": "sse"
}
}
}
3. Restart Claude Desktop for the changes to take effect