New:Microsoft Teams Notifications Are Now Available in Socket.Learn more
Get Started

unraid-rmcp

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

unraid-rmcp

Node launcher for the unraid-rmcp Rust MCP server and CLI binary.

Source
npmnpm
Version
0.2.2
Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

unraid-rmcp

Rust MCP server that bridges Claude (and any MCP client) to the Unraid server GraphQL API. Exposes 24 read-only data actions covering array health, Docker, VMs, shares, logs, metrics, UPS, and more, plus a status observability action and a help action.

Rust MCP naming pattern

This repo follows the Rust MCP server naming convention:

  • Repo: unraid-rmcp
  • CLI alias: runraid
  • npm package: unraid-rmcp

npm / npx

Run the stdio MCP server or CLI without a manual binary install:

npx -y unraid-rmcp --help

MCP clients can use the same launcher:

{
  "mcpServers": {
    "unraid-rmcp": {
      "command": "npx",
      "args": ["-y", "unraid-rmcp"]
    }
  }
}

The npm package downloads the runraid binary from GitHub Releases during postinstall and keeps the release tag aligned with packages/unraid-rmcp/package.json.

Architecture

                      ┌────────────────────────────────────┐
  Claude / MCP ◀────▶ │  POST /mcp  (RMCP Streamable HTTP) │
  stdio client ◀────▶ │  runraid mcp  (stdio transport)     │
                      │                                    │
                      │  mcp/tools.rs  ─▶  app.rs          │
                      │                       │            │
                      │                  graphql.rs        │
                      │                       │            │
                      │             POST <UNRAID_API_URL>   │
                      │             x-api-key: <key>       │
                      └───────────────────────┼────────────┘
                                              │
                              Unraid GraphQL API (myunraid.net)
  • graphql.rs — HTTP client: POSTs GraphQL queries to the Unraid API with the x-api-key header
  • app.rsUnraidService: business layer, one method per action, no logic
  • mcp/tools.rs — thin shim: parse JSON args, call service, return Value
  • cli.rs — thin shim: parse CLI args, call service, format and print
  • main.rs — mode dispatch: HTTP MCP server, stdio MCP, or CLI

Quickstart

Prerequisites

  • Rust 1.90+ (rustup show)
  • Unraid API URL and API key (Settings → API Management in Unraid)
  • Platform: linux/amd64 only. Release binaries, the Docker image, and CI builds target x86_64 exclusively — arm64/aarch64 is not built or supported.

Run

git clone https://github.com/jmagar/unraid-rmcp
cd unraid-rmcp

# Set required environment variables
export UNRAID_API_URL="https://10-1-0-2.<hash>.myunraid.net:31337/graphql"
export UNRAID_API_KEY="your-api-key-here"
export UNRAID_RMCP_PORT=40010
export UNRAID_RMCP_DISABLE_HTTP_AUTH=true

# Or copy .env and edit it
cp .env .env.local

# Start the MCP HTTP server
cargo run -- serve mcp

# Verify it is up
curl -sf http://localhost:40010/health | jq .
# → {"status":"ok"}

First MCP call

curl -s -X POST http://localhost:40010/mcp \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "tools/call",
    "params": {
      "name": "unraid",
      "arguments": {"action": "server"}
    }
  }' | jq .result.content[0].text | jq -r . | jq .

Transports

ModeCommandDescription
HTTP MCPrunraid serve mcp or runraid (no args)RMCP Streamable HTTP on POST /mcp
stdio MCPrunraid mcpFor MCP clients that launch the server as a child process
CLIrunraid <command>Human-readable or --json output

MCP Tool Reference

One tool is exposed: unraid. Set the required action argument to select the operation.

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "unraid",
    "arguments": {"action": "array"}
  }
}

Core actions

ActionDescription
arrayArray state, disk health, parity check status, capacity
disksPhysical disks with SMART status, temperature, interface type
dockerAll Docker containers: state, status, ports, update availability
docker_logsContainer logs — requires id, optional tail (default 100)
vmsVirtual machines and their state
serverServer identity, LAN/WAN IP, local and remote URLs
infoOS, CPU, memory layout, Unraid and kernel versions
sharesUser shares with size, cache settings, LUKS status
notificationsActive warnings and alerts with overview counts

System actions

ActionDescription
servicesRunning system services with uptime
networkNetwork access URLs (type, name, IPv4, IPv6)
metricsLive CPU percent per core, memory usage, temperature sensors
varsSystem configuration variables (hostname, sharing, SSL, SSH)
registrationLicense type, state, expiry
flashUSB flash drive vendor and product info

Log actions

ActionDescriptionExtra args
log_filesList available log files with sizes and modification times
log_fileRead a log filepath (required), lines, start_line

Storage actions

ActionDescription
parity_historyAll past parity check results (date, duration, speed, errors)
rcloneBackup remote configurations and drive names

UPS actions

ActionDescription
upsUPS devices: battery charge, estimated runtime, power load
ups_configUPS monitoring configuration (service, type, shutdown thresholds)

Remote access actions

ActionDescription
remote_accessWAN access type and port forwarding configuration
connectUnraid Connect dynamic remote access status and settings

Plugin actions

ActionDescription
pluginsInstalled community plugins with versions

Meta

ActionDescription
statusServer observability: version, PID, uptime, and request counters (requires unraid:read)
helpMarkdown reference for all actions (no auth required)

Action parameters

ParameterTypeUsed byDescription
actionstringallOperation to perform (required)
idstringdocker_logsContainer ID
pathstringlog_fileLog file path
linesintegerlog_fileNumber of lines to read
start_lineintegerlog_fileStarting line number (1-indexed)
tailintegerdocker_logsLines to return (default 100)
limitintegerlist actionsMax items per page (default 50, max 200)
offsetintegerlist actionsNumber of items to skip (default 0)
statestringdockerFilter containers by state
namestringshares, pluginsFilter results by name

Pagination and filtering are MCP-only. List actions return a paginated envelope:

{
  "items": [ /* ... */ ],
  "total": 120,
  "limit": 50,
  "offset": 0,
  "has_more": true,
  "next_offset": 50
}

CLI Reference

All CLI commands accept --json for machine-readable output.

runraid [serve]                       Start MCP HTTP server (default)
runraid mcp                           Start MCP stdio transport

Core:
  runraid array [--json]
  runraid disks [--json]
  runraid docker [--json]
  runraid docker logs <id> [--tail N] [--json]
  runraid vms [--json]
  runraid server [--json]
  runraid info [--json]
  runraid shares [--json]
  runraid notifications [--json]

System:
  runraid services [--json]
  runraid network [--json]
  runraid metrics [--json]
  runraid vars [--json]
  runraid registration [--json]
  runraid flash [--json]

Logs:
  runraid log-files [--json]
  runraid log <path> [--lines N] [--start-line N] [--json]

Storage:
  runraid parity-history [--json]
  runraid rclone [--json]

UPS:
  runraid ups [--json]
  runraid ups-config [--json]

Remote access:
  runraid remote-access [--json]
  runraid connect [--json]

Plugins:
  runraid plugins [--json]

Every read-only data action is reachable from both the CLI and the MCP tool. A few capabilities are surface-specific: status is MCP-only, the setup and doctor commands are CLI-only, and pagination/filtering and output truncation apply only to MCP responses.

HTTP Endpoints

EndpointMethodAuthDescription
/mcpPOSTyes (when configured)RMCP Streamable HTTP
/healthGETnoAlways returns {"status":"ok"}
/mcp/.well-known/oauth-authorization-serverGETnoOAuth metadata (OAuth mode only)

Configuration

Configuration loads from three sources, highest priority first:

  • Environment variables
  • config.toml (if present in the working directory)
  • Built-in defaults

Environment variables

VariableRequiredDefaultDescription
UNRAID_API_URLyesUnraid GraphQL endpoint
UNRAID_API_KEYyesAPI key sent as x-api-key header
UNRAID_API_SKIP_TLS_VERIFYnofalseSkip TLS certificate check
UNRAID_RMCP_HOSTno0.0.0.0Bind host
UNRAID_RMCP_PORTno40010Bind port
UNRAID_RMCP_TOKENnoStatic bearer token for /mcp
UNRAID_RMCP_DISABLE_HTTP_AUTHnofalseDisable MCP auth (safe on loopback or trusted networks)
UNRAID_RMCP_NO_AUTHnofalseAlias for disabling auth
UNRAID_RMCP_ALLOWED_HOSTSnoExtra comma-separated Host header values
UNRAID_RMCP_ALLOWED_ORIGINSnoExtra comma-separated CORS origins
UNRAID_RMCP_PUBLIC_URLnoPublic URL for OAuth metadata
RUST_LOGnoinfoLog filter (e.g. debug, warn)

config.toml

[unraid]
api_url = "https://10-1-0-2.<hash>.myunraid.net:31337/graphql"
api_key  = "your-api-key"
# skip_tls_verify = false

[mcp]
host = "0.0.0.0"
port = 40010
server_name = "unraid-rmcp"
# allowed_hosts = ["unraid.example.com"]
# allowed_origins = ["https://unraid.example.com"]

Authentication

Three auth modes are supported:

No auth (loopback or trusted network): Set UNRAID_RMCP_DISABLE_HTTP_AUTH=true. Auth is also automatically disabled when the bind host starts with 127..

Static bearer token: Set UNRAID_RMCP_TOKEN=<token>. All /mcp requests must include Authorization: Bearer <token>. /health remains unauthenticated.

OAuth (Google): Set UNRAID_RMCP_PUBLIC_URL, UNRAID_RMCP_GOOGLE_CLIENT_ID, UNRAID_RMCP_GOOGLE_CLIENT_SECRET, and UNRAID_RMCP_AUTH_ADMIN_EMAIL. The server issues RS256 JWTs after Google login. Scopes: unraid:read, unraid:admin.

Development

just dev       # cargo run -- serve mcp
just check     # cargo check
just lint      # cargo clippy -- -D warnings
just fmt       # cargo fmt
just test      # cargo test
just build     # cargo build
just release   # cargo build --release
just gen-token # openssl rand -hex 32

Claude Code / stdio config

{
  "mcpServers": {
    "unraid-rmcp": {
      "command": "/path/to/runraid",
      "args": ["mcp"],
      "env": {
        "UNRAID_API_URL": "https://...",
        "UNRAID_API_KEY": "your-key",
        "RUST_LOG": "warn"
      }
    }
  }
}

License

MIT

Keywords

mcp

FAQs

Package last updated on 09 Jul 2026

Related posts