HomeKit integration for MajorDom — bridges HomeKit accessories into the MajorDom language.
Project description
integration-homekit
A MajorDom integration — bridges Apple HomeKit accessories into the MajorDom language.
Built for the MajorDom Hub, but it doesn't need it: this is a standalone, standardized
library for HomeKit that you can use on its own (see Run it standalone below). Built on the
MajorDom Integration SDK. The entry point
is HomeKitController (majordom_homekit/controller.py), which the Hub — or the SDK's dev runner —
instantiates and drives through its lifecycle: discovery → pairing → commands → teardown.
- Other protocols: browse the MajorDom integrations.
- Create your own: start from the integration template.
Documentation
Full integration-author docs — the controller lifecycle, data models, storing data, discovery, and a worked example — live at docs.majordom.io.
Development
poetry install && poetry run poe install
| Task | Description |
|---|---|
poe check |
Full quality pipeline (ruff, ty, pytest, poetry build/check) |
poe check --ci |
Same, plus git diff --exit-code |
Work lands on develop; master is protected and released via Actions → Release. Tests drive
the controller with the SDK's test doubles against an in-process fake HAP accessory server — no real
accessory required (see tests/).
Run it standalone (without the Hub)
majordom-homekit is a standalone library — import it into your own app, or run just this
integration interactively (discover, pair, control, and inspect devices from a prompt) with no Hub.
It discovers IP accessories over mDNS (BLE accessories need a BLE adapter); no external service is
required.
See Standalone mode for the interactive CLI, watch mode, and the programmatic API.
About this integration
- Protocol / platform: Apple HomeKit Accessory Protocol (HAP) via the
parker-aiohomekitfork ofaiohomekit. - Transport(s): IP (Wi-Fi / Ethernet, discovered via mDNS); BLE for BLE accessories.
- Supported devices: HomeKit-compatible accessories — lights, plugs, switches, sensors, locks.
- Credentials needed to pair:
code(the accessory's 8-digit HomeKit setup code).
Required harness
- Hardware adapters: a BLE adapter only if pairing BLE accessories; IP accessories need none.
- Third-party software services: none —
aiohomekitspeaks HAP directly. - OS / permissions: mDNS on the LAN for discovery; BLE access for BLE accessories.
Protocol stack (OSI)
| OSI layer | Protocol | Implemented by |
|---|---|---|
| Application (7) | HAP characteristics / services | this integration (via aiohomekit) |
| Session (5) | Pair-Setup / Pair-Verify (SRP, Ed25519) | library (aiohomekit) |
| Transport (4) | TCP (IP) / GATT (BLE) | OS |
| Network + below (1–3) | IP over Wi-Fi / Ethernet (or BLE) | OS |
Progress
- Discovery services registered (mDNS via
zeroconf_discovery_service; BLE where applicable); cancel closures called instop - Discovery listeners fire and call
controller_did_receive_discovery - Re-discovery of already-paired accessories on reconnect (
controller_did_connect_device) - Device pairing (HAP pair-setup with the setup code)
- Device schema mapped: services/characteristics → parameter list with per-parameter metadata
- Hub → Device control (
send_command) - Device → Hub event subscription (
controller_did_receive_events) -
identify -
unpair -
fetch - Availability tracking while running (
controller_did_lose_device/last_error) - Graceful shutdown in
stop - Tests pass against a fake HAP accessory server (
tests/)
Notes
Uses the parker-aiohomekit fork of aiohomekit; note its Python upper bound (<3.14).
License
See LICENSE. For commercial licensing or partnership inquiries regarding MajorDom, contact us via parker-industries.org/partnership.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file majordom_homekit-0.1.4.tar.gz.
File metadata
- Download URL: majordom_homekit-0.1.4.tar.gz
- Upload date:
- Size: 16.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1d49c5a37e204592970024e138a4838269507d9fb9b8c658653489cfe15be4fe
|
|
| MD5 |
0283934834d5d78d55200815aaf3db36
|
|
| BLAKE2b-256 |
660effe8ad70ec0fb8cef202f75a76d136ca8f87d7b0845b795a2f17f7c537a7
|
Provenance
The following attestation bundles were made for majordom_homekit-0.1.4.tar.gz:
Publisher:
release.yml on MajorDom-Systems/integration-homekit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
majordom_homekit-0.1.4.tar.gz -
Subject digest:
1d49c5a37e204592970024e138a4838269507d9fb9b8c658653489cfe15be4fe - Sigstore transparency entry: 2221279673
- Sigstore integration time:
-
Permalink:
MajorDom-Systems/integration-homekit@6865891306412a994c0a227b7fadc9784e16d7a8 -
Branch / Tag:
refs/heads/develop - Owner: https://github.com/MajorDom-Systems
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@6865891306412a994c0a227b7fadc9784e16d7a8 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file majordom_homekit-0.1.4-py3-none-any.whl.
File metadata
- Download URL: majordom_homekit-0.1.4-py3-none-any.whl
- Upload date:
- Size: 17.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
93e340da776d451282f18cb06f9296c20d55e71949a2ef88c39f981545c3a8d5
|
|
| MD5 |
66141ad445527979a2bf0ffcc9b4d421
|
|
| BLAKE2b-256 |
2b3be77070c1a71efb4887d1f8f476ef560cca1ccfb492135661d9162864a784
|
Provenance
The following attestation bundles were made for majordom_homekit-0.1.4-py3-none-any.whl:
Publisher:
release.yml on MajorDom-Systems/integration-homekit
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
majordom_homekit-0.1.4-py3-none-any.whl -
Subject digest:
93e340da776d451282f18cb06f9296c20d55e71949a2ef88c39f981545c3a8d5 - Sigstore transparency entry: 2221280330
- Sigstore integration time:
-
Permalink:
MajorDom-Systems/integration-homekit@6865891306412a994c0a227b7fadc9784e16d7a8 -
Branch / Tag:
refs/heads/develop - Owner: https://github.com/MajorDom-Systems
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@6865891306412a994c0a227b7fadc9784e16d7a8 -
Trigger Event:
workflow_dispatch
-
Statement type: