How to template for period in automation condition

Hello,

I’d like to ask for help how to template period of time in condition as follows:

          - condition: state
            entity_id: binary_sensor.0xabcd_contact
            state: 'off'
                for: 
                  seconds: {{ states('input_number.some_number') | int }}
            # this of course works but it's a hardcoded value
            #   seconds: 60

If this is not possible then any suggestion how to work around this would be much appreciated.

Thank you!

All single line templates must be enclosed in quotes

- condition: state
  entity_id: binary_sensor.0xabcd_contact
  state: 'off'
  for:
    seconds: "{{ states('input_number.some_number')|int }}"

Certainly works for triggers as I use it myself, although I did notice that there’s no mention of templating the for fields in the condition documentation.