Error in my automation

I get for this automation an error:

description: Rollo Mitte Links nach unten (close)
mode: single
trigger:
  - platform: time_pattern
    minutes: /10
condition:
  - condition: and
    conditions:
      - condition: numeric_state
        entity_id: sensor.davis_solar
        above: 250
        for:
          minutes: 5
      - condition: state
        entity_id: binary_sensor.rollo_condition
        state: "on"
      - condition: state
        entity_id: cover.rollo_mitte_links
        state: open
      - condition: numeric_state
        entity_id: sensor.sun_solar_azimuth
        above: 180
action:
  - service: cover.close_cover
    target:
      entity_id: cover.rollo_mitte_links
    data: {}
alias: Rollo mitte links nach unten (close)

the following error:

2024-04-27 10:46:00.777 ERROR (MainThread) [homeassistant.components.automation] Automation with alias 'Rollo mitte links nach unten (close)' could not be validated and has been disabled: extra keys not allowed @ data['condition'][0]['conditions'][0]['for']. Got {'minutes': 5}

I want that solar is over 250 for 5 minutes… before it starts the action.
can I add an id: rollo_mitte_lins, to have traces?
It is stored in a separate file in the automation subdir.
Thanks!

Numeric state conditions do not support for: See: https://www.home-assistant.io/docs/scripts/conditions/#numeric-state-condition

Numeric state triggers do. Use that instead of your time pattern trigger. https://www.home-assistant.io/docs/automation/trigger/#numeric-state-trigger

I have another automation to open the cover eg due to wind.
So the case is possible that solar is still over 250 and therefore will not trigger the automation when the wind is gone.
To my knowledge the trigger for solar > 250 will only work, if solar is back under 250
Is my thinking correct?

If you want a condition on a numeric state above a certain value for a certain time, a binary sensor can help out. I would use a threshold sensor. With that you can replace the numerical condition with a state condition. Then you can put a for duration on the state condition for the binary sensor.

Instead of a time based trigger (which will always be late, especially with strong wind. The basic construct for that is that all conditions you have for the action all need a corresponding trigger. So in this case you need four triggers. The trigger on the aforementioned threshold sensor would also get the same for duration.