Migrate announcement automations #154

This commit is contained in:
2023-10-03 15:43:08 -04:00
parent 2b4a82c592
commit 34bdc989b7
2 changed files with 194 additions and 154 deletions

View File

@ -105,160 +105,6 @@ intent_script:
# Announcment Automation - fires at the time of the above input_datetimes
################################
automation:
- id: 81bee5ee-6820-4626-aebf-3deb8de69e4d
alias: Turn On Audible Notifications
initial_state: true
trigger:
platform: time
at: input_datetime.audible_notification_on
condition:
- condition: state
entity_id: input_boolean.vacation_mode
state: 'off'
action:
- service: input_boolean.turn_on
entity_id: input_boolean.audible_notifications
- service: switch.turn_off
target:
entity_id:
- switch.living_room_echo_dot_do_not_disturb_switch
- service: script.volume_reset
# Turn off audible notifications if they have't been turned off yet.
- id: e0e9c774-6abe-42aa-bdab-32108bebb0e9
alias: Turn Off Audible Notifications
initial_state: true
trigger:
- platform: time
at: input_datetime.audible_notification_off
condition:
- condition: state
entity_id: input_boolean.vacation_mode
state: 'off'
action:
- service: input_boolean.turn_off
entity_id: input_boolean.audible_notifications
- id: 842a1b9a-de3b-4f0a-9ecc-6cfacd92bf5d
alias: Kallen Briefings
trigger:
- platform: time
at: input_datetime.kallen_morning_briefing
id: kallen-morning
- platform: time
at: input_datetime.kallen_nightly_briefing
id: kallen-nightly
condition:
- condition: state
entity_id: input_boolean.kallen_overnight
state: 'off'
- condition: state
entity_id: input_boolean.vacation_mode
state: 'off'
action:
- choose:
- conditions:
- condition: and
conditions:
- condition: trigger
id: kallen-morning
- condition: state
entity_id: input_boolean.kallen_morning_briefing
state: 'off'
sequence:
- service: script.kallen_morning_briefing
- conditions:
- condition: and
conditions:
- condition: trigger
id: kallen-nightly
- condition: state
entity_id: input_boolean.kallen_nightly_briefing
state: 'off'
sequence:
- service: script.kallen_nightly_briefing
- id: fa2b59f8-1ad6-4380-9347-cb7d53590e41
alias: House Briefings
trigger:
- platform: time
at: input_datetime.morning_briefing
id: house-morning
- platform: time
at: input_datetime.daily_briefing
id: house-daily
- platform: time
at: input_datetime.nightly_briefing
id: house-nightly
condition:
- condition: state
entity_id: input_boolean.vacation_mode
state: 'off'
action:
- choose:
- conditions:
- condition: and
conditions:
- condition: trigger
id: house-morning
- condition: state
entity_id: input_boolean.good_morning
state: 'off'
sequence:
- if:
- condition: template
value_template: >
{% if is_state('input_boolean.kallen_school_today','on') and is_state('input_boolean.kallen_overnight','on') %}
false
{% else %}
true
{% endif %}
then:
- service: script.morning_briefing
- conditions:
- condition: and
conditions:
- condition: trigger
id: house-daily
- condition: state
entity_id: input_boolean.daily_briefing
state: 'off'
sequence:
- service: script.daily_briefing
- conditions:
- condition: and
conditions:
- condition: trigger
id: house-nightly
- condition: state
entity_id: input_boolean.nightly_briefing
state: 'off'
sequence:
- service: script.nightly_briefing
- id: d7641b5e-3cbb-4fb3-b6ed-5edf3157b88d
alias: Kallen Briefing Location Change
trigger:
- platform: state
entity_id: input_boolean.kallen_awake
from: 'off'
to: 'on'
condition:
- condition: state
entity_id: input_boolean.kallen_school_today
state: 'on'
- condition: state
entity_id: input_boolean.kallen_overnight
state: 'off'
action:
- service: input_select.select_option
data:
option: Common Areas
target:
entity_id: input_select.kallen_morning_briefing_location
script:
reset_annc_switches:
sequence: