I’m trying to create an automation for a fan to run for 30 minutes every 2 hours. I referenced a similar question below before posting (for due diligence), but HA is still generating errors.
When I add the code below, it generates the error “Message malformed: extra keys not allowed @ data[‘alias’]”.
alias: Grow Tent Fan Schedule
description: ''
mode: single
trigger:
- alias: Grow Tent Fan On
- platform: time
at: '00:00:00'
- platform: time
at: '02:00:00'
- platform: time
at: '04:00:00'
- platform: time
at: '06:00:00'
- platform: time
at: '08:00:00'
- platform: time
at: '10:00:00'
- platform: time
at: '12:00:00'
- platform: time
at: '14:00:00'
- platform: time
at: '16:00:00'
- platform: time
at: '18:00:00'
- platform: time
at: '20:00:00'
- platform: time
at: '22:00:00'
action: switch.turn_on
condition: []
action:
- type: turn_on
device_id: c08444c0640cea2370e079d4a99be825
entity_id: switch.grow_tent_fan
domain: switch
- alias: Grow Tent Fan Off
trigger:
- platform: state
device_id: c08444c0640cea2370e079d4a99be825
entity_id: switch.grow_tent_fan
from: 'off'
to: 'on'
for: '00:30:00'
action: