I would like to share here my first blueprint that will monitor all smoke sensors in the system and send notification with definable title and text via notify service.
It assumes that notify service has been configured properly and that there are smoke sensors in the system already
If I have four smoke detectors and a big fire I would have the string value “on,on,on,on” at the end… That does NOT equal “on”
The only case your script works is with ONE smoke detector
This would probably work
"{{ "on" in states.binary_sensor | selectattr('attributes.device_class', 'eq', 'smoke') | map(attribute='state') | list }}"
But I urge everyone to try their script out for themselves, fires are dangerous