07-04-2024 12:50 PM
I am trying to write a script that will turn my flash my floodlights on and off every second for 2 minutes when I issue the voice command "lights on and off".
I keep getting a validation error 'Required field for Struct is missing. Expected subfields: [type]." on the line
- repeat:
metadata:
name: Lights on and off
description: Turn the floodlight on and off every second for 2 minutes
automations:
- starters:
- type: assistant.event.OkGoogle
eventData: query
is: Lights on and off
actions:
- repeat:
times: 60
actions:
- type: action.devices.commands.OnOff
devices: ["Floodlight - ADU"]
parameters:
on: true
- type: time.delay
duration: 1s
- type: action.devices.commands.OnOff
devices: ["Floodlight - ADU"]
parameters:
on: false
- type: time.delay
duration: 1s
Can anyone see what I am doing wrong?
07-06-2024 12:24 PM
I don't think -repeat is an supported option