mirror of
https://github.com/CCOSTAN/Home-AssistantConfig.git
synced 2025-02-21 00:25:12 +00:00
40 lines
1.1 KiB
YAML
Executable File
40 lines
1.1 KiB
YAML
Executable File
######################################################################################################
|
|
###Script to send notifications to the ChromeCast Audios during normal hours and only when we are home! Call like this:
|
|
# action:
|
|
# service: script.Voice_notify
|
|
# data_template:
|
|
# value1: 'Startup: Home Assistant is Up and Running!'
|
|
# OR
|
|
# value1: "{{ trigger.to_state.state }}"
|
|
|
|
######################################################################################################
|
|
|
|
voice_notify:
|
|
sequence:
|
|
- condition: and
|
|
conditions:
|
|
- condition: or
|
|
conditions:
|
|
- condition: state
|
|
entity_id: group.family
|
|
state: 'home'
|
|
- condition: state
|
|
entity_id: input_boolean.guest_mode
|
|
state: 'on'
|
|
|
|
- condition: time
|
|
before: '20:00:00'
|
|
|
|
- service: switch.turn_on
|
|
entity_id: switch.living_room_amp
|
|
- delay: '00:00:10'
|
|
|
|
- service: tts.google_say
|
|
entity_id: media_player.whole_house
|
|
data_template:
|
|
message: "{{ value1 }}"
|
|
cache: true
|
|
|
|
|
|
|