-
Notifications
You must be signed in to change notification settings - Fork 17
Examples Script
caiosweet edited this page Nov 13, 2022
·
2 revisions
script:
centro_notifiche_alexa_test:
alias: "Centro Notifiche Alexa Test"
sequence:
- variables:
my_variable: >
{% if is_state('alarm_control_panel.home_alarm', 'triggered')
and is_state('input_boolean.allarme_silenzioso', 'off')-%}
1 {% else -%} 0 {%- endif %}
- service: script.my_notify
data:
message: "Alert"
"{{'alexa' if my_variable else ''}}":
message: "Houston, we have a problem! "
language: en-US
voice: Matthew
script:
centro_notifiche_test:
alias: "Centro Notifiche: Test"
sequence:
- variables:
vocale: >-
{{is_state('switch.shelly_shsw_25_c48c2b_2', 'on')}}
- service: script.my_notify
data:
call_no_annuncio: 1
title: test 2
message: >-
messaggio con audio condizionato
alexa:
mode: "{{vocale}}"
message: >-
test 2 messaggio con audio condizionato
type: announce
media_player: last alexa