zwave-alarm-client
Async Python client (aiohttp) for the REST API of the Z-Wave Alarm service. Used by the Home Assistant integration; contains no Home Assistant code.
import aiohttp
from zwave_alarm_client import async_get_panel_state, async_stream_events, InvalidAuth, CannotConnect
async with aiohttp.ClientSession() as session:
panel = await async_get_panel_state(session, "192.168.1.50", 3000, None)
async for event in async_stream_events(session, "192.168.1.50", 3000, None):
... # first event is a full `snapshot`, then `panel.changed`, `sensor.changed`, ...
Every call takes (session, host, port, token, ...); token is optional: pass None (no Authorization header is sent, so only host and port are needed); a non-empty value is sent as a bearer token. A cookie session from async_login also works with None. Pass secure=True for https/wss.
Coverage
| Area | Calls |
|---|---|
| Auth | async_login, async_logout |
| Panel | async_get_panel_state, async_validate_connection, async_arm, async_disarm (zone-restricted guests return a panel with disarmedZoneIds) |
| Zones & sensors | async_get_zones, async_create_zone, async_update_zone, async_delete_zone (force=), async_list_discoverable_sensors, async_assign_sensor, async_update_sensor, async_unassign_sensor |
| Users | async_list_users (ha_person_id= filter), async_create_user (code optional; guest expiry / guest_zone_id, ha_person_id, ha_user_id), async_update_user, async_delete_user |
| Codes (write-only) | async_set_user_code, async_clear_user_code; users expose only hasCode |
| Lockout policy | async_get_lockout_policy, async_update_lockout_policy |
| Events | async_get_events |
| HA links | async_create_ha_link, async_delete_ha_link |
| Keypads | async_list_keypads, async_chime_keypad |
| Push channel | async_stream_events (sends keepalive pings, drops pongs; reconnect policy is the caller's) |
Response shapes are available as TypedDicts in zwave_alarm_client.models.
Errors
All derive from ZwaveAlarmError: CannotConnect (unreachable, timeout, 5xx; ServiceUnavailable for 503), InvalidAuth (401), Forbidden (403), NotFound (404), BadRequest (400, message names the field), Conflict (409; CommandRejected for a lost arm/disarm race, ZoneNotEmpty, ZoneInUse, CodeInUse), AccountLocked (423), TooManyRequests (429, .retry_after).
Development
python -m venv .venv && . .venv/bin/activate
pip install -e '.[test]'
pytest
Commits follow Conventional Commits: fix releases a patch, feat a minor, BREAKING CHANGE/! a major. Releases are tagged and published to PyPI from main.
Metadata
Release files for zwave-alarm-client 0.4.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| zwave_alarm_client-0.4.2.tar.gz | 18.0 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| zwave_alarm_client-0.4.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 30.1 kB
Release files / zwave_alarm_client-0.4.2.tar.gz
| Download URL | zwave_alarm_client-0.4.2.tar.gz |
|---|---|
| Size | 18.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7ec8a51ee770bf29332891363c0dfe0d9383a4afddda197dd9132002fd445722
|
|
BLAKE2b-256 checksum How to use checksums |
09c3a9af2d7d0ea031d7475f2ea2949085e8efe3124771c941ab0c0b5d885260
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.
Transparency logRelease files / zwave_alarm_client-0.4.2-py3-none-any.whl
| Download URL | zwave_alarm_client-0.4.2-py3-none-any.whl |
|---|---|
| Size | 12.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
70c12a387bb8a8bb980a5ed00275f1180e2ece00b3885f19eae49891d2ebb4ba
|
|
BLAKE2b-256 checksum How to use checksums |
4ce977d2d7d2e1442c2447879e8bab99c5c217a972658cfad773a4a2faf4990a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.
Transparency logSecurity for zwave-alarm-client 0.4.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for zwave_alarm_client-0.4.2.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.