经 AI Skill Hub 精选评估,unifi-mcp MCP工具 获评「强烈推荐」。这款MCP工具在功能完整性、社区活跃度和易用性方面表现出色,AI 评分 8.2 分,适合有一定技术背景的用户使用。
专为Ubiquiti UniFi网络管理套件开发的MCP服务器工具集,支持Network、Protect、Access等应用集成。通过MCP协议与AI助手协联动,使智能代理能够管理和控制UniFi网络设备、监控和访问控制。适合家庭/企业网络自动化和智能运维人群。
unifi-mcp MCP工具 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
专为Ubiquiti UniFi网络管理套件开发的MCP服务器工具集,支持Network、Protect、Access等应用集成。通过MCP协议与AI助手协联动,使智能代理能够管理和控制UniFi网络设备、监控和访问控制。适合家庭/企业网络自动化和智能运维人群。
unifi-mcp MCP工具 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
# 方式一:通过 Claude Code CLI 一键安装
claude skill install https://github.com/sirkirby/unifi-mcp
# 方式二:手动配置 claude_desktop_config.json
{
"mcpServers": {
"unifi-mcp-mcp--": {
"command": "npx",
"args": ["-y", "unifi-mcp"]
}
}
}
# 配置文件位置
# macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
# Windows: %APPDATA%/Claude/claude_desktop_config.json
# 安装后在 Claude 对话中直接使用 # 示例: 用户: 请帮我用 unifi-mcp MCP工具 执行以下任务... Claude: [自动调用 unifi-mcp MCP工具 MCP 工具处理请求] # 查看可用工具列表 # 在 Claude 中输入:"列出所有可用的 MCP 工具"
// claude_desktop_config.json 配置示例
{
"mcpServers": {
"unifi-mcp_mcp__": {
"command": "npx",
"args": ["-y", "unifi-mcp"],
"env": {
// "API_KEY": "your-api-key-here"
}
}
}
}
// 保存后重启 Claude Desktop 生效
<p align="center"> <img src="docs/assets/hero-readme.jpg" alt="UniFi MCP — AI agents for your UniFi infrastructure" width="720"> </p>
Leverage agents and agentic AI workflows to manage your UniFi deployment.
The MCP servers authenticate to the local UniFi controller APIs with a local admin/service account. Do not use a Ubiquiti SSO cloud account for MCP setup. For Network MCP today, accounts that require SSO MFA or local 2FA are not supported through configuration; use a dedicated local admin account without MFA for the service account, scoped to the permissions you are comfortable giving the MCP server.
Paste the block below into your coding agent. It points the agent at the canonical, versioned setup guide and limits what it may change:
Install UniFi MCP for me using the official instructions at:
https://github.com/sirkirby/unifi-mcp/blob/main/docs/agent-install.md
Before changing anything, identify my agent client and operating system, ask
whether I need Network, Protect, Access, or more than one, and show me the exact
commands and configuration files you plan to change. Wait for my confirmation.
Do not ask me to paste a password or API key into chat. Prefer an indirect
credential provider or the client's secure secret prompt. Keep mutation
permissions in confirm mode and explicitly deny create, update, and delete
unless I opt in. After setup, reload the client, verify the MCP connection and
tool list, and run one harmless read-only check.
The guide covers native plugins, product-scoped npx skills add installs, OpenCode's built-in MCP support, and the current manual paths for Antigravity, Cursor, and Devin Desktop. A skills install adds agent guidance; it does not by itself register the MCP server.
See the changelog for what each plugin release changed, and the plugin upgrade guide before updating an existing install.
Each server supports its own prefixed environment variables that take priority over the shared UNIFI_* variables. This lets you point the Network and Protect servers at different controllers (or different credentials) while keeping a single trusted env file explicitly loaded by the launcher:
| Shared (fallback) | Network server | Protect server | Access server |
|---|---|---|---|
UNIFI_HOST | UNIFI_NETWORK_HOST | UNIFI_PROTECT_HOST | UNIFI_ACCESS_HOST |
UNIFI_USERNAME | UNIFI_NETWORK_USERNAME | UNIFI_PROTECT_USERNAME | UNIFI_ACCESS_USERNAME |
UNIFI_PASSWORD | UNIFI_NETWORK_PASSWORD | UNIFI_PROTECT_PASSWORD | UNIFI_ACCESS_PASSWORD |
UNIFI_PORT | UNIFI_NETWORK_PORT | UNIFI_PROTECT_PORT | UNIFI_ACCESS_PORT |
UNIFI_VERIFY_SSL | UNIFI_NETWORK_VERIFY_SSL | UNIFI_PROTECT_VERIFY_SSL | UNIFI_ACCESS_VERIFY_SSL |
UNIFI_API_KEY | UNIFI_NETWORK_API_KEY | UNIFI_PROTECT_API_KEY | UNIFI_ACCESS_API_KEY |
Single controller? Just set the shared UNIFI_* variables -- all servers will use them. Server-specific variables are only needed when the servers talk to different controllers or use different credentials.
For the full configuration reference including permissions, transports, and advanced options, see the Network server docs, Protect server docs, or Access server docs.
Once connected, just ask your AI agent in natural language:
Network > "Show me all clients on the Guest VLAN with their signal strength and data usage" > "Create a firewall rule that blocks IoT devices from reaching the internet between midnight and 6 AM" > "Audit my firewall policies — are there any redundant or conflicting rules?" > "Show me the top traffic flows from the last hour and group them by destination"
Protect > "List all cameras that detected motion in the last hour" > "Show me smart detection events from the front door camera today — people and vehicles only" > "Find driveway detections for white vans this week"
Access > "Who badged into the office today? Show me a timeline of all door access events" > "Create a visitor pass for John Smith with access to the main entrance tomorrow 9-5"
UniFi Intelligence (the unifi-intelligence plugin) > "Switch aa:bb:cc:00:10:02 dropped off at 8:45 this morning, New York time. What happened between 8:00 and 9:00?" — cites Network events and mapped Protect camera events with their coverage > "Show me everything that happened at the front entrance in the last hour" — needs the cloud worker and relay
All mutations use a preview-then-confirm flow — you see exactly what will change before anything is applied.
Set these variables in the server's process environment (shell exports, the MCP client's env block, or Docker environment: / env_file:):
| Variable | Required | Description |
|---|---|---|
UNIFI_HOST | Yes | Controller IP or hostname |
UNIFI_USERNAME | Yes | Local admin/service account username; do not use a Ubiquiti SSO account |
UNIFI_PASSWORD | Yes | Password for the local account |
UNIFI_API_KEY | No | UniFi API key for selected capabilities, including firewall policy ordering and some Protect settings updates |
CONFIG_PATH | No | Absolute path to an operator-controlled custom YAML file; otherwise uses bundled configuration |
UNIFI_SETTINGS_FILE | No | Absolute path (~ allowed) to a per-user settings file of UNIFI_* variables; see below |
UNIFI_DEFER_CONTROLLER_INIT | No | Network only: make no controller connection at startup and connect on the first tool call instead. By default every server answers the MCP client at once and connects in the background |
UNIFI_META_TOOLS_ENABLED | No | Network eager mode only: set false to omit indirect meta-tools; requires UNIFI_ENABLED_CATEGORIES or UNIFI_ENABLED_TOOLS |
Startup configuration: The servers do not automatically load .env files or config/config.yaml from the working directory. MCP clients may launch servers inside untrusted projects, so project files must not control where credentials are sent or weaken permissions and redaction. If you previously relied on automatic loading, select a trusted env file in your launcher (for example, uv run --env-file /absolute/path/to/trusted.env --with unifi-network-mcp unifi-network-mcp) or set an absolute CONFIG_PATH for custom YAML. Docker Compose env_file: remains supported.
Per-user settings file: UNIFI_SETTINGS_FILE names a file the server reads at startup, before anything else reads configuration. The Codex plugin's setup writes ~/.config/unifi-mcp/<product>.env and points its bundled server at it. The file holds KEY=VALUE lines (# comments, optional matching quotes; no export, interpolation or multi-line values). Only UNIFI_* keys are accepted, and each behaves exactly as if exported, including _FILE / _COMMAND providers and policy gates. Variables already in the process environment win. A missing file is not an error. On POSIX the file must be owned by you and not group- or world-writable (keep it chmod 600); Windows has no mode check, so keep it in your user profile.
To keep the secret out of the MCP client's environment (and out of every process the client spawns), set UNIFI_PASSWORD_FILE to a path whose contents are the password, or UNIFI_PASSWORD_COMMAND to an absolute argv whose stdout is the password (contract). The same _FILE / _COMMAND suffixes work on UNIFI_API_KEY and on the per-server variables below. Details are in each server's docs/configuration.md.
| Component | Status | Package |
|---|---|---|
| [API Server](https://github.com/sirkirby/unifi-mcp/tree/main/apps/api) | Beta | [unifi-api-server](https://pypi.org/project/unifi-api-server/) · [GHCR image](https://github.com/sirkirby/unifi-mcp/pkgs/container/unifi-api-server) |
unifi-api-server is an independent HTTP service for custom applications, automation, and adapters. It provides typed REST resources, read-only GraphQL queries, SSE streams, scoped API keys and administration, plus a REST action endpoint for supported controller operations. It shares unifi-core managers with the MCP servers but does not proxy or require them.
See apps/api/README.md for quick-start and deployment patterns.
Install these from the Claude Code, Codex or OpenClaw marketplace; Quick Start shows how.
| Plugin | What you get |
|---|---|
unifi-network | The Network MCP server, its agent skills and guided setup |
unifi-protect | The Protect MCP server, its agent skills and guided setup |
unifi-access | The Access MCP server, its agent skills and guided setup |
unifi-intelligence | Cross-product investigations that use Network and Protect together, with every claim cited. Incident Investigation runs locally; Security Patrol and Visitor Audit need the [cloud worker](#cloud-relay). It requires the Network and Protect plugins |
The Agent Skills table lists every skill each plugin ships.
| What you are building | Use | Why |
|---|---|---|
| An AI assistant or another existing MCP client | [Network](apps/network/), [Protect](apps/protect/), or [Access](apps/access/) MCP server | Standard MCP discovery, tool calls, permissions, and confirmation flows |
| A custom application, automation service, code-execution runtime, or MCP adapter | [unifi-api-server](apps/api/) | Your code controls call sequencing, data joins, resource limits, and approval flow |
| Remote access for an MCP client | [Cloud Relay](packages/unifi-mcp-relay/) | Authenticated remote MCP routing without exposing the local servers directly |
An MCP adapter can expose a small set of tools while using unifi-api-server as its backend. This keeps application-specific joins, branching, loops, and code isolation out of the general-purpose MCP servers.
高质量的MCP工具,填补UniFi与AI代理集成的空白。代码活跃维护,适配主流MCP框架,为家庭/企业智能化提供专业解决方案。
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ MIT 协议 — 最宽松的开源协议之一,可自由商用、修改、分发,仅需保留版权声明。
AI Skill Hub 点评:unifi-mcp MCP工具 的核心功能完整,质量优秀。对于Claude Desktop / Claude Code 用户来说,这是一个值得纳入个人工具库的选择。建议先在非生产环境试用,再逐步推广。
| 原始名称 | unifi-mcp |
| 原始描述 | 开源MCP工具:MCP servers for the UniFi suite of applications, Network, Protect, Access, and D。⭐343 · Python |
| Topics | UniFi网络管理MCP服务器智能代理家庭自动化Python |
| GitHub | https://github.com/sirkirby/unifi-mcp |
| License | MIT |
| 语言 | Python |
收录时间:2026-05-17 · 更新时间:2026-05-19 · License:MIT · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端