mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-23 17:27:19 +00:00
Update some service calls to use target (#16586)
This commit is contained in:
parent
ea1eb577a6
commit
81d0265f1b
@ -62,11 +62,11 @@ script:
|
|||||||
sequence:
|
sequence:
|
||||||
- alias: "Alarm Room1 Start"
|
- alias: "Alarm Room1 Start"
|
||||||
service: homeassistant.turn_on
|
service: homeassistant.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: switch.AlmSnd1
|
entity_id: switch.AlmSnd1
|
||||||
- alias: "Set Ack Room1"
|
- alias: "Set Ack Room1"
|
||||||
service: homeassistant.turn_on
|
service: homeassistant.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: input_boolean.ack1
|
entity_id: input_boolean.ack1
|
||||||
- alias: "email_Room1"
|
- alias: "email_Room1"
|
||||||
service: notify.email
|
service: notify.email
|
||||||
@ -77,7 +77,7 @@ script:
|
|||||||
seconds: 60
|
seconds: 60
|
||||||
- alias: "Alarm Room1 Stop"
|
- alias: "Alarm Room1 Stop"
|
||||||
service: homeassistant.turn_off
|
service: homeassistant.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: switch.AlmSnd1
|
entity_id: switch.AlmSnd1
|
||||||
|
|
||||||
flash_room1:
|
flash_room1:
|
||||||
@ -85,18 +85,18 @@ script:
|
|||||||
sequence:
|
sequence:
|
||||||
- alias: "Light Room1 On"
|
- alias: "Light Room1 On"
|
||||||
service: homeassistant.turn_on
|
service: homeassistant.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: switch.REL1
|
entity_id: switch.REL1
|
||||||
- delay:
|
- delay:
|
||||||
# time for flash light on
|
# time for flash light on
|
||||||
seconds: 1
|
seconds: 1
|
||||||
- alias: "Light Room1 Off"
|
- alias: "Light Room1 Off"
|
||||||
service: homeassistant.turn_off
|
service: homeassistant.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: switch.REL1
|
entity_id: switch.REL1
|
||||||
- alias: "loop_room1"
|
- alias: "loop_room1"
|
||||||
service: script.turn_on
|
service: script.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: script.flash_loop
|
entity_id: script.flash_loop
|
||||||
|
|
||||||
flash_loop:
|
flash_loop:
|
||||||
@ -107,7 +107,7 @@ script:
|
|||||||
seconds: 1
|
seconds: 1
|
||||||
- alias: "loop_room1"
|
- alias: "loop_room1"
|
||||||
service: script.turn_on
|
service: script.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: script.flash_room1
|
entity_id: script.flash_room1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -132,8 +132,9 @@ script:
|
|||||||
direction == 'down' and br > mn }}
|
direction == 'down' and br > mn }}
|
||||||
sequence:
|
sequence:
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ light }}"
|
entity_id: "{{ light }}"
|
||||||
|
data:
|
||||||
brightness: >
|
brightness: >
|
||||||
{% set br = state_attr(light, 'brightness')|int(0) %}
|
{% set br = state_attr(light, 'brightness')|int(0) %}
|
||||||
{% set mn = states('input_number.light_minimum')|int %}
|
{% set mn = states('input_number.light_minimum')|int %}
|
||||||
|
@ -46,17 +46,17 @@ script:
|
|||||||
foscam_off:
|
foscam_off:
|
||||||
sequence:
|
sequence:
|
||||||
- service: switch.turn_off
|
- service: switch.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: switch.foscam_motion
|
entity_id: switch.foscam_motion
|
||||||
- service: shell_command.foscam_turn_off
|
- service: shell_command.foscam_turn_off
|
||||||
foscam_on:
|
foscam_on:
|
||||||
sequence:
|
sequence:
|
||||||
- service: switch.turn_off
|
- service: switch.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: switch.foscam_motion
|
entity_id: switch.foscam_motion
|
||||||
- service: shell_command.foscam_turn_on
|
- service: shell_command.foscam_turn_on
|
||||||
- service: switch.turn_on
|
- service: switch.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: switch.foscam_motion
|
entity_id: switch.foscam_motion
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -35,8 +35,9 @@ automation:
|
|||||||
|
|
||||||
action:
|
action:
|
||||||
service: media_player.play_media
|
service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.nursery
|
entity_id: media_player.nursery
|
||||||
|
data:
|
||||||
media_content_id: http://fileserver/rain.mp3
|
media_content_id: http://fileserver/rain.mp3
|
||||||
media_content_type: music
|
media_content_type: music
|
||||||
|
|
||||||
@ -51,8 +52,9 @@ automation:
|
|||||||
|
|
||||||
action:
|
action:
|
||||||
service: media_player.play_media
|
service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.nursery
|
entity_id: media_player.nursery
|
||||||
|
data:
|
||||||
media_content_id: http://fileserver/babbling_brook.mp3
|
media_content_id: http://fileserver/babbling_brook.mp3
|
||||||
media_content_type: music
|
media_content_type: music
|
||||||
|
|
||||||
@ -66,7 +68,7 @@ automation:
|
|||||||
|
|
||||||
action:
|
action:
|
||||||
service: media_player.turn_off
|
service: media_player.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.nursery
|
entity_id: media_player.nursery
|
||||||
```
|
```
|
||||||
A little bit more complex example that uses [`input_select`](/integrations/input_select/) and template to decide what to play, and which [Chromecast](/integrations/cast/) to play on.
|
A little bit more complex example that uses [`input_select`](/integrations/input_select/) and template to decide what to play, and which [Chromecast](/integrations/cast/) to play on.
|
||||||
|
@ -55,7 +55,7 @@ script:
|
|||||||
data:
|
data:
|
||||||
message: "WeMo not found, restarting HA"
|
message: "WeMo not found, restarting HA"
|
||||||
- service: switch.turn_on
|
- service: switch.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: switch.killhass
|
entity_id: switch.killhass
|
||||||
|
|
||||||
automation:
|
automation:
|
||||||
|
@ -16,22 +16,22 @@ script:
|
|||||||
alias: "Sonos TTS script"
|
alias: "Sonos TTS script"
|
||||||
sequence:
|
sequence:
|
||||||
- service: sonos.snapshot
|
- service: sonos.snapshot
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ sonos_entity }}"
|
entity_id: "{{ sonos_entity }}"
|
||||||
- service: sonos.unjoin
|
- service: sonos.unjoin
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ sonos_entity }}"
|
entity_id: "{{ sonos_entity }}"
|
||||||
- service: media_player.volume_set
|
- service: media_player.volume_set
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ sonos_entity }}"
|
entity_id: "{{ sonos_entity }}"
|
||||||
volume_level: "{{ volume }}"
|
volume_level: "{{ volume }}"
|
||||||
- service: tts.voicerss_say
|
- service: tts.voicerss_say
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ sonos_entity }}"
|
entity_id: "{{ sonos_entity }}"
|
||||||
message: "{{ message }}"
|
message: "{{ message }}"
|
||||||
- delay: "{{ delay }}"
|
- delay: "{{ delay }}"
|
||||||
- service: sonos.restore
|
- service: sonos.restore
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ sonos_entity }}"
|
entity_id: "{{ sonos_entity }}"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -44,12 +44,12 @@ automation:
|
|||||||
to: "on"
|
to: "on"
|
||||||
action:
|
action:
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id:
|
entity_id:
|
||||||
- light.hallway_0
|
- light.hallway_0
|
||||||
- light.hallway_1
|
- light.hallway_1
|
||||||
- service: timer.start
|
- service: timer.start
|
||||||
data:
|
target:
|
||||||
entity_id: timer.hallway
|
entity_id: timer.hallway
|
||||||
|
|
||||||
- alias: "Turn off hallway lights 10 minutes after trigger"
|
- alias: "Turn off hallway lights 10 minutes after trigger"
|
||||||
@ -60,7 +60,7 @@ automation:
|
|||||||
entity_id: timer.hallway
|
entity_id: timer.hallway
|
||||||
action:
|
action:
|
||||||
service: light.turn_off
|
service: light.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id:
|
entity_id:
|
||||||
- light.hallway_0
|
- light.hallway_0
|
||||||
- light.hallway_1
|
- light.hallway_1
|
||||||
|
@ -102,8 +102,9 @@ automation:
|
|||||||
to: "home"
|
to: "home"
|
||||||
action:
|
action:
|
||||||
service: scene.turn_on
|
service: scene.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: scene.romantic
|
entity_id: scene.romantic
|
||||||
|
data:
|
||||||
transition: 2.5
|
transition: 2.5
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -16,7 +16,7 @@ script:
|
|||||||
sequence:
|
sequence:
|
||||||
# This is written using the Script Syntax
|
# This is written using the Script Syntax
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: light.ceiling
|
entity_id: light.ceiling
|
||||||
- service: notify.notify
|
- service: notify.notify
|
||||||
data:
|
data:
|
||||||
@ -49,8 +49,9 @@ The most important one is the action to call a service. This can be done in vari
|
|||||||
```yaml
|
```yaml
|
||||||
- alias: "Bedroom lights on"
|
- alias: "Bedroom lights on"
|
||||||
service: light.turn_on
|
service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: group.bedroom
|
entity_id: group.bedroom
|
||||||
|
data:
|
||||||
brightness: 100
|
brightness: 100
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -76,8 +77,9 @@ The variables action allows you to set/override variables that will be accessibl
|
|||||||
brightness: 100
|
brightness: 100
|
||||||
- alias: "Control lights"
|
- alias: "Control lights"
|
||||||
service: light.turn_on
|
service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ entities }}"
|
entity_id: "{{ entities }}"
|
||||||
|
data:
|
||||||
brightness: "{{ brightness }}"
|
brightness: "{{ brightness }}"
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -339,14 +341,14 @@ script:
|
|||||||
mode: restart
|
mode: restart
|
||||||
sequence:
|
sequence:
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: "light.{{ light }}"
|
entity_id: "light.{{ light }}"
|
||||||
- repeat:
|
- repeat:
|
||||||
count: "{{ count|int * 2 - 1 }}"
|
count: "{{ count|int * 2 - 1 }}"
|
||||||
sequence:
|
sequence:
|
||||||
- delay: 2
|
- delay: 2
|
||||||
- service: light.toggle
|
- service: light.toggle
|
||||||
data:
|
target:
|
||||||
entity_id: "light.{{ light }}"
|
entity_id: "light.{{ light }}"
|
||||||
flash_hallway_light:
|
flash_hallway_light:
|
||||||
sequence:
|
sequence:
|
||||||
|
@ -36,21 +36,24 @@ alarm_control_panel:
|
|||||||
value_template: "{{ states('alarm_control_panel.real_alarm') }}"
|
value_template: "{{ states('alarm_control_panel.real_alarm') }}"
|
||||||
arm_away:
|
arm_away:
|
||||||
service: alarm_control_panel.alarm_arm_away
|
service: alarm_control_panel.alarm_arm_away
|
||||||
data:
|
target:
|
||||||
entity_id: alarm_control_panel.real_alarm
|
entity_id: alarm_control_panel.real_alarm
|
||||||
|
data:
|
||||||
code: !secret alarm_code
|
code: !secret alarm_code
|
||||||
arm_home:
|
arm_home:
|
||||||
service: alarm_control_panel.alarm_arm_home
|
service: alarm_control_panel.alarm_arm_home
|
||||||
data:
|
target:
|
||||||
entity_id: alarm_control_panel.real_alarm
|
entity_id: alarm_control_panel.real_alarm
|
||||||
|
data:
|
||||||
code: !secret alarm_code
|
code: !secret alarm_code
|
||||||
disarm:
|
disarm:
|
||||||
- condition: state
|
- condition: state
|
||||||
entity_id: device_tracker.paulus
|
entity_id: device_tracker.paulus
|
||||||
state: "home"
|
state: "home"
|
||||||
- service: alarm_control_panel.alarm_arm_home
|
- service: alarm_control_panel.alarm_arm_home
|
||||||
data:
|
target:
|
||||||
entity_id: alarm_control_panel.real_alarm
|
entity_id: alarm_control_panel.real_alarm
|
||||||
|
data:
|
||||||
code: !secret alarm_code
|
code: !secret alarm_code
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -217,7 +217,7 @@ intent_script:
|
|||||||
ActivateSceneIntent:
|
ActivateSceneIntent:
|
||||||
action:
|
action:
|
||||||
service: scene.turn_on
|
service: scene.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: scene.{{ Scene | replace(" ", "_") }}
|
entity_id: scene.{{ Scene | replace(" ", "_") }}
|
||||||
speech:
|
speech:
|
||||||
type: plain
|
type: plain
|
||||||
@ -269,7 +269,7 @@ intent_script:
|
|||||||
RunScriptIntent:
|
RunScriptIntent:
|
||||||
action:
|
action:
|
||||||
service: script.turn_on
|
service: script.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: script.{{ Script | replace(" ", "_") }}
|
entity_id: script.{{ Script | replace(" ", "_") }}
|
||||||
speech:
|
speech:
|
||||||
type: plain
|
type: plain
|
||||||
|
@ -104,7 +104,7 @@ Say to the `media_player.living_room` device entity:
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- service: tts.amazon_polly_say
|
- service: tts.amazon_polly_say
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.living_room
|
entity_id: media_player.living_room
|
||||||
message: >
|
message: >
|
||||||
<speak>
|
<speak>
|
||||||
|
@ -215,15 +215,17 @@ You can launch an app on your device using the `media_player.select_source` comm
|
|||||||
start_netflix:
|
start_netflix:
|
||||||
sequence:
|
sequence:
|
||||||
- service: media_player.select_source
|
- service: media_player.select_source
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.fire_tv_living_room
|
entity_id: media_player.fire_tv_living_room
|
||||||
|
data:
|
||||||
source: "com.netflix.ninja"
|
source: "com.netflix.ninja"
|
||||||
|
|
||||||
stop_netflix:
|
stop_netflix:
|
||||||
sequence:
|
sequence:
|
||||||
- service: media_player.select_source
|
- service: media_player.select_source
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.fire_tv_living_room
|
entity_id: media_player.fire_tv_living_room
|
||||||
|
data:
|
||||||
source: "!com.netflix.ninja"
|
source: "!com.netflix.ninja"
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -241,8 +243,9 @@ In an [action](/getting-started/automation-action/) of your [automation setup](/
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: androidtv.adb_command
|
service: androidtv.adb_command
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.androidtv_tv_living_room
|
entity_id: media_player.androidtv_tv_living_room
|
||||||
|
data:
|
||||||
command: "HOME"
|
command: "HOME"
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -282,8 +285,9 @@ As an example, a service call in a [script](/docs/scripts) could be changed from
|
|||||||
```yaml
|
```yaml
|
||||||
# Send the "UP" command (slow)
|
# Send the "UP" command (slow)
|
||||||
- service: androidtv.adb_command
|
- service: androidtv.adb_command
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.fire_tv_living_room
|
entity_id: media_player.fire_tv_living_room
|
||||||
|
data:
|
||||||
command: UP
|
command: UP
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -292,8 +296,9 @@ to this:
|
|||||||
```yaml
|
```yaml
|
||||||
# Send the "UP" command using `sendevent` (faster)
|
# Send the "UP" command using `sendevent` (faster)
|
||||||
- service: androidtv.adb_command
|
- service: androidtv.adb_command
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.fire_tv_living_room
|
entity_id: media_player.fire_tv_living_room
|
||||||
|
data:
|
||||||
command: "sendevent /dev/input/event4 4 4 786979 && sendevent /dev/input/event4 1 172 1 && sendevent /dev/input/event4 0 0 0 && sendevent /dev/input/event4 4 4 786979 && sendevent /dev/input/event4 1 172 0 && sendevent /dev/input/event4 0 0 0"
|
command: "sendevent /dev/input/event4 4 4 786979 && sendevent /dev/input/event4 1 172 1 && sendevent /dev/input/event4 0 0 0 && sendevent /dev/input/event4 4 4 786979 && sendevent /dev/input/event4 1 172 0 && sendevent /dev/input/event4 0 0 0"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -88,8 +88,9 @@ A typical service call for press several buttons looks like this.
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
service: remote.send_command
|
service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.apple_tv
|
entity_id: remote.apple_tv
|
||||||
|
data:
|
||||||
command:
|
command:
|
||||||
- left
|
- left
|
||||||
- left
|
- left
|
||||||
|
@ -55,7 +55,7 @@ The requirement is that you have setup the [`xiaomi aqara` integration](/integra
|
|||||||
data:
|
data:
|
||||||
brightness: 5
|
brightness: 5
|
||||||
- service: automation.turn_on
|
- service: automation.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: automation.MOTION_OFF
|
entity_id: automation.MOTION_OFF
|
||||||
- alias: "If there no motion for 5 minutes turn off the gateway light"
|
- alias: "If there no motion for 5 minutes turn off the gateway light"
|
||||||
trigger:
|
trigger:
|
||||||
@ -70,7 +70,7 @@ The requirement is that you have setup the [`xiaomi aqara` integration](/integra
|
|||||||
target:
|
target:
|
||||||
entity_id: light.gateway_light_34ce00xxxx11
|
entity_id: light.gateway_light_34ce00xxxx11
|
||||||
- service: automation.turn_off
|
- service: automation.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: automation.Motion_off
|
entity_id: automation.Motion_off
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -356,7 +356,7 @@ This automation toggles the living room lamp on vibration/tilt.
|
|||||||
movement_type: vibrate
|
movement_type: vibrate
|
||||||
action:
|
action:
|
||||||
service: light.toggle
|
service: light.toggle
|
||||||
data:
|
target:
|
||||||
entity_id: light.living_room_lamp
|
entity_id: light.living_room_lamp
|
||||||
- alias: "Turn on Living Room Lamp on tilt"
|
- alias: "Turn on Living Room Lamp on tilt"
|
||||||
trigger:
|
trigger:
|
||||||
@ -367,6 +367,6 @@ This automation toggles the living room lamp on vibration/tilt.
|
|||||||
movement_type: tilt
|
movement_type: tilt
|
||||||
action:
|
action:
|
||||||
service: light.toggle
|
service: light.toggle
|
||||||
data:
|
target:
|
||||||
entity_id: light.living_room_lamp
|
entity_id: light.living_room_lamp
|
||||||
```
|
```
|
||||||
|
@ -104,13 +104,14 @@ This example script shows how to take a picture with your camera, named `My Came
|
|||||||
alias: "Blink Snap Picture"
|
alias: "Blink Snap Picture"
|
||||||
sequence:
|
sequence:
|
||||||
- service: blink.trigger_camera
|
- service: blink.trigger_camera
|
||||||
data:
|
target:
|
||||||
entity_id: camera.blink_my_camera
|
entity_id: camera.blink_my_camera
|
||||||
- delay: 00:00:05
|
- delay: 00:00:05
|
||||||
- service: blink.blink_update
|
- service: blink.blink_update
|
||||||
- service: camera.snapshot
|
- service: camera.snapshot
|
||||||
data:
|
target:
|
||||||
entity_id: camera.blink_my_camera
|
entity_id: camera.blink_my_camera
|
||||||
|
data:
|
||||||
filename: /tmp/my_image.jpg
|
filename: /tmp/my_image.jpg
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -69,8 +69,9 @@ script:
|
|||||||
learn_tv_power:
|
learn_tv_power:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.learn_command
|
- service: remote.learn_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command: power
|
command: power
|
||||||
```
|
```
|
||||||
@ -89,8 +90,9 @@ script:
|
|||||||
learn_car_unlock:
|
learn_car_unlock:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.learn_command
|
- service: remote.learn_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.garage
|
entity_id: remote.garage
|
||||||
|
data:
|
||||||
device: car
|
device: car
|
||||||
command: unlock
|
command: unlock
|
||||||
command_type: rf
|
command_type: rf
|
||||||
@ -112,8 +114,9 @@ script:
|
|||||||
learn_tv_commands:
|
learn_tv_commands:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.learn_command
|
- service: remote.learn_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command:
|
command:
|
||||||
- turn on
|
- turn on
|
||||||
@ -138,8 +141,9 @@ script:
|
|||||||
learn_tv_power_button:
|
learn_tv_power_button:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.learn_command
|
- service: remote.learn_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command: power
|
command: power
|
||||||
alternative: true
|
alternative: true
|
||||||
@ -173,8 +177,9 @@ script:
|
|||||||
tv_power:
|
tv_power:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.send_command
|
- service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command: power
|
command: power
|
||||||
```
|
```
|
||||||
@ -189,8 +194,9 @@ script:
|
|||||||
turn_up_tv_volume_20:
|
turn_up_tv_volume_20:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.send_command
|
- service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command: volume up
|
command: volume up
|
||||||
num_repeats: 20
|
num_repeats: 20
|
||||||
@ -206,8 +212,9 @@ script:
|
|||||||
turn_on_ac:
|
turn_on_ac:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.send_command
|
- service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: air conditioner
|
device: air conditioner
|
||||||
command:
|
command:
|
||||||
- turn on
|
- turn on
|
||||||
@ -224,8 +231,9 @@ script:
|
|||||||
turn_on_tv:
|
turn_on_tv:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.send_command
|
- service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
command: b64:JgAcAB0dHB44HhweGx4cHR06HB0cHhwdHB8bHhwADQUAAAAAAAAAAAAAAAA=
|
command: b64:JgAcAB0dHB44HhweGx4cHR06HB0cHhwdHB8bHhwADQUAAAAAAAAAAAAAAAA=
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -239,8 +247,9 @@ script:
|
|||||||
turn_on_ac:
|
turn_on_ac:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.send_command
|
- service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
command:
|
command:
|
||||||
- b64:JgAcAB0dHB44HhweGx4cHR06HB0cHhwdHB8bHhwADQUAAAAAAAAAAAAAAAA=
|
- b64:JgAcAB0dHB44HhweGx4cHR06HB0cHhwdHB8bHhwADQUAAAAAAAAAAAAAAAA=
|
||||||
- b64:JgAaABweOR4bHhwdHB4dHRw6HhsdHR0dOTocAA0FAAAAAAAAAAAAAAAAAAA=
|
- b64:JgAaABweOR4bHhwdHB4dHRw6HhsdHR0dOTocAA0FAAAAAAAAAAAAAAAAAAA=
|
||||||
@ -256,8 +265,9 @@ script:
|
|||||||
turn_on_ac:
|
turn_on_ac:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.send_command
|
- service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command:
|
command:
|
||||||
- turn on
|
- turn on
|
||||||
@ -284,8 +294,9 @@ script:
|
|||||||
delete_tv_power:
|
delete_tv_power:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.delete_command
|
- service: remote.delete_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command: power
|
command: power
|
||||||
```
|
```
|
||||||
@ -300,8 +311,9 @@ script:
|
|||||||
delete_tv_commands:
|
delete_tv_commands:
|
||||||
sequence:
|
sequence:
|
||||||
- service: remote.delete_command
|
- service: remote.delete_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.bedroom
|
entity_id: remote.bedroom
|
||||||
|
data:
|
||||||
device: television
|
device: television
|
||||||
command:
|
command:
|
||||||
- power
|
- power
|
||||||
|
@ -60,8 +60,9 @@ For example, the following action in an automation would send an `hls` live stre
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: camera.play_stream
|
service: camera.play_stream
|
||||||
data:
|
target:
|
||||||
entity_id: camera.yourcamera
|
entity_id: camera.yourcamera
|
||||||
|
data:
|
||||||
media_player: media_player.chromecast
|
media_player: media_player.chromecast
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -87,8 +88,9 @@ For example, the following action in an automation would take a recording from "
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: camera.record
|
service: camera.record
|
||||||
data:
|
target:
|
||||||
entity_id: camera.yourcamera
|
entity_id: camera.yourcamera
|
||||||
|
data:
|
||||||
filename: '/tmp/{{ entity_id.name }}_{{ now().strftime("%Y%m%d-%H%M%S") }}.mp4'
|
filename: '/tmp/{{ entity_id.name }}_{{ now().strftime("%Y%m%d-%H%M%S") }}.mp4'
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -112,8 +114,9 @@ For example, the following action in an automation would take a snapshot from "y
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: camera.snapshot
|
service: camera.snapshot
|
||||||
data:
|
target:
|
||||||
entity_id: camera.yourcamera
|
entity_id: camera.yourcamera
|
||||||
|
data:
|
||||||
filename: '/tmp/yourcamera_{{ now().strftime("%Y%m%d-%H%M%S") }}.jpg'
|
filename: '/tmp/yourcamera_{{ now().strftime("%Y%m%d-%H%M%S") }}.jpg'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -54,8 +54,9 @@ Optional:
|
|||||||
'cast_youtube_to_my_chromecast':
|
'cast_youtube_to_my_chromecast':
|
||||||
alias: "Cast YouTube to My Chromecast"
|
alias: "Cast YouTube to My Chromecast"
|
||||||
sequence:
|
sequence:
|
||||||
- data:
|
- target:
|
||||||
entity_id: media_player.my_chromecast
|
entity_id: media_player.my_chromecast
|
||||||
|
data:
|
||||||
media_content_type: cast
|
media_content_type: cast
|
||||||
media_content_id: '
|
media_content_id: '
|
||||||
{
|
{
|
||||||
@ -79,8 +80,9 @@ Optional:
|
|||||||
'cast_supla_to_my_chromecast':
|
'cast_supla_to_my_chromecast':
|
||||||
alias: "Cast supla to My Chromecast"
|
alias: "Cast supla to My Chromecast"
|
||||||
sequence:
|
sequence:
|
||||||
- data:
|
- target:
|
||||||
entity_id: media_player.my_chromecast
|
entity_id: media_player.my_chromecast
|
||||||
|
data:
|
||||||
media_content_type: cast
|
media_content_type: cast
|
||||||
media_content_id: '
|
media_content_id: '
|
||||||
{
|
{
|
||||||
@ -99,8 +101,9 @@ To cast media directly from a configured Plex server, set the fields [as documen
|
|||||||
alias: "Cast Plex to Chromecast"
|
alias: "Cast Plex to Chromecast"
|
||||||
sequence:
|
sequence:
|
||||||
- service: media_player.play_media
|
- service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.chromecast
|
entity_id: media_player.chromecast
|
||||||
|
data:
|
||||||
media_content_type: movie
|
media_content_type: movie
|
||||||
media_content_id: 'plex://{"library_name": "Movies", "title": "Groundhog Day"}'
|
media_content_id: 'plex://{"library_name": "Movies", "title": "Groundhog Day"}'
|
||||||
```
|
```
|
||||||
@ -116,8 +119,9 @@ You can play MP3 streams like net radios, FLAC files or videos from your local n
|
|||||||
```yaml
|
```yaml
|
||||||
# Play a video file from the local network:
|
# Play a video file from the local network:
|
||||||
service: media_player.play_media
|
service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.chromecast
|
entity_id: media_player.chromecast
|
||||||
|
data:
|
||||||
media_content_type: "video"
|
media_content_type: "video"
|
||||||
media_content_id: "http://192.168.0.100/movies/sample-video.mkv"
|
media_content_id: "http://192.168.0.100/movies/sample-video.mkv"
|
||||||
```
|
```
|
||||||
@ -125,8 +129,9 @@ data:
|
|||||||
```yaml
|
```yaml
|
||||||
# Show a jpeg image:
|
# Show a jpeg image:
|
||||||
service: media_player.play_media
|
service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.chromecast
|
entity_id: media_player.chromecast
|
||||||
|
data:
|
||||||
media_content_type: "image/jpeg"
|
media_content_type: "image/jpeg"
|
||||||
media_content_id: "http://via.placeholder.com/1024x600.jpg/0B6B94/FFFFFF/?text=Hello,%20Home%20Assistant!"
|
media_content_id: "http://via.placeholder.com/1024x600.jpg/0B6B94/FFFFFF/?text=Hello,%20Home%20Assistant!"
|
||||||
```
|
```
|
||||||
@ -137,8 +142,9 @@ For the possible metadata types and values check [Google cast documentation > Me
|
|||||||
```yaml
|
```yaml
|
||||||
# Play a movie from the internet, with extra metadata provided:
|
# Play a movie from the internet, with extra metadata provided:
|
||||||
service: media_player.play_media
|
service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.chromecast
|
entity_id: media_player.chromecast
|
||||||
|
data:
|
||||||
media_content_type: "video/mp4"
|
media_content_type: "video/mp4"
|
||||||
media_content_id: "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4"
|
media_content_id: "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4"
|
||||||
extra:
|
extra:
|
||||||
@ -153,8 +159,9 @@ data:
|
|||||||
```yaml
|
```yaml
|
||||||
# Play a netradio, with extra metadata provided:
|
# Play a netradio, with extra metadata provided:
|
||||||
service: media_player.play_media
|
service: media_player.play_media
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.chromecast
|
entity_id: media_player.chromecast
|
||||||
|
data:
|
||||||
media_content_type: "audio/mp3"
|
media_content_type: "audio/mp3"
|
||||||
media_content_id: "http://stream.tilos.hu:8000/tilos"
|
media_content_id: "http://stream.tilos.hu:8000/tilos"
|
||||||
extra:
|
extra:
|
||||||
|
@ -41,8 +41,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_aux_heat
|
- service: climate.set_aux_heat
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
aux_heat: true
|
aux_heat: true
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -66,8 +67,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_preset_mode
|
- service: climate.set_preset_mode
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
preset_mode: "eco"
|
preset_mode: "eco"
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -93,8 +95,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_temperature
|
- service: climate.set_temperature
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
temperature: 24
|
temperature: 24
|
||||||
hvac_mode: heat
|
hvac_mode: heat
|
||||||
```
|
```
|
||||||
@ -107,8 +110,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_temperature
|
- service: climate.set_temperature
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
target_temp_high: 24
|
target_temp_high: 24
|
||||||
target_temp_low: 20
|
target_temp_low: 20
|
||||||
hvac_mode: heat_cool
|
hvac_mode: heat_cool
|
||||||
@ -132,8 +136,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_humidity
|
- service: climate.set_humidity
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
humidity: 60
|
humidity: 60
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -155,8 +160,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_fan_mode
|
- service: climate.set_fan_mode
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
fan_mode: "On Low"
|
fan_mode: "On Low"
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -178,8 +184,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_hvac_mode
|
- service: climate.set_hvac_mode
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
hvac_mode: heat
|
hvac_mode: heat
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -201,8 +208,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: climate.set_swing_mode
|
- service: climate.set_swing_mode
|
||||||
data:
|
target:
|
||||||
entity_id: climate.kitchen
|
entity_id: climate.kitchen
|
||||||
|
data:
|
||||||
swing_mode: 1
|
swing_mode: 1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -151,7 +151,7 @@ automation:
|
|||||||
level: ERROR
|
level: ERROR
|
||||||
action:
|
action:
|
||||||
service: counter.increment
|
service: counter.increment
|
||||||
data:
|
target:
|
||||||
entity_id: counter.error_counter
|
entity_id: counter.error_counter
|
||||||
|
|
||||||
counter:
|
counter:
|
||||||
|
@ -57,8 +57,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: cover.set_cover_position
|
- service: cover.set_cover_position
|
||||||
data:
|
target:
|
||||||
entity_id: cover.demo
|
entity_id: cover.demo
|
||||||
|
data:
|
||||||
position: 50
|
position: 50
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -80,7 +81,8 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: cover.set_cover_tilt_position
|
- service: cover.set_cover_tilt_position
|
||||||
data:
|
target:
|
||||||
entity_id: cover.demo
|
entity_id: cover.demo
|
||||||
|
data:
|
||||||
tilt_position: 50
|
tilt_position: 50
|
||||||
```
|
```
|
||||||
|
@ -159,15 +159,15 @@ cover:
|
|||||||
position_template: "{{ states('sensor.garage_door') }}"
|
position_template: "{{ states('sensor.garage_door') }}"
|
||||||
open_cover:
|
open_cover:
|
||||||
service: switch.turn_on
|
service: switch.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: switch.garage_door
|
entity_id: switch.garage_door
|
||||||
close_cover:
|
close_cover:
|
||||||
service: switch.turn_off
|
service: switch.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: switch.garage_door
|
entity_id: switch.garage_door
|
||||||
stop_cover:
|
stop_cover:
|
||||||
service: switch.turn_on
|
service: switch.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: switch.garage_door
|
entity_id: switch.garage_door
|
||||||
icon_template: >-
|
icon_template: >-
|
||||||
{% if states('sensor.garage_door')|float > 0 %}
|
{% if states('sensor.garage_door')|float > 0 %}
|
||||||
@ -237,17 +237,18 @@ script:
|
|||||||
cover_group:
|
cover_group:
|
||||||
sequence:
|
sequence:
|
||||||
- service: "cover.{{modus}}_cover"
|
- service: "cover.{{modus}}_cover"
|
||||||
data:
|
target:
|
||||||
entity_id:
|
entity_id:
|
||||||
- cover.bedroom
|
- cover.bedroom
|
||||||
- cover.livingroom
|
- cover.livingroom
|
||||||
cover_group_position:
|
cover_group_position:
|
||||||
sequence:
|
sequence:
|
||||||
- service: cover.set_cover_position
|
- service: cover.set_cover_position
|
||||||
data:
|
target:
|
||||||
entity_id:
|
entity_id:
|
||||||
- cover.bedroom
|
- cover.bedroom
|
||||||
- cover.livingroom
|
- cover.livingroom
|
||||||
|
data:
|
||||||
position: "{{position}}"
|
position: "{{position}}"
|
||||||
|
|
||||||
automation:
|
automation:
|
||||||
@ -258,8 +259,9 @@ automation:
|
|||||||
offset: "+00:30:00"
|
offset: "+00:30:00"
|
||||||
action:
|
action:
|
||||||
- service: cover.set_cover_position
|
- service: cover.set_cover_position
|
||||||
data:
|
target:
|
||||||
entity_id: cover.cover_group
|
entity_id: cover.cover_group
|
||||||
|
data:
|
||||||
position: 25
|
position: 25
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -218,8 +218,9 @@ automation:
|
|||||||
event: 2002
|
event: 2002
|
||||||
action:
|
action:
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: light.lamp
|
entity_id: light.lamp
|
||||||
|
data:
|
||||||
brightness: >
|
brightness: >
|
||||||
{% set bri = state_attr('light.lamp', 'brightness') | int %}
|
{% set bri = state_attr('light.lamp', 'brightness') | int %}
|
||||||
{{ [bri+30, 249] | min }}
|
{{ [bri+30, 249] | min }}
|
||||||
@ -234,8 +235,9 @@ automation:
|
|||||||
event: 3002
|
event: 3002
|
||||||
action:
|
action:
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: light.lamp
|
entity_id: light.lamp
|
||||||
|
data:
|
||||||
brightness: >
|
brightness: >
|
||||||
{% set bri = state_attr('light.lamp', 'brightness') | int %}
|
{% set bri = state_attr('light.lamp', 'brightness') | int %}
|
||||||
{{ [bri-30, 0] | max }}
|
{{ [bri-30, 0] | max }}
|
||||||
|
@ -55,6 +55,6 @@ If you have a sensor session running, and once you have enabled the Dexcom integ
|
|||||||
before: "06:00:00"
|
before: "06:00:00"
|
||||||
action:
|
action:
|
||||||
- service: light.turn_on
|
- service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: light.kitchen
|
entity_id: light.kitchen
|
||||||
```
|
```
|
||||||
|
@ -112,7 +112,7 @@ intent_script:
|
|||||||
{%- else -%}
|
{%- else -%}
|
||||||
switch.turn_off
|
switch.turn_off
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
data:
|
target:
|
||||||
entity_id: "switch.light_{{ Room | striptags | replace(' ', '_') }}"
|
entity_id: "switch.light_{{ Room | striptags | replace(' ', '_') }}"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -119,8 +119,9 @@ A typical service call for press several buttons looks like this.
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
service: remote.send_command
|
service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.directv_entity
|
entity_id: remote.directv_entity
|
||||||
|
data:
|
||||||
command:
|
command:
|
||||||
- left
|
- left
|
||||||
- left
|
- left
|
||||||
|
@ -86,8 +86,9 @@ script:
|
|||||||
bed_set_heat:
|
bed_set_heat:
|
||||||
sequence:
|
sequence:
|
||||||
- service: eight_sleep.heat_set
|
- service: eight_sleep.heat_set
|
||||||
data:
|
target:
|
||||||
entity_id: "sensor.eight_left_bed_state"
|
entity_id: "sensor.eight_left_bed_state"
|
||||||
|
data:
|
||||||
target: 35
|
target: 35
|
||||||
duration: 3600
|
duration: 3600
|
||||||
```
|
```
|
||||||
|
@ -142,7 +142,7 @@ automation:
|
|||||||
pushed: 0
|
pushed: 0
|
||||||
action:
|
action:
|
||||||
service: "{% if trigger.event.data.onoff %} light.turn_on {% else %} light.turn_off {%endif %}"
|
service: "{% if trigger.event.data.onoff %} light.turn_on {% else %} light.turn_off {%endif %}"
|
||||||
data:
|
target:
|
||||||
entity_id: "{% if trigger.event.data.which == 1 %} light.hall_left {% else %} light.hall_right {%endif %}"
|
entity_id: "{% if trigger.event.data.which == 1 %} light.hall_left {% else %} light.hall_right {%endif %}"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -158,8 +158,9 @@ This service call will set the `setpoint` of a zone, as identified by its `entit
|
|||||||
```yaml
|
```yaml
|
||||||
- action:
|
- action:
|
||||||
- service: evohome.set_zone_override
|
- service: evohome.set_zone_override
|
||||||
|
target:
|
||||||
|
entity_id: climate.loungeroom\
|
||||||
data:
|
data:
|
||||||
entity_id: climate.loungeroom
|
|
||||||
setpoint: 10
|
setpoint: 10
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -168,8 +169,9 @@ The `duration` can be up to 24 hours, after which the zone mode will revert to s
|
|||||||
```yaml
|
```yaml
|
||||||
- action:
|
- action:
|
||||||
- service: evohome.set_zone_override
|
- service: evohome.set_zone_override
|
||||||
data:
|
target:
|
||||||
entity_id: climate.loungeroom
|
entity_id: climate.loungeroom
|
||||||
|
data:
|
||||||
setpoint: 10
|
setpoint: 10
|
||||||
duration: {minutes: 0}
|
duration: {minutes: 0}
|
||||||
```
|
```
|
||||||
|
@ -71,7 +71,7 @@ trigger:
|
|||||||
to: "on"
|
to: "on"
|
||||||
action:
|
action:
|
||||||
service: media_player.turn_on
|
service: media_player.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: "media_player.badezimmer"
|
entity_id: "media_player.badezimmer"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -79,8 +79,9 @@ script:
|
|||||||
tts:
|
tts:
|
||||||
sequence:
|
sequence:
|
||||||
- service: tts.google_say # or amazon_polly, voicerss, etc
|
- service: tts.google_say # or amazon_polly, voicerss, etc
|
||||||
data:
|
target:
|
||||||
entity_id: media_player.gstreamer
|
entity_id: media_player.gstreamer
|
||||||
|
data:
|
||||||
message: "example text-to-speech message"
|
message: "example text-to-speech message"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -127,8 +127,9 @@ A typical service call for sending several button presses looks like this:
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
service: remote.send_command
|
service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.tv_room
|
entity_id: remote.tv_room
|
||||||
|
data:
|
||||||
command:
|
command:
|
||||||
- PowerOn
|
- PowerOn
|
||||||
- Mute
|
- Mute
|
||||||
@ -138,8 +139,9 @@ data:
|
|||||||
OR
|
OR
|
||||||
```yaml
|
```yaml
|
||||||
service: remote.send_command
|
service: remote.send_command
|
||||||
data:
|
target:
|
||||||
entity_id: remote.tv_room
|
entity_id: remote.tv_room
|
||||||
|
data:
|
||||||
command:
|
command:
|
||||||
- PowerOn
|
- PowerOn
|
||||||
- Mute
|
- Mute
|
||||||
@ -160,8 +162,9 @@ A typical service call for changing the channel would be::
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
service: harmony.change_channel
|
service: harmony.change_channel
|
||||||
data:
|
target:
|
||||||
entity_id: remote.tv_room
|
entity_id: remote.tv_room
|
||||||
|
data:
|
||||||
channel: 200
|
channel: 200
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -82,8 +82,9 @@ script:
|
|||||||
boost_heating:
|
boost_heating:
|
||||||
sequence:
|
sequence:
|
||||||
- service: hive.boost_heating
|
- service: hive.boost_heating
|
||||||
data:
|
target:
|
||||||
entity_id: "climate.heating"
|
entity_id: "climate.heating"
|
||||||
|
data:
|
||||||
time_period: "01:30:00"
|
time_period: "01:30:00"
|
||||||
temperature: "20.5"
|
temperature: "20.5"
|
||||||
```
|
```
|
||||||
@ -106,8 +107,9 @@ script:
|
|||||||
boost_hot_water:
|
boost_hot_water:
|
||||||
sequence:
|
sequence:
|
||||||
- service: "hive.boost_hot_water"
|
- service: "hive.boost_hot_water"
|
||||||
data:
|
target:
|
||||||
entity_id: "water_heater.hot_water"
|
entity_id: "water_heater.hot_water"
|
||||||
|
data:
|
||||||
time_period: "01:30:00"
|
time_period: "01:30:00"
|
||||||
on_off: "on"
|
on_off: "on"
|
||||||
```
|
```
|
||||||
|
@ -67,7 +67,7 @@ Generic service to toggle devices on/off under any domain. Same usage as the lig
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: homeassistant.toggle
|
service: homeassistant.toggle
|
||||||
data:
|
target:
|
||||||
entity_id: light.living_room
|
entity_id: light.living_room
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -84,7 +84,7 @@ Generic service to turn devices on under any domain. Same usage as the light.tur
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: homeassistant.turn_on
|
service: homeassistant.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: light.living_room
|
entity_id: light.living_room
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -101,7 +101,7 @@ Generic service to turn devices off under any domain. Same usage as the light.tu
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: homeassistant.turn_off
|
service: homeassistant.turn_off
|
||||||
data:
|
target:
|
||||||
entity_id: light.living_room
|
entity_id: light.living_room
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -118,7 +118,7 @@ Force one or more entities to update its data rather than wait for the next sche
|
|||||||
```yaml
|
```yaml
|
||||||
action:
|
action:
|
||||||
service: homeassistant.update_entity
|
service: homeassistant.update_entity
|
||||||
data:
|
target:
|
||||||
entity_id:
|
entity_id:
|
||||||
- light.living_room
|
- light.living_room
|
||||||
- switch.coffe_pot
|
- switch.coffe_pot
|
||||||
|
@ -332,8 +332,9 @@ Set boolean variable to true:
|
|||||||
...
|
...
|
||||||
action:
|
action:
|
||||||
service: homematic.set_variable_value
|
service: homematic.set_variable_value
|
||||||
data:
|
target:
|
||||||
entity_id: homematic.ccu2
|
entity_id: homematic.ccu2
|
||||||
|
data:
|
||||||
name: Variablename
|
name: Variablename
|
||||||
value: true
|
value: true
|
||||||
```
|
```
|
||||||
|
@ -287,8 +287,9 @@ You can get the required index from the native Homematic IP App.
|
|||||||
...
|
...
|
||||||
action:
|
action:
|
||||||
service: homematicip_cloud.set_active_climate_profile
|
service: homematicip_cloud.set_active_climate_profile
|
||||||
data:
|
target:
|
||||||
entity_id: climate.livingroom
|
entity_id: climate.livingroom
|
||||||
|
data:
|
||||||
climate_profile_index: 1
|
climate_profile_index: 1
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -308,7 +309,7 @@ Reset energy counter of measuring actuators.
|
|||||||
...
|
...
|
||||||
action:
|
action:
|
||||||
service: homematicip_cloud.reset_energy_counter
|
service: homematicip_cloud.reset_energy_counter
|
||||||
data:
|
target:
|
||||||
entity_id: switch.livingroom
|
entity_id: switch.livingroom
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -44,8 +44,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: humidifier.set_mode
|
- service: humidifier.set_mode
|
||||||
data:
|
target:
|
||||||
entity_id: humidifier.bedroom
|
entity_id: humidifier.bedroom
|
||||||
|
data:
|
||||||
preset_mode: "eco"
|
preset_mode: "eco"
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -67,8 +68,9 @@ automation:
|
|||||||
at: "07:15:00"
|
at: "07:15:00"
|
||||||
action:
|
action:
|
||||||
- service: humidifier.set_humidity
|
- service: humidifier.set_humidity
|
||||||
data:
|
target:
|
||||||
entity_id: humidifier.bedroom
|
entity_id: humidifier.bedroom
|
||||||
|
data:
|
||||||
humidity: 60
|
humidity: 60
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -70,7 +70,7 @@ automation:
|
|||||||
to: "on"
|
to: "on"
|
||||||
action:
|
action:
|
||||||
- service: image_processing.scan
|
- service: image_processing.scan
|
||||||
data:
|
target:
|
||||||
entity_id: image_processing.door
|
entity_id: image_processing.door
|
||||||
...
|
...
|
||||||
```
|
```
|
||||||
|
@ -91,6 +91,6 @@ You can also set or change the status of an `input_boolean` by using `input_bool
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- service: input_boolean.turn_on
|
- service: input_boolean.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: input_boolean.notify_home
|
entity_id: input_boolean.notify_home
|
||||||
```
|
```
|
||||||
|
@ -216,8 +216,9 @@ script:
|
|||||||
color: [255, 0, 0]
|
color: [255, 0, 0]
|
||||||
sequence:
|
sequence:
|
||||||
service: light.turn_on
|
service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ entities }}"
|
entity_id: "{{ entities }}"
|
||||||
|
data:
|
||||||
rgb_color: "{{ color }}"
|
rgb_color: "{{ color }}"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -155,8 +155,9 @@ script:
|
|||||||
color: [255, 0, 0]
|
color: [255, 0, 0]
|
||||||
sequence:
|
sequence:
|
||||||
service: light.turn_on
|
service: light.turn_on
|
||||||
data:
|
target:
|
||||||
entity_id: "{{ entities }}"
|
entity_id: "{{ entities }}"
|
||||||
|
data:
|
||||||
rgb_color: "{{ color }}"
|
rgb_color: "{{ color }}"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user