Condition for action notification

Hello everyone,

I created a notification when someone rings the gate, I integrated an action into it “open the gate”.
Everything works fine, but I want this action not to appear if the portal is open

alias: Ouverture portail notification
description: ""
trigger:
  - platform: state
    entity_id:
      - binary_sensor.vto_doorbell
    from: "off"
    to: "on"
condition: []
action:
  - service: notify.mobile_app_iphone_4
    data:
      message: "Quelqu’un sonne au portail "
      title: Dingdong
      data:
        entity_id: camera.192_168_0_72
        presentation_options:
          - alert
          - badge
        conditon:
          - condition: state
            entity_id: binary_sensor.smart_implant_portail
        state: "off"
        actions:
          - action: ouverture_portail
            title: Ouvrir le portail
mode: single

You’ve mis-spelled condition and the state: "off" should be at the same level of indentation as the entity_id.

I don’t believe you can have a condition there anyway… why not put it in the main condition block above if the notification is the only thing in the action?

Thanks, I’ll try like that :grinning:
Because I still want to be notified if someone rings.