Climate Automation for Time schedules over the day

Tags: #<Tag:0x00007f77fa3f72e8>

Hi folks,
i have an automation problem with my time scheduling the thermostats over the day.
I use the eurotronic zwave thermostats and set some input_number’s and input_datetimes to control them. This is the first step, it should become more complex later :slight_smile:

the first pic shows the frontend and my inputs
then the automation code
and a screenshot which shows the replacements.

i have no ideas anymore

automation:

  - id: start_heating_workdays
    alias: Starte Heizen an Werktagen
    trigger:
      platform: time
    condition:
      - condition: or
        conditions:
        - condition: time
          after: '{{ states( "input_datetime.time_buero_week_heat_1_start" ) }}'
          before: '{{ states( "input_datetime.time_buero_week_heat_1_end" ) }}'
        - condition: time
          after: '{{ states( "input_datetime.time_buero_week_heat_2_start" ) }}'
          before: '{{ states( "input_datetime.time_buero_week_heat_2_end" ) }}'
    action:
      service: climate.set_temperature
      data: 
        entity_id: climate.thermostat_buero
        temperature: input_number.slider_buero_comfort
        hvac_mode: heat

When checking with the configuration I get this:

Konfiguration ungültig 
KONFIGURATION PRÜFEN
Invalid config for [automation]: extra keys not allowed @ data['condition'][0]['conditions'][0]['after']. Got None
extra keys not allowed @ data['condition'][0]['conditions'][0]['before']. Got None
not a valid value for dictionary value @ data['condition'][0]['conditions'][0]['condition']. Got None
required key not provided @ data['condition'][0]['conditions'][0]['entity_id']. Got None
required key not provided @ data['trigger'][0]['at']. Got None. (See ?, line ?). Please check the docs at https://home-assistant.io/integrations/automation/

I need some help to get this working - thanks

Your automation is wrong in multiple places.
First when should your automation trigger? You specify only the platform but no time to trigger. You probably want it to trigger at your specified start times.
Second, you can’t template “after” and “before” in your conditions.

I think you need to rethink how you do your automations and read the docs (again).

I read this article…

i understand, that my trigger is not well. But how it goes?

Do you have a good tutorial for me as a automations beginner?

Start with reading all the trigger types

Compare your trigger to the examples.

Sure, check the docs for trigger as stated by petro , condition, action and template. And here are some examples also from the docs.