I’m new to templating and have ran into an issue while using a template inside a package.
I am looking to hardcode the turn off and turn on times inside the YAML file, and not use an input. How can I make this happen?
- alias: lights_wake_up_on
trigger:
- platform: template
value_template: "{{ states.sensor.time.state == (states.input_datetime.lights_wake_up_on.attributes.timestamp | int | timestamp_custom('%H:%M', False)) }}"
action:
<my action here>
################################################
## Input Date/time
################################################
input_datetime:
lights_wake_up_off:
# name: Turning Wake Up Routine Off At
has_time: true
initial: '06:15'
lights_wake_up_on:
# name: Turning Wake Up Routine On At
has_time: true
initial: '03:59'