Hi All
I am not sure if this is a indent error or a condition error in my code?
I have created this as my first IOS notification test
automation:
- alias: 'IOS Notification: Outdoor lights change'
trigger:
- platform: state
entity_id: switch.sonoff_pow_r2
condition:
- condition: state
entity_id: device_tracker.caspersensiphone
state: not_home
action:
- service: notify.ios_caspersensiphone
data:
message: 'Outdoor light triggered'
And I did the “-” because I want to add more automation but when I try to add any more I keep getting errors
and I cant find any alignement errors?
automation:
- alias: 'IOS Notification: Outdoor lights change'
trigger:
- platform: state
entity_id: switch.sonoff_pow_r2
condition:
- condition: state
entity_id: device_tracker.caspersensiphone
state: not_home
action:
- service: notify.ios_caspersensiphone
data:
message: 'Udendørsbelysning triggered'
- alias: "IOS Notification: Victoria out"
trigger:
- condition: state
entity_id: device_tracker.victoriasiphone
state: not_home
action:
- service: notify.ios_group_caspersen_home
data:
message: "Victoria Out"
I then get this error
Validate your configuration if you recently made some changes to your configuration and want to make sure that it is all valid
Konfigurationen ugyldig
Invalid config for [automation]: required key not provided @ data[‘trigger’][0][‘platform’]. Got None. (See /config/configuration.yaml, line 383). Please check the docs at https://home-assistant.io/components/automation/
The line is the first line “automation”, which indicate alignment error?
I just cant find any errors looking at this guide: