Would some one help with this automation, the condition is invalid.
# Doorbell
- alias: Doorbell pressed
initial_state: on
mode: restart
trigger:
platform: event
event_type: xiaomi_aqara.click
event_data:
entity_id: binary_sensor.switch
click_type: single
action:
- service: notify.alexa_media
data:
message: Someone just pressed the doorbell
data:
type: announce
target:
- media_player.kitchen
- media_player.living_room
# Why is this part not valid
- condition:
condition: time
after: "08:00:00"
before: "17:00:00"
# Why is this part not valid
- service: notify.alexa_media
data:
message: Someone just pressed the doorbell
data:
type: announce
target:
- media_player.bedroom_2
basically i dont want the announcement to bedroom at night time