32 lines
745 B
Django/Jinja
32 lines
745 B
Django/Jinja
- id: info_low_battery
|
|
alias: '[INFO] Low battery'
|
|
mode: single
|
|
trigger:
|
|
- platform: numeric_state
|
|
below: 15
|
|
for:
|
|
hours: 0
|
|
minutes: 1
|
|
seconds: 0
|
|
entity_id:
|
|
{% for entity in entities %}
|
|
- {{ entity }}
|
|
{% endfor %}
|
|
- platform: numeric_state
|
|
below: 10
|
|
for:
|
|
hours: 0
|
|
minutes: 1
|
|
seconds: 0
|
|
entity_id:
|
|
{% for entity in entities %}
|
|
- {{ entity }}
|
|
{% endfor %}
|
|
action:
|
|
- service: notify.home_assistant
|
|
data:
|
|
message: >
|
|
Low battery
|
|
{% raw %}{{ device_attr(trigger.entity_id, 'name_by_user') }} has low battery {{ states(trigger.entity_id) }}% {% endraw %}
|
|
target: [ "1070507369164984372" ]
|