uiprotect
Python API for Unifi Protect (Unofficial)
Decision gist · record as of 2026-08-14
Yes. The package is actively maintained, has no known vulnerabilities, carries a permissive MIT license, and low install friction. It is production-stable (Development Status 5) and well-suited for Home Assistant users or developers building UniFi Protect integrations. The primary constraint is the requirement for Python 3.11+, a POSIX system, and network access to a UniFi Protect 7.1+ instance; Windows users must use Docker or WSL.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.11+, a POSIX-compatible system (not Windows without Docker/WSL), and network access to a UniFi Protect instance running version 7.1 or later.
- Low friction install with a pure-Python wheel.
- Active maintenance with a recent release (30 days ago) and ongoing commits.
License · maintenance · safety
MIT (permissive) — MIT license permits commercial and private use with minimal restrictions, making it suitable for integration into Home Assistant and other projects without licensing concerns.
last release 2026-07-15 (30 days) · last repo commit 2026-08-14 · 101 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 111,088 downloads/mo, #12,434 on PyPI
Alternatives
Verify before relying
pip install uiprotect
from uiprotect import ProtectApiClient
protect = ProtectApiClient(host, port, username, password, verify_ssl=True)
await protect.update()
for camera in protect.bootstrap.cameras.values():
print(camera.name)- Stability of private API fallback when official Public Integration API does not cover a feature.
- Compatibility across different UniFi OS Console hardware models (CloudKey+, UNVR, Dream Machine variants).
- Performance characteristics under high-frequency WebSocket event loads.
What it is and what it does
uiprotect is an async Python library that communicates with UniFi Protect surveillance software running on Ubiquiti hardware (CloudKey+, UNVR, Dream Machine Pro/SE/Pro Max). It exposes both a programmatic API via ProtectApiClient and a command-line interface for managing cameras, events, sensors, lights, and other devices. The library is primarily designed for Home Assistant integration but can be used standalone.
The library increasingly relies on Ubiquiti's official Public Integration API where available, falling back to undocumented private APIs for features not yet exposed officially. It is built entirely on async/await patterns and communicates via WebSocket for real-time updates. Authentication supports both username/password and API-key modes, with public-only mode available for API-key-only workflows. Core dependencies include aiohttp for HTTP, PyAV for audio streaming to speakers, pydantic for data validation, and orjson for fast JSON parsing.
Use it for
- Integrate UniFi Protect cameras and events into Home Assistant for home automation workflows.
- Build custom monitoring dashboards or alerting systems that consume UniFi Protect events via WebSocket.
- Automate camera settings, recordings, or device management across multiple UniFi Protect instances.
- Export event logs or generate sample data for testing and analysis.
- Develop CLI tools to query NVR status, manage API keys, or control connected devices remotely.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
The package is actively maintained, has no known vulnerabilities, carries a permissive MIT license, and low install friction. It is production-stable (Development Status 5) and well-suited for Home Assistant users or developers building UniFi Protect integrations. The primary constraint is the requirement for Python 3.11+, a POSIX system, and network access to a UniFi Protect 7.1+ instance; Windows users must use Docker or WSL.
Install
uiprotect on PyPI
Before you install
Low friction install with a pure-Python wheel. Active maintenance with a recent release (30 days ago) and ongoing commits. Requires Python 3.11+ and a POSIX system; Windows requires Docker or WSL. PyAV dependency adds a compiled component but is pre-packaged.
Requires Python 3.11+, a POSIX-compatible system (not Windows without Docker/WSL), and network access to a UniFi Protect instance running version 7.1 or later.
License in practice
MIT license permits commercial and private use with minimal restrictions, making it suitable for integration into Home Assistant and other projects without licensing concerns.
Quickstart
pip install uiprotect
from uiprotect import ProtectApiClient
protect = ProtectApiClient(host, port, username, password, verify_ssl=True)
await protect.update()
for camera in protect.bootstrap.cameras.values():
print(camera.name)
Verify before relying
- Stability of private API fallback when official Public Integration API does not cover a feature.
- Compatibility across different UniFi OS Console hardware models (CloudKey+, UNVR, Dream Machine variants).
- Performance characteristics under high-frequency WebSocket event loads.
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release >=3.11 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 13 packagesaiofilesaiohttpaiozoneinfoavconvertertoolsorjsonpackagingplatformdirspropcachepydanticpydantic-extra-typespyjwtyarl |
| Maintenance | Actively maintained 30 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 111,088 / month, #12,434 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersNatural Language :: EnglishOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Software Development :: Build ToolsTopic :: Software Development :: Libraries |
Evidence: uiprotect-15.14.2-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “unifi protect api client”
- uiprotectProvides an async Python API and CLI for interacting with UniFi…
- aiounifiAsynchronous Python library for communicating with UniFi Network…
- py-unifi-accessAsync Python client for UniFi Access local API with WebSocket event…
Give your agent the search over MCP, or paste the wish link into any chat.
More Libraries packages
urllib3 is an HTTP client library that provides thread-safe connection pooling, SSL/TLS verification, multipart file uploads, request retries, compression support, and proxy handling for Python applications.
Requests is a Python HTTP library that simplifies sending HTTP/1.1 requests with automatic handling of headers, authentication, cookies, and response parsing.
Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.
Install it if you're building an extensible application or framework.
Provides parsing, arithmetic, and recurrence rule computation for dates and times, with timezone support and iCalendar RFC compliance.
Install it if you need to parse flexible date strings, compute relative dates, handle timezones, or work with recurrence rules—it's the de facto choice for these tasks.
Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.
pytest is a testing framework that lets you write test functions using plain assert statements and automatically discovers and runs them, with detailed failure reporting.
See also motioneye-client · py-unifi-access · reolink-aio · aiounifi · blinkpy · unifi-discovery · onvif-zeep-async · pytapo · simplisafe-python · total-connect-client