I an trying to write a script but I am new to HA, I have given it my best shot but computer says no. How do I get the script god to accept my YAML? Do I have to sacrifice my children?
Message malformed: extra keys not allowed @ data[‘pump_timer_script’]
pump_timer_script:
alias: Pump and Solenoid Sequence
sequence: [
- service: switch.turn_on
entity_id:
- switch.a16_pump1
- switch.switch.a16_sol1
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol1
- service: switch.turn_on
entity_id: switch.a16_sol2
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol2
- service: switch.turn_on
entity_id: switch.a16_sol3
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol3
- service: switch.turn_on
entity_id: switch.a16_sol4
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol4
- service: switch.turn_on
entity_id: switch.a16_sol5
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol5
- service: switch.turn_on
entity_id: switch.a16_sol6
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol6
- service: switch.turn_on
entity_id: switch.a16_sol7
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id: switch.a16_sol7
- service: switch.turn_on
entity_id: switch.a16_sol8
- delay:
seconds: "{{ states('input_number.spray_time') | int }}"
- service: switch.turn_off
entity_id:
- switch.a16_pump1
- switch.a16_sol8
- delay:
minutes: "{{ states('input_number.wait_time') | int }}"
- service: script.turn_on
target:
entity_id: script.pump_timer_script
]