--- id: pycontrol4 version: "2.0.2" license: unclear license_treatment: permissive maintenance: active --- # pyControl4 — Python 3 asyncio package for interacting with Control4 systems License: permissive · Maintenance: active · Downloads: 75.8K/mo ## What it is and what it does pyControl4 is an async Python library that bridges your code to Control4 smart home systems via their built-in REST API. It handles authentication (both account-level and controller-level bearer tokens), device discovery, and direct control of connected devices like lights. The library is built on aiohttp and websocket-client for non-blocking I/O, making it suitable for integration into async applications like Home Assistant. The package is actively maintained and known to work with Control4 OS 2.10.1.544795-res and OS 3.0+. It provides high-level classes (C4Account, C4Director, C4Light) that abstract the REST API details, so you authenticate once, query your controller's device list, and then send commands to individual devices. The official Home Assistant integration uses this library, indicating production readiness for that use case. Use it for: - Integrate Control4 device control into a Home Assistant or other home automation platform - Build custom automation scripts that query and control lights, switches, or other Control4 devices on a schedule - Discover all devices on a Control4 controller and expose them to a third-party dashboard or API - Implement scene triggering or device ramping (e.g., dimming lights over a time interval) from external applications ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. An async library for controlling Control4 smart home systems through their REST API, supporting device discovery, authentication, and direct control of lights and other connected devices. Yes, if you own a Control4 system and need programmatic control. The library is actively maintained, has no known vulnerabilities, and is already battle-tested in Home Assistant. Install friction is low. The main constraint is Python >=3.11 and network access to your Control4 controller; verify your controller's OS version matches the documented compatibility range. ## Install pip install pycontrol4 uv add pycontrol4 poetry add pycontrol4 ## Installing pyControl4 Before you install: Low install friction with a pure-Python wheel. Maintained actively with recent commits and no known vulnerabilities. Requires Python >=3.11 and four async-capable runtime dependencies (aiohttp, xmltodict, python-socketio-v4, websocket-client). License in practice: Licensed under Apache Software License (permissive), allowing commercial and private use with minimal restrictions. Quickstart: from pyControl4.account import C4Account from pyControl4.director import C4Director import asyncio account = C4Account(username, password) token = asyncio.run(account.get_account_bearer_token()) controllers = asyncio.run(account.get_account_controllers()) director = C4Director(ip, bearer_token) devices = asyncio.run(director.get_all_item_info()) Requires Python >=3.11; Control4 controller must be reachable on the local network and support the REST API. Verify before relying: - Whether the library works reliably with Control4 OS versions other than 2.10.1.544795-res and 3.0+ - Performance characteristics and concurrency limits when controlling many devices simultaneously - Whether all Control4 device types are supported or only a subset (lights are documented) ## Package facts - License: not declared (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 75.8K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags control4 home automation api, async control4 device control, control4 rest api client, smart home control4 integration, control4 light control python, home-automation, control4, async-io [View on SkillFed](https://skillfed.io/packages/pycontrol4) · [View on PyPI](https://pypi.org/project/pycontrol4/)