Mention event data structure when we talk about firing events (#682)

This commit is contained in:
Daniel Shokouhi 2020-10-15 03:28:15 -07:00 committed by GitHub
parent abb95d32cf
commit bd76a78d57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 4 deletions

View File

@ -142,7 +142,7 @@ Call a service in Home Assistant.
## Fire an event
Fire an event in Home Assistant.
Fire an event in Home Assistant. Please be mindful of the data structure as documented on our [Data Science portal](https://data.home-assistant.io/docs/events/#database-table).
```json
{

View File

@ -499,7 +499,7 @@ curl -X POST -H "Authorization: Bearer ABCDEFGH" \
#### POST /api/events/<event_type>
Fires an event with event_type
Fires an event with event_type. Please be mindful of the data structure as documented on our [Data Science portal](https://data.home-assistant.io/docs/events/#database-table).
You can pass an optional JSON object to be used as `event_data`.

View File

@ -63,7 +63,7 @@ Keep a new integration to the minimum functionality needed for someone to get va
### 6. Event names
Prefix component event names with the domain name. For example, use `netatmo_person` instead of `person` for the `netatmo` component.
Prefix component event names with the domain name. For example, use `netatmo_person` instead of `person` for the `netatmo` component. Please be mindful of the data structure as documented on our [Data Science portal](https://data.home-assistant.io/docs/events/#database-table).
### 7. Tests

View File

@ -10,7 +10,7 @@ The event system is very flexible. There are no limitations on the event type, a
## Firing events
To fire an event, you have to interact with the event bus. The event bus is available on the Home Assistant instance as `hass.bus`.
To fire an event, you have to interact with the event bus. The event bus is available on the Home Assistant instance as `hass.bus`. Please be mindful of the data structure as documented on our [Data Science portal](https://data.home-assistant.io/docs/events/#database-table).
Example component that will fire an event when loaded. Note that custom event names are prefixed with the component name.