Automatic notification on leaving the home if any door is open

I have 14 Aqara door sensors for all outside doors in my apartment, linked to an Aqara M3 Hub.

What I would like to do is the following: as soon as I leave the home (via geofenced automation), I get a notification that either confirms that all doors are closed, or notifying me that at least one door is open (bonus points if it tells me which door, but that’s not a necessity).

I’ve been trying to set this up in the Aqara app under “Automations”:

  • “All Door Closed” is easy: IF door 1 Is closed & “door 2 Is closed” & … & leave geofenced area (all conditions are met) => Push Notification

  • The opposite “at least one door open” however seems impossible to do with one automation: if I set the conditions to “Any condition is met” (so "Door 1 Open OR Door 2 Open … OR Leave Geofenced Area), it’ll trigger each time I leave the geofenced area, as that condition will be met, and there’s no way to group this logically; what I would need is “IF Leave Geofenced Area AND NOT (Door 1 Closed AND Door 2 Closed…)” or “IF Leave Geofenced Area AND (Door 1 Open OR Door 2 Open …)”, neither of which is doable in automations.

  • I’ve tried setting up individual automations for each door (“IF door X open & leave geofenced area”), but since the app won’t let me set up more than 10 geofenced automations, I can’t do this for all doors…

Does anyone have a clever idea how to do this without integrating yet another third party device into the Aqara ecosystem? Is there any way to simply access a “any door is open” switch for a group of sensors, or something like that?

3 Likes

I haven’t played with the Aqara App much but the easiest way to accomplish this is with a on/off flag. Now I know the Aqara app doesn’t allow for this yet but 15 years ago for my first home automation experience there wasn’t any good tools or apps so I had to create scenes like “Flag ON” or “Flag OFF” and then trigger them inside automations. Then you can have an [ If Scene Flag ON and Leave Geofenced Area ] - send notification

Let me know if this works out!

Hello. In automation 2.0, you can make the following two automations.
1-Name" If I leave, the message “All doors are closed” comes.
If
I leave the zone
AND
(execute all)
Door 1 is closed
Door 2 is closed
Door … is closed
Then
Push message “All doors are closed”
2-Name" If I leave, the message "There are open doors!!! “”
If
I leave the zone
AND
(execute any)
Door 1 is open
Door 2 is open
Door … is open
Then
Push message “There are open doors!!!”
Note, the release of automation 2.0 is planned for autumn.

I do not think you’ll get exactly what you want with the current automation system.

But here is a thing or 2 you can try.

  1. Acting Time / State - under each device in your IF condition there is a button on the right for “Acting Time” where you can set conditions individually “met” or “not met.” If you set your device “Door Is Closed” to Not Met, this might help.

  1. Stacked automations - You could try making two automations, where the first is just triggered on your location and has a second automation as it’s response. And then the second that does IF sensors, Then Notification. Like this:

-IF: Location. → Run Automation
-IF: ANY door sensor IS Open → Notification

The challenge you will still have here is that the second notification is will trigger on it’s own each time a door is left open. But then it will trigger again when you leave home. It’s almost the opposite of your initial problem but might be better than no notifications at all.

Nobody else has picked up on this but…You have 14 outside doors? It’s not Buckingham Palace by any chance?