UniFi Internal API MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@UniFi Internal API MCP Serverlist all connected clients"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
UniFi Internal API MCP Server
An MCP (Model Context Protocol) server that exposes the internal UniFi Controller API — the same API the web UI uses — as tools for AI assistants.
This wraps the cookie-authenticated controller endpoints documented in the Art-of-WiFi/UniFi-API-client PHP library, providing ~170 tools for managing UniFi networks.
Features
Full controller access: Clients, devices, WLANs, networks, firewall, statistics, events, admins, firmware, backups, DNS, RADIUS, DPI, hotspot/vouchers, and more
Cookie-based authentication: Uses the same session auth as the UniFi web UI
UniFi OS support: Works with UDM, UDR, UCG, and legacy standalone controllers
Readonly safety mode: Write operations blocked by default — enable explicitly
170+ tools across 19 categories
Related MCP server: UniFi MCP Server
Quick Start
Clone this repository
Copy
.env.exampleto.envand fill in your controller detailsRun:
uv run unifi-internal-api-mcp
Configuration
Variable | Description | Default |
| Controller URL (e.g. | required |
| Controller username | |
| Controller password | |
| Pre-authenticated TOKEN cookie (alternative to username/password) | |
| Site name |
|
| UniFi OS controller (UDM/UDR/UCG) |
|
| Block all write operations |
|
| Verify SSL certificates |
|
Authentication
Option 1: Username/password — for self-hosted controllers without 2FA:
UNIFI_USERNAME=admin
UNIFI_PASSWORD=your-passwordOption 2: Browser token — for cloud-hosted (ui.com) or 2FA-enabled controllers:
Log into your controller in a browser
Open DevTools (Cmd+Option+I) > Application > Cookies
Copy the
TOKENcookie value
UNIFI_TOKEN=eyJhbGciOiJIUzI1NiIs...The token expires after ~30 days. When using a token, the server won't log out (so your browser session stays valid).
Tool Categories
Module | Tools | Description |
| 15 | Sysinfo, health, dashboard, settings, device states |
| 13 | Site management, settings (country, SNMP, NTP, etc.) |
| 20 | Client management, guest auth, block/unblock |
| 23 | Device adoption, restart, locate, radio settings |
| 9 | Vouchers, hotspot operators, guest login |
| 8 | WLAN configuration, MAC filters |
| 4 | Network CRUD |
| 5 | Firewall groups and rules |
| 22 | 5min/hourly/daily/monthly stats, speedtest, IPS |
| 4 | Events and alarms |
| 8 | Admin management and permissions |
| 10 | Firmware updates, rolling upgrades |
| 3 | Backup generation and export |
| 3 | DNS records (v2 API) |
| 5 | RADIUS profiles and accounts |
| 5 | Device tags |
| 5 | DPI stats, port forwarding, system log |
| 4 | User groups (bandwidth profiles) |
| 4 | AP groups (v2 API) |
MCP Client Configuration
Add to your MCP client config (e.g. Claude Desktop):
{
"mcpServers": {
"unifi-internal": {
"command": "uv",
"args": ["run", "--directory", "/path/to/unifi_internal_api_mcp", "unifi-internal-api-mcp"],
"env": {
"UNIFI_HOST": "https://your-controller-url",
"UNIFI_TOKEN": "eyJhbGciOiJIUzI1NiIs...",
"UNIFI_SITE": "default",
"UNIFI_READONLY": "true"
}
}
}
}Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityCmaintenanceEnables AI assistants to interact with Ubiquiti UniFi network infrastructure for monitoring devices, managing clients, and performing configuration tasks like blocking/unblocking devices and viewing network health.Last updated101GPL 3.0
- AlicenseDqualityDmaintenanceEnables comprehensive management of UniFi network infrastructure through the UniFi Cloud API, including device control, client management, camera settings, and access door control through natural language.Last updated3933Apache 2.0
- AlicenseBqualityDmaintenanceEnables AI assistants to manage and monitor UniFi Network Controllers through natural language. Provides 25 read-only tools for discovering devices and clients, viewing security configurations, analyzing network statistics, and exporting configuration data.Last updated41MIT
- AlicenseBqualityDmaintenanceEnables AI assistants to manage UniFi network infrastructure through 50+ tools covering devices, clients, networks, WiFi, firewall rules, and guest access using the official UniFi Network API.Last updated52754MIT
Related MCP Connectors
Universal AI API Orchestrator — 1,554 tools, 96 services. One install.
SaaS intelligence for AI agents. 5 unified tools cover 1,000+ services with 91-96% token savings.
60+ Meta Ads tools for AI agents: audits, campaign management, audiences and CAPI tracking.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/sevaepsteyn/unifi_internal_api_mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server