Loading...
Loading...
This skill should be used when the user asks to "manage UniFi devices", "configure UniFi networks", "create a VLAN", "provision an SSID", "create firewall rules", "reorder firewall policies", "create a NAT rule", "set up port forwarding", "configure masquerade NAT", "add DNS records", "manage traffic matching lists", "create DHCP reservations", "list DHCP reservations", "block a client", "kick a client", "find a client by IP or name", "adopt a device", "restart a UniFi device", "cycle a PoE port", "upgrade device firmware", "run a speed test", "stream UniFi events", "watch real-time events", "query UniFi stats", "analyze DPI traffic", "enable DPI", "generate hotspot vouchers", "show network topology", "audit firewall policies", "create a backup", "call the raw UniFi API", "check network health", or any task involving UniFi network infrastructure management via the unifly CLI. Also triggers on mentions of unifly, UniFi, Ubiquiti, UDM, UCG, USG, USW, UAP, UXG, UNVR, U6, U7, or UniFi controller operations.
npx skill4agent add hyperb1iss/unifly uniflyunifly events watchreorder --getreorder --setunifly api-p home-p officecommand -v unifly >/dev/null 2>&1 && unifly --version || echo "unifly not installed"brew install hyperb1iss/tap/uniflycargo install --git https://github.com/hyperb1iss/unifly.git uniflyunifly config initunifly config cloud-setupexamples/config.tomlevents watch| Mode | Credentials | What It Unlocks |
|---|---|---|
| API key | Integration API plus session HTTP on UniFi OS: CRUD, device commands, stats, reservations, admin, event list |
| Username + password | Session HTTP + WebSocket only: events watch, stats, device commands, DPI control, admin, backups, NAT policies, firewall groups, switch port config-as-code, site settings |
| API key + username/pass | Everything above, including session WebSocket plus enriched records with maximum controller compatibility |
| Site Manager API key | Connector-routed Integration CRUD plus |
events watchsessionhybridreferences/concepts.mdunifly [global-flags] <command> <action> [args]| Command | Aliases | Actions |
|---|---|---|
| | list, get, adopt, remove, restart, locate, port-cycle, ports, ports-export, port-set, stats, pending, upgrade, provision, speedtest, tags |
| | list, find, get, roams, wifi, authorize, unauthorize, block, unblock, kick, forget, reservations ( |
| hosts [get], sites, switch, devices, isp [query], sdwan [get, status] | |
| | list, get, create, update, delete, refs |
| | list, get, neighbors, channels, create, update, delete |
| | policies {list, get, create, update, patch, delete, reorder}, zones {list, get, create, update, delete}, groups {list, get, create, update, delete} |
| policies {list, get, create, update, delete} | |
| list, get, create, update, delete, reorder | |
| list, get, create, update, delete | |
| list, get, create, update, delete | |
| list, get, create, delete, purge | |
| list, watch | |
| list, archive, archive-all | |
| site, device, client, gateway, dpi | |
| apps, categories, status, enable, disable | |
| | (no subcommands) |
| | info, health, sysinfo, backup {create, list, download, delete}, reboot, poweroff |
| list, get, set, export | |
| list, create, delete | |
| list, invite, revoke, update | |
| list | |
| servers [get], tunnels [get], status, health, site-to-site {list, get, create, update, delete}, remote-access {list, get, create, update, suggest-port, download-config, delete}, clients {list, get, create, update, delete}, connections {list, get, restart}, peers {list, get, create, update, delete, subnets}, magic-site-to-site {list, get}, settings {list, get, set, patch} | |
| profiles | |
| (no subcommands) | |
| Raw API passthrough (GET/POST/PUT/PATCH/DELETE any path) | |
| init, cloud-setup, show, set, profiles, use, set-password, theme | |
| (no subcommands) | |
| bash, zsh, fish, powershell, elvish |
references/commands.md--help--output-o| Format | Flag | Use Case |
|---|---|---|
| | Human display (default) |
| | Agent processing, pipe to |
| | Single-line JSON for scripting |
| | Config file output |
| | One ID per line for |
-o jsonjqtablereferences/workflows.md--from-file--from-file <path.json>-Fnetworkswififirewall policiesfirewall zonesfirewall groupsnat policiesacldnstraffic-listsvpn site-to-sitevpn remote-accessvpn clientsvpn peersvpn settings patchdevices port-setexamples/unifly networks create -F examples/network-iot-vlan.json
unifly firewall policies create -F examples/firewall-block-iot.json# All events
unifly events watch
# Filter by EventCategory (case-insensitive): Device, Client, Network,
# System, Admin, Firewall, Vpn, Unknown
unifly events watch --types "Firewall,Admin"
# JSON stream for piping into alerting (severity serializes PascalCase)
unifly events watch --types Client -o json | jq -c 'select(.severity == "Warning")'# Read current order for a zone pair
unifly firewall policies reorder --source-zone <zid> --dest-zone <zid> --get
# Write back an explicit order
unifly firewall policies reorder --source-zone <zid> --dest-zone <zid> \
--set "<id1>,<id2>,<id3>"unifly apiunifly api "v2/api/site/default/traffic-flow-latest-statistics"
unifly api "cmd/stamgr" -m post -d '{"cmd":"kick-sta","mac":"aa:bb:cc:dd:ee:ff"}'
unifly api "api/s/default/set/setting/teleport" -m put -d '{"enabled":true}'unifly vpn site-to-siterest/networkconfpurposesite-vpnunifly vpn site-to-site list -o json
unifly vpn site-to-site get <id> -o json
unifly vpn site-to-site create -F site-to-site.json
unifly vpn site-to-site update <id> -F site-to-site.json
unifly vpn site-to-site delete <id>unifly vpn remote-accessrest/networkconfpurposeremote-user-vpnunifly vpn remote-access list -o json
unifly vpn remote-access get <id> -o json
unifly vpn remote-access create -F remote-access.json
unifly vpn remote-access update <id> -F remote-access.json
unifly vpn remote-access suggest-port -o json
unifly vpn remote-access download-config <id> --path .
unifly vpn remote-access delete <id>unifly vpn clientsrest/networkconfpurposevpn-clientunifly vpn clients list -o json
unifly vpn clients get <id> -o json
unifly vpn clients create -F vpn-client.json
unifly vpn clients update <id> -F vpn-client.json
unifly vpn clients delete <id>unifly vpn peerslistcreateupdatedeleteunifly vpn peers list -o json
unifly vpn peers list <server-id> -o json
unifly vpn peers get <server-id> <peer-id> -o json
unifly vpn peers create <server-id> -F peer.json
unifly vpn peers update <server-id> <peer-id> -F peer.json
unifly vpn peers delete <server-id> <peer-id>
unifly vpn peers subnets -o jsonunifly vpn connectionsv2/api/site/<site>/vpn/connectionsrestartunifly vpn connections list -o json
unifly vpn connections get <id> -o json
unifly vpn connections restart <id>unifly vpn magic-site-to-sitemagicsitetositevpn/configsunifly vpn magic-site-to-site list -o json
unifly vpn magic-site-to-site get <id> -o jsonunifly vpn settingsrest/settingteleportmagic-site-to-site-vpnopenvpnpeer-to-peerunifly vpn settings list -o json
unifly vpn settings get peer-to-peer -o json
unifly vpn settings set teleport --enabled true
unifly vpn settings patch peer-to-peer -F peer-to-peer.jsonsite-to-site getremote-access getclients getconnections getpeers getmagic-site-to-site getfieldssettings getkeyenabledfieldspatchfieldshotspot purge --filterunifly hotspot purge --filter "status.eq('UNUSED')"
unifly hotspot purge --filter "name.contains('Conference')"# Agent inspects, proposes. Human runs unifly tui and verifies on
# screen 4 (Networks) or 5 (Firewall) before the agent applies the change.
unifly tuiunifly -p home devices list
unifly -p office firewall policies list
UNIFI_PROFILE=warehouse unifly system healthclients roams--all--limit 200UNIFI_UNIFLY_UNIFI_URLUNIFI_API_KEYUNIFI_USERNAMEUNIFI_PASSWORDUNIFI_SITEUNIFI_PROFILEUNIFI_OUTPUTUNIFI_INSECUREUNIFI_TIMEOUTUNIFI_TOTPUNIFI_HOST_IDUNIFI_DEMOUNIFLY_*UNIFLY_THEME--yes-yevents watchunifly cloud ...auth_mode = "cloud"0--outputID=$(unifly networks create ... -o json | jq -r .id)-o plainsites createsystem backup createcommand -v uniflyunifly config showunifly system health -o jsonlistget--from-fileget--yesreferences/commands.mdreferences/concepts.mdreferences/workflows.mdexamples/config.tomlexamples/network-iot-vlan.json--from-fileexamples/firewall-block-iot.jsonexamples/nat-masquerade.jsonexamples/nat-port-forward.jsonexamples/wifi-iot.jsonexamples/vpn-remote-access-wireguard.jsonexamples/vpn-site-to-site-ipsec.jsonexamples/vpn-client-openvpn.jsonexamples/vpn-wireguard-peer.jsonexamples/switch-ports.jsoncdevices port-set -F