blueprint tutorial: rename 'service' to 'action' (#33800)

This commit is contained in:
c0ffeeca7 2024-07-16 16:39:13 +02:00 committed by GitHub
parent 5c0c9965ad
commit f6003f1a65
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -63,7 +63,7 @@ action:
The options that can be used with the `trigger` object are listed under [automation trigger variables](/docs/automation/templating/#available-trigger-data). The options that can be used with the `trigger` object are listed under [automation trigger variables](/docs/automation/templating/#available-trigger-data).
In this example, a [state trigger](/docs/automation/templating/#state) is used. In this example, a [state trigger](/docs/automation/templating/#state) is used.
`turn_on` and `turn_off` are [`homeassistant` services](/docs/scripts/service-calls/#homeassistant-services). They are not tied to a specific domain. You can use them on lights, switches, and other domains. `turn_on` and `turn_off` are [`homeassistant` actions](/docs/scripts/service-calls/#homeassistant-actions). They are not tied to a specific domain. You can use them on lights, switches, and other domains.
### Creating the blueprint file ### Creating the blueprint file
@ -96,7 +96,7 @@ trigger:
entity_id: !input motion_sensor entity_id: !input motion_sensor
``` ```
For the light, we can offer some more flexibility. We want to allow the user to be able to define any device or area as the target. The `target` property in the service action can contain references to areas, devices and/or entities, so that's what we will use. For the light, we can offer some more flexibility. We want to allow the user to be able to define any device or area as the target. The `target` property in the action can contain references to areas, devices, and/or entities, so that's what we will use.
Inputs are not limited to strings. They can contain complex objects too. So in this case, we're going to mark the whole `target` as input: Inputs are not limited to strings. They can contain complex objects too. So in this case, we're going to mark the whole `target` as input: