Call Event
ha_call_eventFire a custom event on the Home Assistant event bus to trigger event-driven automations, Node-RED flows, or custom integrations that subscribe to specific event types.
Instructions
Execute a custom event on the Home Assistant event bus.
When NOT to use: for controlling entities (lights, switches, climate) — use ha_call_service instead. To run an automation now, use ha_config_set_automation(entity_id=..., run_actions=True).
Use this to publish custom event types consumed by event-triggered automations, Node-RED flows, or custom integrations that subscribe to specific event types.
Caveats: Events are fire-and-forget; a successful dispatch reports the bus accepted the event and how many listeners were registered for it, not that any of them acted. A timeout means dispatch is unconfirmed. listener_count covers the exact event type; wildcard_listener_count covers match-all listeners (the recorder is one, and it only stores the event). The counts come from the component's dispatch reply when it serves the fire, otherwise from a GET /api/events lookup taken before dispatch; a route that cannot report them omits both fields.
The response carries the event's context_id (and context) when Home Assistant reports it. An automation triggered by this event records that id as the parent_id of its run's context, so looking up that automation trace proves whether a listener acted — which the counts cannot show, because an event trigger that filters on event_data still registers as a listener when the payload does not match.
Events fire in-process through the ha_mcp_tools component when it is installed, otherwise over Home Assistant's own WebSocket fire_event command; both carry the event type in the message body, so any type Core accepts fires as written and Core's rejection comes back as the error text (for example its 64-character event-type limit). state_changed alone keeps the REST route, because only that route rebuilds its old_state/new_state payloads into State objects; there event_type must be a plain name with no / \ ? # or % characters.
If a Claude Desktop user gets a 4-minute timeout with no result on this call, read the target back before repeating it, and tell them to wait a few seconds before clicking the manual-approve button, as clicking it too quickly is known to cause hangs in Claude Desktop. This workaround is specific to Claude Desktop.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"event_type": "<event_type>"
},
"name": "ha_call_event"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | Optional event payload, delivered to subscribers as the event's data (trigger.event.data in an automation). | |
| event_type | Yes | Event type to fire, e.g. 'my_custom_event'. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||