Agent skill

Homekit

by omarshahine in omarshahine/HomeClaw

Control HomeKit smart home accessories and view home events via homeclaw-cli.

MITAuto-check: notesMobile

Install Homekit

skills CLI
$ npx skills add omarshahine/HomeClaw --skill homekit -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install omarshahine/HomeClaw homekit --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/omarshahine/HomeClaw.git skills-src && mkdir -p .claude/skills && cp -r skills-src/openclaw/skills/homekit .claude/skills/homekit && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
homekit
GitHub stars
175
Token cost
~6.3k tokens
SKILL.md length
1,864 words
Files
1
Skills in repo
14
Repo updated
First seen
Licence
MIT

At a glance

Control HomeKit smart home accessories and view home events via homeclaw-cli.

  • Works in 5 steps: Install the Agent Workspace → Configure OpenClaw Hooks + Mappings → Configure HomeClaw Webhook → …
  • The user asks to control lights
  • SKILL.md covers Golden Rule: Device Map First, Resolving What the User Means, Commands and Device Types and What They…, plus 5 more sections
  • Calls openssl and python3; needs HOMECLAW_WEBHOOK_TOKEN

What it does

Homekit is an agent skill from omarshahine/HomeClaw. Control HomeKit smart home accessories and view home events via homeclaw-cli. Use when the user asks to control lights, locks, thermostats, fans, blinds, scenes, check device/sensor status, or view recent home activity/events. Examples: "turn off the stairs lights", "lock the front door", "what's the temperature", "run the movie scene", "close the blinds", "is the garage door open", "what happened at home today", "when was the front door last unlocked"

Its SKILL.md is about 6.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Mobile. The repository describes itself as: HomeKit smart home control via MCP — lights, locks, thermostats, and scenes for Claude Desktop, Claude Code, and OpenClaw. The licence is MIT.

When your agent uses it

  • The user asks to control lights
  • Check device/sensor status
  • View recent home activity/events

Example prompts

  • “turn off the stairs lights”
  • “lock the front door”
  • “s the temperature”
  • “/homekit”

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. Install the Agent Workspace
  2. Configure OpenClaw Hooks + Mappings
  3. Configure HomeClaw Webhook
  4. Create Triggers
  5. Verify

What it can do on your machine

Read from SKILL.md and the folder at commit da69700. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • openssl
    • python3

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • docs.openclaw.ai
    • github.com
    • justin.poehnelt.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • HOMECLAW_WEBHOOK_TOKEN

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Homekit loads about 6.3k tokens when it runs. Until then it costs about 116 tokens; SKILL.md has 1,864 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~116
When it runs · the whole SKILL.md, loaded when a task matches
~6.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NoteMentions a .env fileSKILL.md:344
    erate a token and add it to `~/.openclaw/.env`:
  • NoteMentions a .env fileSKILL.md:350
    # Add to .env
  • NoteMentions a .env fileSKILL.md:351
    _TOKEN=<generated-token>' >> ~/.openclaw/.env

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from omarshahine/HomeClaw at commit da69700, republished under its MIT licence (© omarshahine). 1,864 words, ~6,344 tokens.

Download SKILL.mdSave it as .claude/skills/homekit/SKILL.md (or your agent's skills folder).
name
homekit
description
Control HomeKit smart home accessories and view home events via homeclaw-cli. Use when the user asks to control lights, locks, thermostats, fans, blinds, scenes, check device/sensor status, or view recent home activity/events. Examples: "turn off the stairs lights", "lock the front door", "what's the temperature", "run the movie scene", "close the blinds", "is the garage door open", "what happened at home today", "when was the front door last unlocked"

HomeKit Control

Golden Rule: Device Map First

Before your first HomeKit action in a session, read memory/homekit-device-map.json.

This compact device map has every device as a flat list with display_name, id (UUID), room, type (semantic category), controls (writable characteristics), and state. It's optimized for fast LLM scanning and disambiguation.

Refresh the cache periodically or when devices may have changed:

bash
homeclaw-cli device-map --format agent -o memory/homekit-device-map.json

Resolving What the User Means

  1. Match user's words against display_name and room from the cached map
  2. Use type to disambiguate — lighting devices support brightness; power devices are on/off only. A "Closet Light" with type: power cannot dim.
  3. If ambiguous, prefer the device in the most likely room (main living areas > bedrooms > outdoor)
  4. If still ambiguous, ask
  5. Always use UUIDs for write operations — many devices share names (9 "Overhead" lights, multiple "Blinds"). Use display_name for reading, id (UUID) for set, import-scene, and automations create commands
  6. Check controls before sending a command — if brightness isn't in controls, don't try to set it
  7. If no match found, refresh the cache first — devices may have been added/renamed:
    bash
    homeclaw-cli device-map --format agent -o memory/homekit-device-map.json
    Then retry the match. Only tell the user "device not found" if it's still missing after refresh.

Commands

bash
# Discovery
homeclaw-cli device-map --format agent   # LLM-optimized flat list (default cache format)
homeclaw-cli device-map --format json      # Full detail with aliases, manufacturer
homeclaw-cli device-map --format md        # Markdown tables by room
homeclaw-cli device-map --home "<home>" --format agent  # Scope map to one home
homeclaw-cli search "<query>" --json       # Search by name/room/category
homeclaw-cli search "<query>" --home "<home>" --json
homeclaw-cli get "<name-or-uuid>" --json   # Full detail on one device
homeclaw-cli get "<name-or-uuid>" --home "<home>" --json
homeclaw-cli list --room "Kitchen" --json  # All devices in a room
homeclaw-cli list --home "<home>" --room "Kitchen" --json

# Control — always use UUID for reliability
homeclaw-cli set "<uuid>" power true                   # On/off
homeclaw-cli set "<uuid>" power true --home "<home>"   # Multi-home: pin the home
homeclaw-cli set "<uuid>" brightness 50                # Lights (0-100)
homeclaw-cli set "<uuid>" target_temperature 72        # Thermostat
homeclaw-cli set "<uuid>" target_heating_cooling auto  # HVAC: off/heat/cool/auto
homeclaw-cli set "<uuid>" lock_target_state locked     # Locks: locked/unlocked
homeclaw-cli set "<uuid>" target_position 100          # Blinds (0=closed, 100=open)

# Multi-gang switches — one accessory, several channels sharing a service type
homeclaw-cli set "<uuid>" power true --service-name "Pendentes"  # By service name
homeclaw-cli set "<uuid>" power true --service-id "<service-uuid>"  # By service UUID (names can repeat)
homeclaw-cli set "<uuid>" power true --service-index 2           # By channel number (ServiceLabelIndex)

# Scenes
homeclaw-cli scenes --json              # List all scenes
homeclaw-cli scenes --home "<home>" --json
homeclaw-cli get-scene "<name>" --json  # Full detail: all actions (accessory, room, characteristic, value)
homeclaw-cli trigger "<scene-name>"     # Run a scene
homeclaw-cli trigger "<scene-name>" --home "<home>"
homeclaw-cli import-scene scene.json --dry-run   # Preview scene import
homeclaw-cli import-scene scene.json              # Create scene from JSON
echo '{"name": "...", "actions": [...]}' | homeclaw-cli import-scene -   # Read JSON from stdin (works from any directory, sandbox-safe)
homeclaw-cli delete-scene "<name-or-uuid>" --dry-run   # Preview deletion
homeclaw-cli delete-scene "<name-or-uuid>"             # Delete a scene

# Room assignment — supports UUID for duplicate names
homeclaw-cli assign-rooms rooms.json --dry-run    # Preview room assignments
homeclaw-cli assign-rooms rooms.json              # Assign accessories to rooms
echo '[{"accessory": "...", "room": "..."}]' | homeclaw-cli assign-rooms -   # stdin also works here
# JSON format: bare array [{"uuid": "...", "room": "..."} or {"accessory": "...", "room": "..."}]
#              (or the same array wrapped as {"assignments": [...]})
# Use "uuid" when multiple accessories share the same name (e.g., ceiling fan + light)

# Management — rename, rooms, zones
homeclaw-cli rename "<name-or-uuid>" "<new-name>"           # Rename accessory
homeclaw-cli rename "<name-or-uuid>" "<new-name>" --dry-run # Preview rename
homeclaw-cli rename-room "<name-or-uuid>" "<new-name>"      # Rename room
homeclaw-cli create-room "<name>"                            # Create room
homeclaw-cli remove-room "<name-or-uuid>"                    # Remove room
homeclaw-cli remove-accessory "<name-or-uuid>"               # Remove accessory
homeclaw-cli create-zone "<name>"                            # Create zone
homeclaw-cli remove-zone "<name-or-uuid>"                    # Remove zone
homeclaw-cli add-room-to-zone "<room>" "<zone>"              # Add room to zone
homeclaw-cli remove-room-from-zone "<room>" "<zone>"         # Remove room from zone

# Automations (button programming)
homeclaw-cli automations list --json                          # List all automations
homeclaw-cli automations get "<name-or-uuid>" --json          # Detail view
homeclaw-cli automations delete "<name-or-uuid>" [--dry-run]
homeclaw-cli automations enable "<name-or-uuid>"
homeclaw-cli automations disable "<name-or-uuid>"

# Create with inline actions (creates a scene named after the automation)
# ALWAYS use UUIDs for target accessories to avoid name collisions
homeclaw-cli automations create --name "Sarah's Room Open" \
  --accessory "Office Button" \
  --action "BE21C139-413A-50F9-B97F-B9BDA06302A8:power:true" \
  --action "52195C6F-6FAA-5E52-AA56-840A6605EEAA:target_position:100" \
  --press single --service-index 1

# Create with a named scene
homeclaw-cli automations create --name "Movie Mode" \
  --accessory "Remote Button" \
  --scene "Movie Time" \
  --press single

# Press types: single (0), double (1), long (2)
# --action format: "UUID:property:value" (repeatable, UUID strongly preferred over names)
# --scene and --action are mutually exclusive
# Use --service-index for multi-button accessories (e.g., Aqara in fast mode)
# Note: inline actions create a visible scene (Apple uses a private API for hidden ones)

# Export to file (any format)
homeclaw-cli device-map --format agent -o memory/homekit-device-map.json
homeclaw-cli device-map --format md -o device-map.md

Device Types and What They Accept

The type field in the compact map tells you what a device IS. The controls array tells you exactly what you CAN set. Key distinctions:

TypeWhat It IsTypical Controls
lightingDimmable lightpower, brightness, sometimes hue, saturation, color_temperature
powerOn/off switch or smart plugpower only — no brightness
climateThermostat, heater, fireplacetarget_temperature, target_heating_cooling (off/heat/cool/auto)
door_lockLocklock_target_state (locked/unlocked)
window_coveringBlinds, shadestarget_position (0=closed, 100=open)
sensorTemp, humidity, motion, contact, leakRead-only — no writable controls
securityCameras, water shutoffVaries: active, power

Critical: A device named "Closet Light" or "Under Cabinet" with type: power is a relay switch. Sending brightness 50 will fail. Always check controls first.

Multi-Gang Switches and Multi-Button Remotes

Some accessories expose the same characteristic on several services: a 3-gang wall switch has three power characteristics, one per channel. Every channel reports the same service_type, so --service-type cannot pick one.

set refuses to guess. When a characteristic exists on more than one service it fails with an ambiguity error listing every candidate:

Ambiguous: 'power' exists on multiple services. Pass service_name, service_index, or service_id to pick one
(service_type is identical across channels on multi-gang accessories):
  - service_name: "Switch 1", service_index: 1, service_id: 5F2A..., service_type: 00000049-...
  - service_name: "Switch 2", service_index: 2, service_id: 91C7..., service_type: 00000049-...
  - service_name: "Pendentes", service_index: 3, service_id: B3E0..., service_type: 00000049-...

Passing selectors that match no service is a different error ("No service on '<name>' matches the given selectors") which lists the same candidates, so an over-constrained retry says so instead of claiming the characteristic doesn't exist.

Copy one of those selectors into the retry. homeclaw-cli get "<uuid>" --json lists the same id, name, and index per service if you want them before writing.

Confirming a Write Landed

set reads the characteristic back after writing and reports which service it hit:

json
{ "characteristic": "power", "value": "true", "verified": true,
  "service": { "id": "B3E0...", "name": "Pendentes", "type": "00000049-...", "index": 3 } }

If the device still reports the old value after a few re-reads, set fails rather than returning success. That is the point of the check: a write HomeKit accepted but the device ignored used to come back as success: true.

Write not applied: Wall Switch.Pendentes.power still reads false after writing true. Pass verify=false to accept unconfirmed writes.

When no verdict is possible the response carries verification_skipped instead: not_readable (a write-only characteristic), read_failed (the readback errored or timed out), or disabled (you passed --no-verify / verify: false). None of these mean the write failed, only that it could not be confirmed.

Use --no-verify for accessories whose readback is unreliable. Verification already retries a few times, so a device that acknowledges a write and publishes the new value a moment later is not flagged.

Event Log

HomeClaw logs all HomeKit events (characteristic changes, scene triggers, control actions) to disk. Query the event log to understand what happened recently:

bash
# Recent events (default: last 50)
homeclaw-cli events --json

# Events from the last hour
homeclaw-cli events --since 1h --json

# Only characteristic changes (e.g. lights turning on/off)
homeclaw-cli events --type characteristic_change --json

# Last 200 events
homeclaw-cli events --limit 200 --json

Event types: characteristic_change, scene_triggered, accessory_controlled, homes_updated

Use events to answer questions like "what changed recently?", "when was the front door last unlocked?", or "what scenes were triggered today?".

Webhook Integration

HomeClaw pushes HomeKit events to OpenClaw via webhooks, enabling a dedicated AI agent to observe, classify, and react to real-world events — a door unlocking, a leak sensor triggering, or a scene activating.

Known Issue: OpenClaw 2026.3.1/2026.3.2 has a bug where /hooks/wake silently drops events (#33271). HomeClaw uses mapped webhooks (/hooks/homeclaw) which route through hooks.mappings and are not affected.

Mapped Webhook Architecture

HomeClaw always POSTs to a single mapped endpoint: /hooks/homeclaw (configurable via webhookEndpoint in config.json). OpenClaw's hooks.mappings config resolves the "homeclaw" key and routes the event to the dedicated HomeClaw agent.

This means HomeClaw doesn't need to know about agentId, channel, deliver, model, or sessionKey — all routing intelligence lives in the OpenClaw config. HomeClaw just sends events; OpenClaw decides what to do with them.

Payload: {"text": "[label] event text", "mode": "now|next-heartbeat"} with Authorization: Bearer <token>, X-Request-ID (UUID), and X-Event-Timestamp (ISO8601) headers.

How Events Flow
Home app / physical switch / Siri / manufacturer app
        |
        v
HomeKit (HMAccessoryDelegate push notification)
        |
        v
HomeClaw event logger (writes to events.jsonl)
        |
        +-- Battery event? --> Logged to disk only (never sent via webhook)
        |
        +-- Trigger matches? --> POST /hooks/homeclaw
        |
        +-- No trigger --> Logged to disk only (no webhook sent)

        v  (trigger matched)
OpenClaw gateway validates Bearer token
        |
        v
hooks.mappings resolves "homeclaw"
        |
        v
HomeClaw Agent (dedicated)
        +-- Classifies: CRITICAL / NOTABLE / AMBIENT
        +-- If CRITICAL/NOTABLE: a2a message to main agent (Lobster)
        +-- If AMBIENT: log to agent memory only

HomeClaw subscribes to HomeKit push notifications for all interesting characteristics. Events fire for changes from any source — Home app, physical switches, Siri, manufacturer apps, and the CLI.

Dedicated HomeClaw Agent

A dedicated HomeClaw agent receives all webhook events and acts as an intelligent filter between your smart home and your main AI assistant:

  • Event classification — categorizes each event as CRITICAL (immediate alert), NOTABLE (worth reporting), or AMBIENT (log only)
  • Pattern correlation — correlates sequences of events (e.g., garage door + front door = arrival)
  • Memory building — learns your home's patterns over time (typical schedules, normal behaviors)
  • Read-only — the agent never controls devices, only observes and reports

Workspace files live in openclaw/agents/homeclaw/:

FilePurpose
AGENTS.mdAgent registration and capabilities
IDENTITY.mdAgent persona and behavioral guidelines
SOUL.mdEvent classification rules and triage logic
TOOLS.mdAvailable tools (read-only HomeKit queries via homeclaw-cli)

Install the agent workspace:

bash
openclaw agents install homeclaw /path/to/openclaw/agents/homeclaw
OpenClaw Configuration

Add the hooks block with a mappings entry to ~/.openclaw/openclaw.json:

json
"hooks": {
  "enabled": true,
  "token": "${HOMECLAW_WEBHOOK_TOKEN}",
  "mappings": {
    "homeclaw": {
      "agentId": "homeclaw",
      "sessionKey": "hook:homeclaw",
      "deliver": true,
      "channel": "last",
      "allowUnsafeExternalContent": true
    }
  },
  "internal": {
    "enabled": true,
    "entries": {
      "audit-logger": { "enabled": true }
    }
  }
}
FieldPurpose
agentIdRoutes to the dedicated HomeClaw agent
sessionKeyAll events share a persistent hook:homeclaw session
deliverAgent responses are delivered to a messaging channel
channel"last" uses the most recent active channel
allowUnsafeExternalContentPermits HomeKit event text in agent prompts

The mappings approach replaces the old defaultSessionKey + per-trigger action model. All routing decisions live in OpenClaw config, not in HomeClaw triggers.

End-to-End Setup
Step 1: Install the Agent Workspace
bash
openclaw agents install homeclaw /path/to/openclaw/agents/homeclaw

Verify the agent is registered:

bash
openclaw agents list
Step 2: Configure OpenClaw Hooks + Mappings

Add the hooks block (shown above) to ~/.openclaw/openclaw.json.

Generate a token and add it to ~/.openclaw/.env:

bash
# Generate a secure token
openssl rand -base64 24 | tr '+/' '-_' | tr -d '='

# Add to .env
echo 'HOMECLAW_WEBHOOK_TOKEN=<generated-token>' >> ~/.openclaw/.env

Restart the gateway: openclaw gateway restart

Step 3: Configure HomeClaw Webhook
bash
homeclaw-cli config --webhook-url "http://127.0.0.1:18789" \
                    --webhook-token "<same-token>" \
                    --webhook-enabled true

Or use HomeClaw Settings > Webhook. Toggle Enable, enter the base URL, and paste the token.

The webhookEndpoint defaults to /hooks/homeclaw. HomeClaw appends this to your base URL automatically.

Step 4: Create Triggers

Open HomeClaw Settings > Webhook. Check the scenes and accessories you want to fire webhooks. Start with security accessories (locks, garage doors, leak sensors) and a few lights to verify.

Triggers can also be managed via the CLI:

bash
# List current triggers
homeclaw-cli triggers

# Add a trigger for all state changes on an accessory
homeclaw-cli triggers add --label "Garage Door" --accessory-id "<uuid>"

# Add a trigger for a specific characteristic only
homeclaw-cli triggers add --label "Mailbox Open" --accessory-id "<uuid>" --characteristic contact_state

# Update a trigger's delivery mode
homeclaw-cli triggers update "<trigger-id>" --wake-mode now

# Remove a trigger
homeclaw-cli triggers remove "<trigger-id>"

Note: Battery-related characteristics (battery_level, low_battery) are automatically excluded from webhooks. They are still logged to the event log and cached for status queries, but never fire webhook triggers.

Show full SKILL.md (744 more words)Show less
Step 5: Verify
bash
# Check webhook health
homeclaw-cli status

# Toggle a light from the Home app, then check
homeclaw-cli events --since 5m

# Check delivery logs
log show --predicate 'process == "HomeClaw" AND category == "webhook"' --last 5m --style compact

Look for a System: line in the OpenClaw TUI, or check that the HomeClaw agent session (hook:homeclaw) shows incoming events.

Scenario Cookbook
Arrival Detection (Garage + Front Door Sequence)

Create triggers for both the garage door and front door. The HomeClaw agent correlates the sequence — garage opens, then front door unlocks within minutes — and reports an arrival to the main agent.

bash
homeclaw-cli triggers add --label "Garage Door" --accessory-id "<garage-uuid>"
homeclaw-cli triggers add --label "Front Door" --accessory-id "<lock-uuid>" --characteristic lock_current_state

The agent sees both events in its persistent session and recognizes the arrival pattern.

Suspicious Unlock Alert (Door Unlocked at 2am)

The HomeClaw agent classifies door unlocks by time of day. An unlock at 2am is CRITICAL; the same unlock at 6pm is NOTABLE. No special trigger config needed — the agent's classification logic handles it.

bash
homeclaw-cli triggers add --label "Front Door" --accessory-id "<lock-uuid>" --characteristic lock_current_state --value unlocked
Water Leak Emergency

Leak sensors should always fire immediately. The agent classifies any leak event as CRITICAL and sends an a2a alert to the main agent right away.

bash
homeclaw-cli triggers add --label "Kitchen Leak" --accessory-id "<leak-uuid>" --characteristic leak_detected --wake-mode now
Mailbox Opened

A contact sensor on the mailbox fires when opened. The agent classifies this as NOTABLE and reports it.

bash
homeclaw-cli triggers add --label "Mailbox" --accessory-id "<mailbox-uuid>" --characteristic contact_state
Bedtime Pattern (Good Night Scene)

Scene triggers capture when someone runs the Good Night scene. The agent logs it as AMBIENT and uses it to learn bedtime patterns over time.

bash
homeclaw-cli triggers add --label "Good Night" --scene-name "Good Night" --wake-mode now
Daily Activity Summary

The agent builds a daily summary from all events in its session. No special trigger config — just ensure your key accessories have triggers enabled. The agent can be prompted to summarize via a2a from the main agent.

Trigger Fields Reference
FieldTypeDefaultDescription
wake_modestring"next-heartbeat""now" (immediate) or "next-heartbeat" (batched, default)
labelstring—Human-readable name shown in webhook payload
accessory_idstring—UUID of the accessory to watch
characteristicstring—Specific characteristic to filter (omit for all)
valuestring—Only fire when characteristic equals this value
scene_namestring—Scene name to watch (alternative to accessory triggers)
criticalboolfalseBypasses circuit breaker when true

Deprecated fields (removed): action, agent_id, agent_prompt, agent_name, agent_deliver. These are no longer needed — all routing is handled by OpenClaw's hooks.mappings config.

Circuit Breaker
StateAfterBehaviorRecovery
Normal—All webhooks delivered—
Soft Open5 failuresNon-critical paused 5 minAuto-resumes
Hard Open3 soft tripsAll non-critical stoppedToggle webhook off/on in Settings

Critical triggers (critical: true) always bypass the circuit breaker.

Tips
  • Default delivery mode is next-heartbeat. Events batch into the next heartbeat cycle. Set wake_mode: "now" on triggers that need immediate delivery (leak sensors, door locks, scene triggers).
  • Start small. Enable triggers for a few key accessories first. Verify events appear in the HomeClaw agent session before adding more.
  • Use critical: true sparingly. It bypasses the circuit breaker. Reserve it for events that must never be silently dropped (leaks, security events). Overusing it defeats the circuit breaker's protection.
  • Triggers are additive. Multiple triggers can match the same event (e.g., an accessory trigger + a characteristic trigger). Each matched trigger fires its own webhook.
  • No catch-all. Only events matching a configured trigger fire webhooks. Untriggered events are logged to disk but not pushed.
  • Scene triggers match by name or UUID. Use scene UUID for precision, scene name for convenience (case-insensitive).
  • Characteristic + value filtering. A trigger with characteristic: "lock_current_state" and value: "unlocked" only fires on unlock, not on lock. Omit value to fire on any state change.
  • Check homeclaw-cli status --json for webhook health: circuit_state, last_success, last_failure, total_dropped.
  • The agent is read-only. It observes and reports but never controls devices. All device control goes through the main agent or direct CLI commands.

Agent-Friendly CLI

The CLI follows AI-agent best practices:

  • Auto-JSON: When stdout is not a TTY (piped or called by an agent), all commands output JSON automatically — no --json flag needed.
  • OUTPUT_FORMAT=json: Set this environment variable to force JSON output in all contexts.
  • --dry-run on mutations: set --dry-run validates the accessory, characteristic, and value without writing to the device. delete-scene --dry-run confirms the scene exists without deleting.
  • Input validation: Control characters (ASCII < 0x20) are rejected from all string arguments to defend against hallucinated inputs.
bash
# Dry run: validate without actuating
homeclaw-cli set "Front Door" lock_target_state locked --dry-run

# Force JSON from any context
OUTPUT_FORMAT=json homeclaw-cli status

Important Notes

  • Temperature values come back formatted: "71F". Set with plain numbers.
  • --json on read commands gives parseable output. Always use it when processing results.
  • Unreachable devices have "unreachable": true in the compact map.
  • If CLI fails with "HomeClaw is not running", the app needs to be launched first.
  • On-disk event log: ~/Library/Containers/com.shahine.homeclaw/Data/Library/Application Support/HomeClaw/events.jsonl
  • HomeClaw subscribes to HomeKit push notifications for all interesting characteristics on reachable accessories. Both Home app toggles and physical/external changes fire characteristic_change events.

Batch Operations

The compact map is flat — no nested traversal needed:

bash
# Find all reachable lights
python3 -c "
import json
d = json.load(open('memory/homekit-device-map.json'))
for dev in d['devices']:
    if dev['type'] == 'lighting' and not dev.get('unreachable'):
        print(dev['id'], dev['display_name'], dev['state'])
"

Then homeclaw-cli set "<uuid>" power false for each.

© omarshahine, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in openclaw/skills/homekit of omarshahine/HomeClaw.

Open the folder on GitHubat commit da69700

Compare with similar skills

Homekit next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Homekit compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Homekit this skillomarshahine/HomeClaw175—~6.3kAutomated safety check: NotesMIT
React Native Best Practicesvercel-labs/openreview1.7k17 repos~1.1kAutomated safety check: PassMIT
Swiftui Protwostraws/SwiftUI-Agent-Skill5.2k2 repos~1.5kAutomated safety check: PassMIT
Kortix Brandkortix-ai/suna20k—~4kAutomated safety check: PassCustom licence
Ip As LogoKartikLabhshetwar/better-shot2.4k1 repos~4.3kAutomated safety check: PassMIT
Compose Multiplatform Patternsmonta-app/ocpp-emulator1805 repos~2kAutomated safety check: PassApache-2.0

Similar skills

  • React Native Best Practices

    vercel-labs/openreview

    Official

    A prioritized rule set for React Native and Expo apps covering list performance, animation, navigation, UI patterns, state, rendering, monorepos and configuration.

    1.7k GitHub starsUsed in 17 repos~1.1k tokens
    MobileAuto-check passed
  • Swiftui Pro

    twostraws/SwiftUI-Agent-Skill

    Comprehensively reviews SwiftUI code for best practices on modern APIs, maintainability, and performance.

    5.2k GitHub starsUsed in 2 repos~1.5k tokens
    MobileAuto-check passed
  • Kortix Brand

    kortix-ai/suna

    Load FIRST for anything that carries the Kortix look or voice: product or mobile UI, copy of any kind, decks, social, images, email, CLI output, anything with the logo, and reviews of these.

    20k GitHub stars~4k tokensUpdated today
    MobileAuto-check passed
  • Ip As Logo

    KartikLabhshetwar/better-shot

    Generate extremely simple, cute, personified square character images with rounded heavy forms, two purposeful character colors, one solid background color, and a dominant lower-corner composition.

    2.4k GitHub starsUsed in 1 repo~4.3k tokens
    MobileAuto-check passed
  • Compose Multiplatform Patterns

    monta-app/ocpp-emulator

    Compose Multiplatform and Jetpack Compose patterns for KMP projects — state management, navigation, theming, performance, and platform-specific UI.

    180 GitHub starsUsed in 5 repos~2k tokens
    MobileAuto-check passed
  • Aso Appstore Screenshots

    adamlyttleapps/claude-skill-aso-appstore-screenshots

    Generate high-converting App Store screenshots by analyzing your app's codebase, discovering core benefits, and creating ASO-optimized screenshot images using Nano Banana Pro.

    1.8k GitHub starsUsed in 1 repo~9.6k tokens
    MobileAuto-check passed

More from omarshahine/HomeClaw

All 14 skills in this repo
  • Swiftui Expert Skill

    omarshahine/HomeClaw

    A skill your agent uses when writing, reviewing, or refactoring SwiftUI code for iOS or macOS, including state management, view composition, performance, Liquid Glass adoption, or Instruments .trace…

    175 GitHub starsUsed in 4 repos~2.8k tokens
    Auto-check passed
  • Spm Build Analysis

    omarshahine/HomeClaw

    Analyze Swift Package Manager dependencies, package plugins, module variants, and CI-oriented build overhead that slow Xcode builds.

    175 GitHub starsUsed in 1 repo~1.5k tokens
    Auto-check passed
  • Xcode Build Benchmark

    omarshahine/HomeClaw

    Benchmark Xcode clean and incremental builds with repeatable inputs, timing summaries, and timestamped .build-benchmark/ artifacts.

    175 GitHub starsUsed in 1 repo~1.2k tokens
    Auto-check passed
  • Xcode Build Fixer

    omarshahine/HomeClaw

    Apply approved Xcode build optimization changes following best practices, then re-benchmark to verify improvement.

    175 GitHub starsUsed in 1 repo~3.1k tokens
    Auto-check passed
  • Xcode Build Orchestrator

    omarshahine/HomeClaw

    Orchestrate Xcode build optimization by benchmarking first, running the specialist analysis skills, prioritizing findings, requesting explicit approval, delegating approved fixes to…

    175 GitHub starsUsed in 1 repo~2.9k tokens
    Auto-check passed
  • Xcode Compilation Analyzer

    omarshahine/HomeClaw

    Analyze Swift and mixed-language compile hotspots using build timing summaries and Swift frontend diagnostics, then produce a recommend-first source-level optimization plan.

    175 GitHub starsUsed in 1 repo~1.4k tokens
    Auto-check passed

Categories

Questions about Homekit

What does Homekit do?

Control HomeKit smart home accessories and view home events via homeclaw-cli. Homekit is an agent skill from omarshahine/HomeClaw. Control HomeKit smart home accessories and view home events via homeclaw-cli.

When should I use Homekit?

Homekit fits situations like: the user asks to control lights; check device/sensor status; view recent home activity/events.

How do I install Homekit in Claude Code?

Run `npx skills add omarshahine/HomeClaw --skill homekit -a claude-code`. Or copy the skill folder (openclaw/skills/homekit in omarshahine/HomeClaw) into .claude/skills/homekit in your project. Claude Code loads it when a task matches its description.

How do I install Homekit in Codex?

Run `npx skills add omarshahine/HomeClaw --skill homekit -a codex`. Or copy the skill folder (openclaw/skills/homekit in omarshahine/HomeClaw) into .agents/skills/homekit in your project. Codex loads it when a task matches its description.

Can I use Homekit in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add omarshahine/HomeClaw --skill homekit -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/homekit, .gemini/skills/homekit, .github/skills/homekit and .opencode/skills/homekit in your project.

What does Homekit need to run?

Going by SKILL.md and its folder, Homekit needs the command-line tools its instructions call (openssl and python3) and credentials named HOMECLAW_WEBHOOK_TOKEN.

Does Homekit access the network?

SKILL.md names 3 domains. As links in the text: docs.openclaw.ai, github.com and justin.poehnelt.com. This is read from the text; nothing was executed.

Is Homekit safe to install?

Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Homekit use?

Homekit is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Homekit use?

About 6.3k tokens (SKILL.md is roughly 25k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Homekit?

Skills that share tags, products or a category with Homekit: React Native Best Practices (vercel-labs/openreview, 1.7k stars), Swiftui Pro (twostraws/SwiftUI-Agent-Skill, 5.2k stars), Kortix Brand (kortix-ai/suna, 20k stars) and Ip As Logo (KartikLabhshetwar/better-shot, 2.4k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Homekit?

omarshahine (a GitHub user) maintains it in omarshahine/HomeClaw, which has 175 GitHub stars. The repository holds 14 skills in this directory. The repository was last updated on October 8, 2026.

Source: omarshahine/HomeClaw on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.