GitHits
Search public open-source code, documentation, metadata, vulnerabilities, changelogs, and examples.
Manage UniFi Network devices, clients, firewall, VLANs, VPNs, and more via MCP.
列表按使用分(满分 100)排序,由以下部分组成
| 热度 | 46/80 | GitHub 星标或每周下载量:较大的计 60,较小的计 20 |
|---|---|---|
| 新鲜度 | 12/12 | 30 天内有发布或代码更新得满分 |
| 仍在响应 | 0/8 | 上次检查时云端端点有响应 |
| 使用分 | 58/100 |
质量: 基础检查通过 3/3 项(仅展示,不用于排序) · 上升势头: 81 (只用于“上升中”标签)
选择你使用的 AI 应用,然后复制设置。
用一句话让 AI 帮你安装
请帮我安装 UniFi Network MCP。按照 https://mcp.popnx.com/i/sirkirby-unifi-network-mcp.md 操作,先把命令给我看,等我同意后再运行。粘贴到能在你电脑上工作的 AI(如 Claude Code、Cursor)。它会读取我们的步骤,先给你看命令,等你同意。无需密钥,无需注册。 · 查看 AI 会读取的全文
通过 3/3 项检查 · 在你的电脑上运行 · ✓ 命令已检查 2026年11月14日
第一步:你用哪个 AI?
选择你用的应用,步骤会显示在下方。
可连接 Claude,但需要先准备
需要 UniFi Network MCP 的密钥(在开发者网站创建) · 需要填写 1 项设置(UNIFI_HOST) · 需要先在电脑上安装 Python (uv)(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用
把这段话复制到 Claude 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。
请在这台电脑上为 Claude 安装 MCP server UniFi Network MCP,按顺序:1) 用 uv --version 检查是否有 uv。没有的话,请让我从 https://docs.astral.sh/uv/getting-started/installation/ 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "mcpServers": { "unifi-network": { "command": "uvx", "args": [ "unifi-network-mcp" ], "env": { "UNIFI_HOST": "your-value", "UNIFI_USERNAME": "your-value", "UNIFI_PASSWORD": "your-value" } } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) UNIFI_USERNAME, UNIFI_PASSWORD, UNIFI_HOST 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 UniFi Network MCP 的工具真的出现了。这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。
已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter
uv --versionMac:按 ⌘ + Space,输入 Terminal 后按 Enter
Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”
还没安装: uv 没有点选式安装程序。从 uv 官方页面复制适合你系统(macOS 或 Windows)的一行命令,粘贴到终端 · 不需要单独安装 Python,uv 会在需要时自动下载
装好后关掉终端再打开,重新运行同一条命令,应显示版本号: uv --version
安装一次,所有需要 uv 的工具都能用
这些是程序设置,不是密钥,无需注册。按开发者的说明填写。
UNIFI_HOST 控制器 IP 地址或主机名 说明为自动翻译,变量名保持原样;不确定时请查看原文。
SettingsDeveloperEdit Config
{
"mcpServers": {
"unifi-network": {
"command": "uvx",
"args": [
"unifi-network-mcp"
],
"env": {
"UNIFI_HOST": "your-value",
"UNIFI_USERNAME": "your-value",
"UNIFI_PASSWORD": "your-value"
}
}
}
}只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人
用 UniFi Network MCP 告诉我你能帮我做什么,然后做一件给我看✓ 如果 Claude 说正在使用 UniFi Network MCP,或回答中出现 UniFi Network MCP 的工具名称,就表示连接成功
上面的命令不填这些也能用。想调整时再按开发者的说明添加。
UNIFI_API_KEY API 密钥(可选,实验性) UNIFI_PORT 控制器 HTTPS 端口 UNIFI_VERIFY_SSL SSL 证书验证 UNIFI_SITE UniFi 站点名称 说明为自动翻译,变量名保持原样;不确定时请查看原文。
菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同
ChatGPT 暂时无法连接 UniFi Network MCP
UniFi Network MCP 需要安装在你的电脑上,而 ChatGPT 只能连接在网上运行的服务器
A · 使用能连接 UniFi Network MCP 的应用
B · 网络安全 类中能连接 ChatGPT 的其他服务器
从同类中使用较多的里挑选,仅限用地址即可连接、无需密钥的
可连接 Claude Code,但需要先准备
需要 UniFi Network MCP 的密钥(在开发者网站创建) · 需要填写 1 项设置(UNIFI_HOST) · 需要先在电脑上安装 Python (uv)(只需一次)
把这段话复制到 Claude Code 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。
请在这台电脑上为 Claude Code 安装 MCP server UniFi Network MCP,按顺序:1) 用 uv --version 检查是否有 uv。没有的话,请让我从 https://docs.astral.sh/uv/getting-started/installation/ 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):claude mcp add --scope user unifi-network --env UNIFI_HOST=your-value --env UNIFI_USERNAME=your-value --env UNIFI_PASSWORD=your-value -- uvx unifi-network-mcp 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) UNIFI_USERNAME, UNIFI_PASSWORD, UNIFI_HOST 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 UniFi Network MCP 的工具真的出现了。这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。
已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter
uv --versionMac:按 ⌘ + Space,输入 Terminal 后按 Enter
Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”
还没安装: uv 没有点选式安装程序。从 uv 官方页面复制适合你系统(macOS 或 Windows)的一行命令,粘贴到终端 · 不需要单独安装 Python,uv 会在需要时自动下载
装好后关掉终端再打开,重新运行同一条命令,应显示版本号: uv --version
安装一次,所有需要 uv 的工具都能用
打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。
获取密钥的方法见下方开发者的 README
这些是程序设置,不是密钥,无需注册。按开发者的说明填写。
UNIFI_HOST 控制器 IP 地址或主机名 说明为自动翻译,变量名保持原样;不确定时请查看原文。
Mac:按 Command+空格,输入 Terminal · Windows:打开 PowerShell
claude mcp add --scope user unifi-network --env UNIFI_HOST=your-value --env UNIFI_USERNAME=your-value --env UNIFI_PASSWORD=your-value -- uvx unifi-network-mcp按 Enter 前,把“your-value”改成你的密钥
只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人
应能看到 UniFi Network MCP 在列表中并显示已连接
用 UniFi Network MCP 告诉我你能帮我做什么,然后做一件给我看✓ 如果 Claude Code 说正在使用 UniFi Network MCP,或回答中出现 UniFi Network MCP 的工具名称,就表示连接成功
上面的命令不填这些也能用。想调整时再按开发者的说明添加。
UNIFI_API_KEY API 密钥(可选,实验性) UNIFI_PORT 控制器 HTTPS 端口 UNIFI_VERIFY_SSL SSL 证书验证 UNIFI_SITE UniFi 站点名称 说明为自动翻译,变量名保持原样;不确定时请查看原文。
菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同
可连接 Cursor,但需要先准备
需要 UniFi Network MCP 的密钥(在开发者网站创建) · 需要填写 1 项设置(UNIFI_HOST) · 需要先在电脑上安装 Python (uv)(只需一次)
把这段话复制到 Cursor 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。
请在这台电脑上为 Cursor 安装 MCP server UniFi Network MCP,按顺序:1) 用 uv --version 检查是否有 uv。没有的话,请让我从 https://docs.astral.sh/uv/getting-started/installation/ 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "mcpServers": { "unifi-network": { "command": "uvx", "args": [ "unifi-network-mcp" ], "env": { "UNIFI_HOST": "your-value", "UNIFI_USERNAME": "your-value", "UNIFI_PASSWORD": "your-value" } } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) UNIFI_USERNAME, UNIFI_PASSWORD, UNIFI_HOST 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 UniFi Network MCP 的工具真的出现了。这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。
已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter
uv --versionMac:按 ⌘ + Space,输入 Terminal 后按 Enter
Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”
还没安装: uv 没有点选式安装程序。从 uv 官方页面复制适合你系统(macOS 或 Windows)的一行命令,粘贴到终端 · 不需要单独安装 Python,uv 会在需要时自动下载
装好后关掉终端再打开,重新运行同一条命令,应显示版本号: uv --version
安装一次,所有需要 uv 的工具都能用
打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。
获取密钥的方法见下方开发者的 README
这些是程序设置,不是密钥,无需注册。按开发者的说明填写。
UNIFI_HOST 控制器 IP 地址或主机名 说明为自动翻译,变量名保持原样;不确定时请查看原文。
在 UniFi Network MCP 的设置中,UNIFI_USERNAME, UNIFI_PASSWORD, UNIFI_HOST 还是空的,填入你的密钥并保存
只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人
用 UniFi Network MCP 告诉我你能帮我做什么,然后做一件给我看✓ 如果 Cursor 说正在使用 UniFi Network MCP,或回答中出现 UniFi Network MCP 的工具名称,就表示连接成功
上面的命令不填这些也能用。想调整时再按开发者的说明添加。
UNIFI_API_KEY API 密钥(可选,实验性) UNIFI_PORT 控制器 HTTPS 端口 UNIFI_VERIFY_SSL SSL 证书验证 UNIFI_SITE UniFi 站点名称 说明为自动翻译,变量名保持原样;不确定时请查看原文。
菜单名称已于 2026年11月11日 对照 Cursor 帮助页面核实 · 你的界面可能因版本略有不同
可连接 VS Code,但需要先准备
需要 UniFi Network MCP 的密钥(在开发者网站创建) · 需要填写 1 项设置(UNIFI_HOST) · 需要先在电脑上安装 Python (uv)(只需一次)
把这段话复制到 VS Code 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。
请在这台电脑上为 VS Code 安装 MCP server UniFi Network MCP,按顺序:1) 用 uv --version 检查是否有 uv。没有的话,请让我从 https://docs.astral.sh/uv/getting-started/installation/ 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "servers": { "unifi-network": { "type": "stdio", "command": "uvx", "args": [ "unifi-network-mcp" ], "env": { "UNIFI_HOST": "your-value", "UNIFI_USERNAME": "your-value", "UNIFI_PASSWORD": "your-value" } } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) UNIFI_USERNAME, UNIFI_PASSWORD, UNIFI_HOST 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 UniFi Network MCP 的工具真的出现了。这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。
已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter
uv --versionMac:按 ⌘ + Space,输入 Terminal 后按 Enter
Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”
还没安装: uv 没有点选式安装程序。从 uv 官方页面复制适合你系统(macOS 或 Windows)的一行命令,粘贴到终端 · 不需要单独安装 Python,uv 会在需要时自动下载
装好后关掉终端再打开,重新运行同一条命令,应显示版本号: uv --version
安装一次,所有需要 uv 的工具都能用
打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。
获取密钥的方法见下方开发者的 README
这些是程序设置,不是密钥,无需注册。按开发者的说明填写。
UNIFI_HOST 控制器 IP 地址或主机名 说明为自动翻译,变量名保持原样;不确定时请查看原文。
在 UniFi Network MCP 的设置中,UNIFI_USERNAME, UNIFI_PASSWORD, UNIFI_HOST 还是空的,填入你的密钥并保存
只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人
用 UniFi Network MCP 告诉我你能帮我做什么,然后做一件给我看✓ 如果 VS Code 说正在使用 UniFi Network MCP,或回答中出现 UniFi Network MCP 的工具名称,就表示连接成功
上面的命令不填这些也能用。想调整时再按开发者的说明添加。
UNIFI_API_KEY API 密钥(可选,实验性) UNIFI_PORT 控制器 HTTPS 端口 UNIFI_VERIFY_SSL SSL 证书验证 UNIFI_SITE UniFi 站点名称 说明为自动翻译,变量名保持原样;不确定时请查看原文。
菜单名称已于 2026年11月11日 对照 VS Code 帮助页面核实 · 你的界面可能因版本略有不同
Claude Code
claude mcp add --scope user unifi-network --env UNIFI_HOST=your-value --env UNIFI_USERNAME=your-value --env UNIFI_PASSWORD=your-value -- uvx unifi-network-mcpClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"unifi-network": {
"command": "uvx",
"args": [
"unifi-network-mcp"
],
"env": {
"UNIFI_HOST": "your-value",
"UNIFI_USERNAME": "your-value",
"UNIFI_PASSWORD": "your-value"
}
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"unifi-network": {
"command": "uvx",
"args": [
"unifi-network-mcp"
],
"env": {
"UNIFI_HOST": "your-value",
"UNIFI_USERNAME": "your-value",
"UNIFI_PASSWORD": "your-value"
}
}
}
}VS Code (mcp.json)
{
"servers": {
"unifi-network": {
"type": "stdio",
"command": "uvx",
"args": [
"unifi-network-mcp"
],
"env": {
"UNIFI_HOST": "your-value",
"UNIFI_USERNAME": "your-value",
"UNIFI_PASSWORD": "your-value"
}
}
}
}UNIFI_HOST 必填 envUNIFI_USERNAME 机密 必填 envUNIFI_PASSWORD 机密 必填 envUNIFI_API_KEY 机密 envUNIFI_PORT envUNIFI_VERIFY_SSL envUNIFI_SITE env说明为自动翻译,变量名保持原样;不确定时请查看原文。
这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。
依据这个服务器的连接方式和各应用自己的文档,检查于 2026年11月10日。
在你的电脑上运行,适用于
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。
我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月19日
注册名称已通过 GitHub 账户 sirkirby 验证,该账户拥有此仓库
代码最后更新于前天
使用 MIT
它在你的电脑上运行,没有互联网端点
在你的电脑上运行,改用本地设置
它在你的电脑上运行;我们只能读取互联网端点的工具列表
OSV.dev 中没有 unifi-network-mcp@0.7.8 的记录
只检查这个版本的包本身,不包括所有依赖 · 检查于 2026年11月15日
如果你是作者,可把这段代码贴到 README。徽章会链接回本页。
[](https://mcp.popnx.com/en/servers/sirkirby-unifi-network-mcp)提问、分享技巧或报告无法使用。按“有帮助”数量排序。
还没有评价
与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。
它在 3 项适用的基础检查中通过了 3 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。
你需要填写:UNIFI_USERNAME, UNIFI_PASSWORD
它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。
GitHub 仓库最后更新于前天,最新版本(0.7.8)于8个月前进入注册中心。
支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Python (uv)。
同一分类中有:GitHits, Dependency Management MCP Server, Snyk MCP, TokenSafe, Draugr
同一分类、其他作者、命令已通过检查。官方的排在前面,再按星标排序。
如何看卡片:↓ 每周下载量i★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i
Search public open-source code, documentation, metadata, vulnerabilities, changelogs, and examples.
Sonatype component intelligence: versions, security analysis, and Trust Score recommendations
Easily find and fix security issues in your applications leveraging Snyk platform capabilities.
Your AI agent is smart enough to code all day. Local firewall & zero-loss runtime.
Security scanning for AI agents: SAST, SCA, secrets, IaC, DAST, ranked by real risk.
| 本项 UniFi Network MCP | GitHits | Dependency Management MCP Server | Snyk MCP | TokenSafe | Draugr | |
|---|---|---|---|---|---|---|
| 运行位置 | 需要安装在电脑上 | 云端或安装在电脑上都可以 | 在云端运行,无需安装 | 需要安装在电脑上 | 云端或安装在电脑上都可以 | 需要安装在电脑上 |
| 需要密钥 | 是 | 否 | 否 | 否 | 否 | 否 |
| 可在 Claude 中按 + 添加 | 否 | 否 | 否 | 否 | 否 | 否 |
| 基础检查 | 3/3 | 5/5 | 3/4 | 3/3 | 5/5 | 3/3 |
| 许可证 | MIT | Apache-2.0 | – | Apache-2.0 | MIT | Apache-2.0 |
| 价格 | 登记中未列出费用 | 登记中未列出费用 | 登记中未列出费用 | 登记中未列出费用 | 登记中未列出费用 | 登记中未列出费用 |
按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。
MCP server exposing 212 UniFi Network Controller tools for AI assistants and other MCP-capable clients. Query clients, devices, firewall rules, VLANs, VPNs, Traffic Flows, stats, and more with safe-by-default permissions and preview-before-confirm for all mutations.
Use this server when an existing AI assistant or other MCP-capable client needs UniFi Network tools. Software integrating over HTTP, including automation services, code-execution runtimes, and MCP adapters, should use unifi-api-server for REST and GraphQL reads, actions, and SSE events. The calling application must sandbox generated code and enforce its resource limits.
The plugin installs the MCP server, an agent skill for tool discovery, and a guided setup command:
/plugin marketplace add sirkirby/unifi-mcp
/plugin install unifi-network@unifi-plugins
Then run the interactive setup to configure your controller connection:
/unifi-network:unifi-network-setup
This walks you through entering your controller host, credentials, and permission preferences. Credentials are given as a file or command provider, never typed into chat. Setup saves the result as the plugin's Claude Code options, which apply in every project; a password or API key entered as an option is stored in the system keychain. Start a new Claude Code session after setup to connect.
Upgrading from a plugin version before 1.0.0, which kept settings in the project's .claude/settings.local.json? Follow the plugin upgrade guide.
Register the marketplace, then install unifi-network from Codex's /plugins UI:
codex plugin marketplace add sirkirby/unifi-mcp
After installing, ask Codex to use the UniFi Network setup skill. Setup saves a version-pinned MCP server entry with your controller settings in Codex's config.toml and prompts you to restart Codex. After each plugin upgrade, re-run setup with --refresh.
# PyPI
uvx unifi-network-mcp@latest
docker pull ghcr.io/sirkirby/unifi-network-mcp:latest
git clone https://github.com/sirkirby/unifi-mcp.git cd unifi-mcp && uv sync
For the approved breaking MAC argument rename in the next minor release, see the MAC parameter migration guide.
Once connected, just ask your AI agent in natural language:
"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"
"Which access points have the most client disconnections this week?"
"Audit my firewall policies — are there any redundant or conflicting rules?"
"Rename the device at 192.168.1.45 to 'Living Room TV' and show me its traffic stats"
"What changed on my network in the last 24 hours? Show me new clients and config changes."
"Show me the largest traffic flows from the last hour and summarize who talked to what."
All mutations (firewall rules, device changes, client blocking) use a preview-then-confirm flow — you see exactly what will change before anything is applied.
unifi_list_nat_rules and unifi_get_nat_rule read V2 NAT rules. The create, update, delete, and toggle tools require Network session credentials and use V2 NAT rule IDs; port-forward and Integration API IDs are different. Public writes cover DNAT, SNAT, and MASQUERADE with IPv4, tcp_udp or all, and NONE or ADDRESS_AND_PORT filters. Creates default to enabled=false. Created rules are marked manual and non-predefined, and both values are checked on readback. Existing rules with missing or non-manual origin are not editable through these tools. SNAT rules with a translated port require source_filter.port; the controller validates port correspondence. Existing rules missing that source port must be corrected in the same update before they can be edited through these tools. Toggle takes an explicit enabled boolean, so repeating the same request is a no-op. IPv6, PPPoE, inverted/excluded matching, and other filter variants are not verified for public writes. Selector edits on a stored rule with an unverified type are refused, even when the same request changes its type to a verified one.
The MCP update preview shows a fresh before/after merge. Confirmation reads fresh state again, sends at most one full replacement, then checks persistence; delete checks fresh absence. If the controller reply or readback is uncertain, list rules before retrying. A concurrent controller edit between fetch and PUT can be overwritten because V2 NAT has no conditional replacement. These checks prove stored configuration, not packet-level enforcement. Existing Core NAT methods retain their return shapes; controller mutation exceptions now carry safe fixed guidance instead of raw response text.
For an approved packet test, use the IPv4 DNS redirect recipe. It covers a single client and synthetic destination, including same-subnet return traffic and cleanup.
Set these variables in the server's process environment. The plugin setup skill already does this for Codex and OpenClaw; in Claude Code the plugin maps its options onto these variables. The server does not automatically load .env or working-directory YAML files; load a trusted env file explicitly in your launcher (Docker env_file: is supported), or select custom YAML with an absolute CONFIG_PATH. See configuration for migration examples.
With no controller host configured, the server still starts in setup mode: it tells the client how to configure it, offers only the read-only unifi_setup_status tool, and makes no controller connections.
# Server-specific variables (recommended)
UNIFI_NETWORK_HOST=192.168.1.1 # Controller IP or hostname UNIFI_NETWORK_USERNAME=admin # Local admin username UNIFI_NETWORK_PASSWORD=your-password # Admin password
Fallback: Existing UNIFI_* variables (e.g., UNIFI_HOST) continue to work. The server checks for UNIFI_NETWORK_* first and falls back to UNIFI_* if the server-specific variable is not set. For single-controller setups, the shared variables are all you need.
Configure UNIFI_NETWORK_API_KEY without a username/password for device, active-client, network, and WLAN lists. The same tools select the available read path; no duplicate API-key tools are needed. When valid session credentials are also configured, the existing session path remains preferred.
On controllers accepting API keys on legacy inventory endpoints, the usual IDs and fields are preserved. This was verified on Network 10.6.106 with a UniFi OS proxy; the minimum supported firmware is not established. Other controllers can use the public Integration inventory fallback when that API is available. Public inventory has narrower fields and network coverage (for example, WAN/VPN networks may be absent). Results identify source_api=integration and expose the public UUID as integration_id, never as a legacy resource ID. Do not pass these UUIDs to legacy details/update tools. Missing legacy fields are unknown. API GraphQL projections therefore allow null for unavailable enabled, wired, and guest flags; clients must handle those nulls.
Historical clients (include_offline=true), full details, legacy mutations, and the Network websocket still require their supported legacy/session paths. API-key legacy transport is restricted to verified inventory GET requests; successful reads do not imply permission to write. Explicit Integration tools such as DPI lookup and firewall ordering retain their own API-key contracts (legacy zone-ID resolution also needs a session). Protect still requires session bootstrap, with an additional API key for public setters; Access retains its independent API-token and proxy-session paths. Discovery reports local_only, api_key_only, either, or both; these describe requirements, not proof that a configured credential has authenticated successfully.
For tool results that already provide structured output, adaptive is the default response mode. It classifies each request by the canonical date-based protocolVersion advertised during MCP initialization, not by the client's product name or application version. Requests advertising MCP 2025-06-18 or later receive concise content plus the full result once in structuredContent; requests advertising an earlier revision (such as 2024-11-05 or 2025-03-26), or whose revision metadata is missing or malformed, keep full compatibility JSON in content. Set UNIFI_NETWORK_MCP_CONTENT_MODE to compat to force the duplicated compatibility form, or to compact to force concise text plus full structured output outside a negotiated request. This server-specific variable overrides UNIFI_MCP_CONTENT_MODE; use compat for any client that consumes the full result only from content, regardless of its advertised revision.
The lazy-loading meta-tools (*_tool_index, *_execute, *_batch, *_batch_status, and lazy-only *_load_tools) remain content-only; they are not the pre-2025-06-18 protocol category described above. For structured inner results, *_execute and *_batch_status expose one normalized JSON payload in content rather than a nested transport pair; content-only execute results remain unchanged. Response modes do not convert these meta-tools to structuredContent.
Network also bounds two large source responses by default: unifi_get_dashboard uses summary=true, and unifi_list_rogue_aps returns a summarized page of at most 100 records. Pass summary=false to request the full selected dashboard or rogue-AP data.
Network tools redact known secret-bearing fields by default before returning data to MCP clients. This includes WLAN passphrases, VPN key material, whole VPN config blobs, SNMP community strings, SNMPv3 passwords, and device-SSH credentials and the management key in raw/detail responses and mutation previews. Disable redaction for a trusted local administration process with UNIFI_NETWORK_REDACT_SENSITIVE_FIELDS=false or the global UNIFI_REDACT_SENSITIVE_FIELDS=false policy flag when raw values are required.
Confirmed Network/WLAN and VPN-state writes are re-read from the controller and report exact persisted_fields, unchanged_fields, dropped_fields, and coerced_fields. Already-satisfied no-op fields appear under unchanged_fields and do not make a failed write partially successful. A response with success: false and mutation_applied: true means the controller accepted the mutation but did not persist it exactly; it may be a partial write, not a rollback. Inspect partial_success and details_after_attempt before retrying or applying a compensa