YAML examples: rename 'service' to 'action' (#34064)

This commit is contained in:
c0ffeeca7 2024-08-02 12:21:56 +02:00 committed by GitHub
parent fa61ff16c9
commit 9e0d048e42
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 21 additions and 21 deletions

View File

@ -140,8 +140,8 @@ type: button
name: Turn Off Lights name: Turn Off Lights
show_state: false show_state: false
tap_action: tap_action:
action: call-service action: perform-action
service: script.turn_on perform_action: script.turn_on
data: data:
entity_id: script.turn_off_lights entity_id: script.turn_off_lights
``` ```

View File

@ -426,8 +426,8 @@ entities:
name: Bed light transition name: Bed light transition
action_name: Toggle light action_name: Toggle light
tap_action: tap_action:
action: call-service action: perform-action
service: light.toggle perform_action: light.toggle
data: data:
entity_id: light.bed_light entity_id: light.bed_light
transition: 10 transition: 10
@ -458,8 +458,8 @@ entities:
name: Power cycle LibreELEC name: Power cycle LibreELEC
icon: mdi:power-cycle icon: mdi:power-cycle
tap_action: tap_action:
action: call-service action: perform-action
confirmation: confirmation:
text: Are you sure you want to restart? text: Are you sure you want to restart?
service: script.libreelec_power_cycle perform_action: script.libreelec_power_cycle
``` ```

View File

@ -135,8 +135,8 @@ type: picture-entity
entity: camera.backdoor entity: camera.backdoor
camera_view: live camera_view: live
tap_action: tap_action:
action: call-service action: perform-action
service: camera.snapshot perform_action: camera.snapshot
data: data:
entity_id: camera.backdoor entity_id: camera.backdoor
filename: '/shared/backdoor-{{ now().strftime("%Y-%m-%d-%H%M%S") }}.jpg' filename: '/shared/backdoor-{{ now().strftime("%Y-%m-%d-%H%M%S") }}.jpg'

View File

@ -197,35 +197,35 @@ If your camera supports <abbr title="pan, tilt, and zoom">PTZ</abbr> (can be mov
- entity: button.camera1_ptz_left - entity: button.camera1_ptz_left
icon: mdi:pan-left icon: mdi:pan-left
tap_action: tap_action:
action: call-service action: perform-action
service: button.press perform_action: button.press
data: data:
entity_id: button.camera1_ptz_left entity_id: button.camera1_ptz_left
- entity: button.camera1_ptz_right - entity: button.camera1_ptz_right
icon: mdi:pan-right icon: mdi:pan-right
tap_action: tap_action:
action: call-service action: perform-action
service: button.press perform_action: button.press
data: data:
entity_id: button.camera1_ptz_right entity_id: button.camera1_ptz_right
- entity: button.camera1_ptz_up - entity: button.camera1_ptz_up
icon: mdi:pan-up icon: mdi:pan-up
tap_action: tap_action:
action: call-service action: perform-action
service: button.press perform_action: button.press
data: data:
entity_id: button.camera1_ptz_up entity_id: button.camera1_ptz_up
- entity: button.camera1_ptz_down - entity: button.camera1_ptz_down
icon: mdi:pan-down icon: mdi:pan-down
tap_action: tap_action:
action: call-service action: perform-action
service: button.press perform_action: button.press
data: data:
entity_id: button.camera1_ptz_down entity_id: button.camera1_ptz_down
camera_image: camera.camera1_sub camera_image: camera.camera1_sub
tap_action: tap_action:
action: call-service action: perform-action
service: light.toggle perform_action: light.toggle
target: target:
entity_id: light.philips_929003052501_01_huelight entity_id: light.philips_929003052501_01_huelight
``` ```

View File

@ -80,8 +80,8 @@ Toggle entity using an action:
type: picture type: picture
image: /local/light.png image: /local/light.png
tap_action: tap_action:
action: call-service action: perform-action
service: light.toggle perform_action: light.toggle
data: data:
entity_id: light.ceiling_lights entity_id: light.ceiling_lights
``` ```

View File

@ -41,7 +41,7 @@ Once the Home Assistant Container is running Home Assistant should be accessible
If you change the configuration, you have to restart the server. To do that you have 3 options. If you change the configuration, you have to restart the server. To do that you have 3 options.
1. In your Home Assistant UI, go to the **Settings** > **System** and click the **Restart** button. 1. In your Home Assistant UI, go to the **Settings** > **System** and click the **Restart** button.
2. You can go to the **Developer Tools** > **Actions**, select the service `homeassistant.restart` and select **Perform action**. 2. You can go to the **Developer Tools** > **Actions**, select `homeassistant.restart` and select **Perform action**.
3. Restart it from a terminal. 3. Restart it from a terminal.
{% tabbed_block %} {% tabbed_block %}