Door opened Voice A

Hi I have simple automatisation door opened:

alias: Voice Info Garaż Otwarty
description: Voice Assistant Informacja głosowa o otwartym garażu.
triggers:

  • trigger: state
    entity_id:
    • binary_sensor.0xa4c138da31719486_contact
      from: “off”
      to: “on”
      conditions:
      actions:
  • action: google_generative_ai_conversation.generate_content
    metadata: {}
    data:
    prompt: >-
    Powiedz w śmieszny sposób, że drzwi od garażu są otwarte. Maksmymalnie 1
    zdanie.
    response_variable: response
  • action: assist_satellite.announce
    metadata: {}
    data:
    message: “{{ response.text }}”
    target:
    entity_id: assist_satellite.home_assistant_voice_09641e_assist_satellite
    mode: single

and door closed

alias: Voice Assistant Info garaż zamknięty
description: Voice Assistant Informacja głosowa o otwartym garażu.
triggers:

  • trigger: state
    entity_id:
    • binary_sensor.0xa4c138da31719486_contact
      from: “on”
      to: “off”
      conditions:
      actions:
  • action: google_generative_ai_conversation.generate_content
    metadata: {}
    data:
    prompt: >-
    Powiedz w śmieszny sposób, że drzwi od garażu są zamknięte. Maksmymalnie
    1 zdanie.
    response_variable: respons
  • action: assist_satellite.announce
    metadata: {}
    data:
    message: “{{ respons.text }}”
    target:
    entity_id: assist_satellite.home_assistant_voice_09641e_assist_satellite
    mode: single

I need help with this becouse when door are opened I whould like to check automatically after detection of door opening until closing by Voice Assistant every 30 minutes and tell me that the doors are opened. (prompt)

Next door closed I whould like set a notification if the door is closed at selected times e.g.:
17:00
20:00
21:00
22:00
An additional feature would be to add, for example, a blinking light bulb for 60 seconds
And thats it :slight_smile:

You need separate automations to check whether the door is open - it’s not a good idea to keep one running for long periods of time. So the trigger for the 30 minute check would be:

triggers:
  - trigger: time_pattern
    minutes: "/30"

…with a condition that the door is open.

The trigger for checks at specific times would be:

triggers:
  - trigger: time
    at: "17:00:00"
  - trigger: time
    at: "20:00:00"
  - trigger: time
    at: "21:00:00"
  - trigger: time
    at: "22:00:00"