I would like to use templates as threshold values, when a temperature falls below a value (using "below: " condition). Doesn’t work.
I found this in the documentation, where a template is used straight in a "delay: " value.
The question is: why can’t use templates for the “below:” numeric condition, but the below sample shows it can be used with “delay:” ?
automation:
- alias: turn something off after x time after turning it on
trigger:
platform: state
entity_id: switch.something
to: 'on'
action:
**- delay: '00:{{ states('input_number.minutes') | int }}:{{ states('input_number.seconds') | int }}'**
- service: switch.turn_off
entity_id: switch.something
automation:
- alias: turn something off after x time after turning it on
trigger:
platform: state
entity_id: switch.something
to: 'on'
action:
- delay: '00:{{ states('input_number.minutes') | int }}:{{ states('input_number.seconds') | int }}'
- service: switch.turn_off
entity_id: switch.something