#create a notify group for persons currently in a zone

1 messages · Page 1 of 1 (latest)

tough ingot
#

I'd like to create a notify group to use in automations that changes dynamically for the current people in a zone. I don't want HA to be spamming the families' phones when they're not at home.

I'd like to use this for notifications when the washer, dryer, dishwasher finish, or if someone left the freezer door opened and the temperature raised by more than so many degrees, etc.

What is the best approach to accomplish this?

radiant shale
#

The zone should have an attribute with a list of the persons in it. I'm not sure the exact syntax to pull that out though and do what you want but it should be possible.

wind pilot
#

like so :

{{ state_attr('zone.home', 'persons') }}
radiant shale
#

That's exactly what I was trying to find. I was bumbling around in the template editor with it.

wind pilot
#

but I think it needs a bit more to work

#

cause the person.name that it returns doesn't have a notify thingy by default

#

but that can be fixed with some yaml in configuration.yaml...

#
radiant shale
wind pilot
#

that is the best way

#

ehm no not states

#

Template

#

Developer tools --> Template

radiant shale
#

When I put that in there I just get null or None even though when I check the States it shows my person in the zone.

wind pilot
#

is the zone correct?

#

I mean is your entity also zone.home

radiant shale
#

Ya. I wasn't sure if I needed to wrap it in some logic to make it display.

wind pilot
radiant shale
#

I had home.zone instead.... that'd do it. Thanks!

wind pilot
#

hehe 🙂

#

no worries happens to the best 😉

tough ingot
#

I was thinking it would somehow be a drill down from zone -> persons -> devices -> mobile...

winged aurora
#

Notify actions or entities are not tied to a person entity. You'd need to create some mapping in the automation