/unifi-network:unifi-networkfrom unifi-network
Build, debug and review integrations with Ubiquiti UniFi networks. Covers the official Network API, Site Manager API, Cloud Connector, and the classic controller API for device/client/site management.
Ships in unifi-network. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
| API | Base | Auth |
|---|---|---|
| Network API (official) | https://{console}/proxy/network/integration/v1/... | X-API-KEY, local key (Settings → Control Plane → Integrations) |
| Cloud Connector | https://api.ui.com/v1/connector/consoles/{consoleId}/proxy/network/integration/v1/... | X-API-KEY, Site Manager key (unifi.ui.com) |
| Site Manager | https://api.ui.com/v1/... | X-API-KEY, Site Manager key |
| Classic (unofficial) | UniFi OS: https://{console}/proxy/network/api/s/{site}/...; self-hosted: https://{host}:8443/api/s/{site}/... | Session cookie + CSRF |
GET /v1/info → applicationVersion). Read the spec for that version: https://developer.ui.com/network/v{version}/openapi.json. Do not assume an endpoint exists on older versions.References:
Official Network API
GET /v1/sites?filter=internalReference.eq('default') and cache. Never put default in an official path.offset + limit (default 25, max 200); response offset, limit, count, totalCount, data. Loop until offset >= totalCount or count == 0.prop.fn(args), and(...), or(...), not(...). Strings in single quotes, inner quote doubled. like uses *. Only the properties and functions listed for that endpoint are allowed. URL-encode.POST {action: ...}: device RESTART, port POWER_CYCLE, client AUTHORIZE_GUEST_ACCESS (timeLimitMinutes, dataUsageLimitMBytes, rxRateLimitKbps, txRateLimitKbps) and UNAUTHORIZE_GUEST_ACCESS./clients lists connected clients only.POST .../hotspot/vouchers needs name and timeLimitMinutes; count 1–1000. DELETE .../hotspot/vouchers?filter=... deletes in bulk.{statusCode, statusName, code, message, requestId}. Branch on statusCode/code; log requestId.Cloud Connector and Site Manager
pageSize + nextToken; envelope {data, httpStatusCode, traceId, nextToken}.429, wait Retry-After seconds. Never hard-code a request rate as if it were guaranteed.reportedState, meta, statistics change shape between versions; read them defensively.Classic API
GET / without redirects: 200 = UniFi OS (login /api/auth/login, prefix /proxy/network, cookie TOKEN, CSRF required); redirect = self-hosted (login /api/login, port 8443, cookie unifises).X-CSRF-Token from the login response header or the csrfToken claim in the TOKEN JWT; replace it if a response carries X-Updated-CSRF-Token. Send on every non-GET.api.err.Ubic2faTokenRequired → resend with ubic_2fa_token; UniFi OS SSO MFA → HTTP 499 → resend with token. Recommend a dedicated local admin without MFA.401/api.err.LoginRequired, re-login once and retry once. Never loop logins (429 AUTHENTICATION_FAILED_LIMIT_REACHED).meta.rc == "ok"; errors can arrive with HTTP 200. data is always an array. v2 endpoints have no envelope.default). Controller-wide paths (/api/self/sites, /api/stat/sites, /api/stat/admin) have no /s/{site}.POST cmd/stamgr (block-sta, unblock-sta, kick-sta, forget-sta with macs[], authorize-guest), cmd/devmgr (restart with macs[] + reboot_type, power-cycle with mac + port_idx, set-locate, adopt), cmd/hotspot (create-voucher), cmd/sitemgr, cmd/evtmgr, cmd/backup.stat/report start/end in ms; stat/session in seconds; within in hours. stat/event caps at 3000 rows.stat/report/*.site returns empty data; use /proxy/network/v2/api/stats/... after checking /v2/api/stats/source is MODERN.PUT rest/..., GET the object, change fields, send it back.wss://{console}/proxy/network/wss/s/{site}/events (self-hosted: :8443/wss/s/{site}/events) with the session cookie; reconnect and backfill on drop.Everywhere
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub uchkunr/unifi-best-practices --plugin unifi-networkOther plugins' skills for the same job