Hey everyone,
I'm trying to smack a bunch of conditionals all into one automation to avoid covering the same concept with multiples and I'm not really managing to do so.
I want to set it up so that when I charge my phone in bed and either my wife is also charging her phone OR she's not home, the lights turn off.
There's a few other conditions involved but it's this "Me and her or me and shes not here" condition that i can't seem to figure out.
description: >-
Lights turn off after 10:30pm when my phone is charging and either Haruka and I are in the bedroom or just I am and Haruka is not home.
triggers:
- entity_id: sensor.jamie_mobile_battery_state
to: charging
trigger: state
conditions:
- condition: time
after: "22:30:00"
- condition: state
entity_id: sensor.kansaigaijinpc_monitorpowerstate
state: PowerOff
- condition: state
entity_id: sensor.jamies_mobile_ibeacon
state: bedroom
and
- condition: state
entity_id: sensor.harukas_mobile_ibeacon
state: charging
or
- condition: state
entity_id: sensor.haruka_location
state: not_home
actions:
- target:
entity_id: group.house_lights
action: homeassistant.turn_off
data: {} ```
I added the `and` `or` comments to show you what I'm wanting but don't know how to write it correctly.
I get `Message malformed: required key not provided @ data['actions']` but the actions section hasn't been touched from the currently working automation?