WRT-MCP

High-performance Model Context Protocol (MCP) server for managing OpenWrt routers over SSH.

Overview

WRT-MCP is a single-binary Model Context Protocol (MCP) server written in Go for managing, monitoring, and auditing OpenWrt routers over passwordless SSH.

It allows AI coding assistants and agentic systems to safely query network interfaces, examine DHCP leases, inspect firewall configurations (UCI), check wireless telemetry, and run router diagnostics with automated safety backups.


Features

  • System & Radio Telemetry: Fetch hardware board specs, kernel metrics, uptime, memory, DHCP lease maps, and wireless channel utilization (iwinfo).
  • UCI Configuration Inspection: Direct read access to OpenWrt Unified Configuration Interface configs (wireless, network, dhcp, firewall, system).
  • Network Diagnostics: Execute ping, nslookup, or traceroute from the router’s internal perspective.
  • Safety-First Maintenance: Package upgrades (opkg upgrade) and firmware testing automatically create timestamped .tar.gz system backups before executing destructive actions.
  • Pure Go Binary: Single standalone binary with zero external runtime dependencies.

Installation & Setup

zsh — install wrt-mcp
$ go install github.com/msjurset/wrt-mcp@latest

Configure in your MCP client settings (e.g. Antigravity, Claude Desktop):

{
  "mcpServers": {
    "openwrt": {
      "command": "wrt-mcp",
      "args": ["--host", "192.168.1.1", "--user", "root"]
    }
  }
}