Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- alias: NINA Warnmeldung Benachrichtigung
- description: ""
- trigger:
- - platform: state
- entity_id:
- - binary_sensor.warning_meckenbeuren_bodenseekreis_baden_wurttemberg_1
- - binary_sensor.warning_meckenbeuren_bodenseekreis_baden_wurttemberg_2
- - binary_sensor.warning_meckenbeuren_bodenseekreis_baden_wurttemberg_3
- - binary_sensor.warning_meckenbeuren_bodenseekreis_baden_wurttemberg_4
- - binary_sensor.warning_meckenbeuren_bodenseekreis_baden_wurttemberg_5
- to: "on"
- alias: "State trigger: warning_meckenbeuren_bodenseekreis_baden_wurttemberg_1-5"
- condition:
- - condition: or
- conditions:
- - condition: template
- value_template: >-
- {{ trigger_severity == 'Moderate' and
- is_state('input_boolean.nina_warnmeldung_moderat', 'on') }}
- alias: Severity = Moderate
- - condition: template
- value_template: >-
- {{ trigger_severity == 'Severe' and
- is_state('input_boolean.nina_warnmeldung_hoch', 'on') }}
- alias: Severity = Severe
- - condition: template
- value_template: >-
- {{ trigger_severity == 'Extreme' and
- is_state('input_boolean.nina_warnmeldung_extrem', 'on') }}
- alias: Severity = Extreme
- alias: Check Severity & Notification-Configuration
- action:
- - service: script.custom_flexible_notification
- data:
- title: NINA Warnmeldung
- message: "{{ trigger_headline }}"
- data:
- notification_icon: mdi:alert-outline
- tag: "{{ entity_id }}"
- actions:
- - action: URI
- title: Meldung ansehen (warnung.bund.de)
- uri: "{{ hyperlink }}"
- variables:
- trigger_severity: "{{ trigger.to_state.attributes.severity }}"
- trigger_headline: "{{ trigger.to_state.attributes.headline }}"
- entity_id: "{{ trigger.to_state.entity_id }}"
- hyperlink: https://warnung.bund.de/meldungen/{{ trigger.to_state.attributes.id }}
- mode: parallel
- max: 10
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement