Automation - door open after sunset

Dear Community,
I try to create an automation to send notification to Telegram if any window or door is kept open after sunset.

this is what I have so far:

alias: door open
description: ''
trigger:
  - platform: sun
    state: below_horizon
condition:
  condition: or
  conditions:
    - condition: state
      entity_id:
        - binary_sensor.bejarati_ajto_contact
        - binary_sensor.garazs_ajto_contact
        - binary_sensor.garazs_kapu_contact
        - binary_sensor.mosokonyha_contact
        - binary_sensor.toloajto_contact
        - binary_sensor.vendegszoba_contact
      state: 'on'
action:
  - data:
      message: Door left open after sunset
    service: notify.b18
mode: single

I got error when I try to save it in YAML editor

Message malformed: extra keys not allowed @ data['state']

please let me know how can I get it to work.
thank you in advance
Gergo

ps: Telegram notifications work in other automations.

It’s either:

trigger:
  - platform: sun
    event: sunset

or

trigger:
  - platform: state
    entity_id: sun.sun
    to: below_horizon

Simply use the visual automation editor.

Christoph,
you are a star!!! thanks a million, it works.