What problem does this solve?
When a helper or device is deleted, core.entity_registry sometimes retains a stale entry. There is currently no ha-mcp tool to remove an individual entity registry entry.
Why not existing tools?
- ha_config_remove_helper: removes the helper config entry, does not target the entity registry directly
- ha_remove_device: targets devices, not individual entity entries
- ha_set_entity(enabled=False): hides the entity, does not remove the registry entry
The API path
HA Core WebSocket:
type: config/entity_registry/remove
entity_id: <entity_id>
Implementation: registry.async_remove(entity_id) — no platform check, works for orphaned entries as long as entity_id exists in the registry.
Proposed tool
ha_remove_entity(entity_id: str)
- Sends config/entity_registry/remove via WebSocket
- Returns error if entity not found
- No HA restart required
Context
Came up in homeassistant-ai/skills#39, where direct .storage/ manipulation was proposed as a workaround. The right fix is a proper tool.
What problem does this solve?
When a helper or device is deleted, core.entity_registry sometimes retains a stale entry. There is currently no ha-mcp tool to remove an individual entity registry entry.
Why not existing tools?
The API path
HA Core WebSocket:
type: config/entity_registry/remove
entity_id: <entity_id>
Implementation: registry.async_remove(entity_id) — no platform check, works for orphaned entries as long as entity_id exists in the registry.
Proposed tool
ha_remove_entity(entity_id: str)
Context
Came up in homeassistant-ai/skills#39, where direct .storage/ manipulation was proposed as a workaround. The right fix is a proper tool.