1
0
ansible-home-assistant/templates/unavailable-zwave.yaml.j2

18 lines
521 B
Django/Jinja

- id: info_zwave_unavailable_notice
alias: '[INFO][Z-Wave] Device offline'
mode: single
trigger:
- platform: state
to: dead
entity_id:
{% for device in devices %}
- {{ device.entity_id }} # {{ device.name }}
{% endfor %}
action:
- service: notify.home_assistant
data:
message: >
Device unavailable
{% raw %}{{ device_attr(device_id(trigger.event.data.device_id), 'name_by_user') }}{% endraw %} is unavailable
target: [ "1070507369164984372" ]