ha-integration-knowledge

A reference guide for building, testing, and reviewing Home Assistant integrations, which connect Home Assistant to devices and online services.

In plain words
What is it for?
Use it when examining or developing an integration, including its manifest, configuration flow, entities, tests, polling settings, and quality-scale requirements.
Why use it?
It provides project-specific patterns and restrictions, helping avoid common design and validation mistakes.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/home-assistant/core/ha-integration-knowledge
Any agent
npx skills add home-assistant/core --skill ha-integration-knowledge
Clone the repo
git clone --depth 1 https://github.com/home-assistant/core

Made for: Claude Code, Codex.

Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 739 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00038 $0.00739
Opus 5 $0.00019 $0.00369
Sonnet 5 $0.00008 $0.00148
Haiku 4.5 $0.00004 $0.00074

Measured today against content hash 705b99a5b85c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

ha-integration-knowledge scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/ha-integration-knowledge/SKILL.md · 49 lines

How it starts

The opening of the file, as written. The whole thing — 49 lines — stays where its author put it; the contents beside it link to each section on GitHub.

File Locations

  • Integration code: ./homeassistant/components/<integration_domain>/
  • Integration tests: ./tests/components/<integration_domain>/

General guidelines

  • When looking for examples, prefer integrations with the platinum or gold quality scale level first.
  • Polling intervals are NOT user-configurable. Never add scan_interval, update_interval, or polling frequency options to config flows or config entries.
  • Do NOT allow users to set config entry names in config flows. Names are automatically generated or can be customized later in UI. Exception: helper integrations may allow custom names.
  • For entity actions and entity services, avoid requesting redundant defensive checks for fields already enforced by Home Assistant validation schemas and entity filters; only request extra guards when values bypass validation or are transformed unsafely.
  • When validation guarantees a key is present, prefer direct dictionary indexing (data["key"]) over .get("key") so invalid assumptions fail fast.
  • Integrations should be thin wrappers. Protocol parsing, device state machines, or other domain logic belong in a separate PyPI library, not in the integration itself. If unsure, ask before inlining.
  • Integrations should not implement fixes or workarounds for limitations in libraries. Instead, the library should be updated to fix the issue.

The following platforms have extra guidelines:

Entity platforms

  • Ensure async_added_to_hass() and async_will_remove_from_hass() have symmetrical behavior. For example, if a subscription is created in async_added_to_hass(), it should be unsubscribed in async_will_remove_from_hass(). Also, if something is torn down in async_will_remove_from_hass(), it should be set up in async_added_to_hass().
  • Entity base class (e.g. SensorEntity, TrackerEntity) provide a stable API for child classes to inherit from. Do not suggest redeclaring or duplicating attributes, properties, or methods the base class already provides, and do not add guards against the parent's behavior changing — rely on the base class instead.

Read the full file on GitHub · 49 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today First seen · 49 lines · 38 tokens per session scan A 705b99a5b85c

Subscribe to this mod's changes

ha-integration-knowledge is a skill published in the GitHub repository home-assistant/core (90,198 stars, last pushed today), licensed Apache-2.0. It adds 38 tokens to every session and 739 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

iot-developer

Expert in IoT development, microcontrollers, sensors, and MQTT protocols.

daffy0208/ai-dev-standards · 18 tokens

edge-iot

Edge computing, IoT protocols, and embedded systems integration.

miles990/claude-software-skills · 15 tokens

acme-cse

Answer questions about the ACME oneM2M CSE open source project — installation, configuration, runtime options, protocol bindings, plugins, scripting, and development. Use this skill whenever the user asks anything about ACME CSE, oneM2M, acmecse, acme.ini, CSE setup, or running/configuring the ACME middleware, even if…

ankraft/ACME-oneM2M-CSE · 105 tokens

aether-iot-query

Use this skill when the user asks about a live AetherEdge runtime: channels, points, real-time values, history, alarms, rules, models, instances, routing, SHM health, service health, or system status. Use aether CLI commands to answer — do NOT inspect source code, local database files, or config YAMLs to answer…

EvanL1/AetherEdge · 82 tokens

aether-iot

Build, integrate, diagnose, or generate applications for the AetherEdge AI-native edge kernel. Use for AetherEdge onboarding, SDK compositions, device and topology clients, read-only operations UIs, MCP integration, Domain Packs, or governed IoT commands where live-state authority and physical-device safety must be…

EvanL1/AetherEdge · 68 tokens

devices-mcp-home

Live inventory of the user's smart home on this devices-mcp installation — cameras, Hue lights, Tapo P115 plugs, Netatmo weather, Ring, Nest Protect, Shelly sensors, and robots. Use when the user asks what devices they have, what's online, or wants a status summary before controlling hardware.

sandraschi/devices-mcp · 69 tokens