MCPSERV.CLUB
sirkirby

UniFi Network MCP Server

MCP Server

Turn your UniFi controller into an AI‑powered network assistant

Active(72)
52stars
0views
Updated 12 days ago

About

A self‑hosted MCP server that exposes UniFi Network Controller operations as standard tools, enabling LLMs and agents to query, analyze, and (with explicit consent) modify your network.

Capabilities

Resources
Access data sources
Tools
Execute functions
Prompts
Pre-built templates
Sampling
AI model interactions

Overview

The UniFi Network MCP Server transforms a UniFi Network Controller into a fully‑exposed, AI‑friendly API. By wrapping every controller operation—firewall rules, routing tables, port forwards, QoS policies, VPN endpoints, WLAN configurations, device and client statistics, and more—into standard MCP tools prefixed with , it allows any LLM or autonomous agent that understands the Model Context Protocol to query, analyze, and even modify a network from within its own workflow. This eliminates the need for custom integrations or manual CLI usage, giving developers a single, consistent interface to interact with their UniFi infrastructure.

For developers building chatbots or automation agents, the server offers a turnkey solution to embed network management into conversational flows. A user can ask an assistant, “Show me the traffic statistics for site default,” and the MCP server will return a structured JSON payload that the assistant can display or further process. When an agent needs to change configuration—such as adding a new VLAN or updating a firewall rule—the corresponding mutating tool requires an explicit flag, providing a safeguard against accidental changes. This design balances powerful automation with safety, making the server suitable for both development and production environments.

Key capabilities include:

  • Comprehensive tool catalog: Every controller API endpoint is represented, enabling fine‑grained control over network policies and device states.
  • Dual transport modes: The server communicates via FastMCP over stdio by default, with an optional SSE HTTP endpoint for web‑based clients.
  • Secure deployment: Credentials are supplied through environment variables or a local file, and the server can run behind a secure reverse proxy for cloud deployment.
  • Python‑centric architecture: Built on modern Python 3.10+, packaged with , and installable via PyPI or Docker, it fits naturally into existing Python toolchains.

Typical use cases span from automated network diagnostics—where an agent can continuously monitor client connectivity and report anomalies—to dynamic policy enforcement, where a conversational interface can adjust QoS settings in real time based on user requests. In research or educational settings, the server serves as a sandbox for teaching network concepts through interactive AI dialogues. By exposing UniFi’s full feature set in a declarative, tool‑based format, the UniFi Network MCP Server empowers developers to integrate sophisticated network management directly into AI assistants and autonomous systems.