Android: Add support for notification channels

Created on 4 Dec 2019  路  7Comments  路  Source: home-assistant/android

I know we don't have notifications yet but it would be great if we can add support for notification channels once we do. Its important to differentiate notifications so the user can set the priority and sound. For example you don't want your phone making the same sound for the alarm being triggered as it does for the laundry.

https://developer.android.com/reference/android/app/NotificationChannel

enhancement notifications

Most helpful comment

My understanding is that notification channels are static and must be defined in AndroidManifest.xml which means we can't modify it during runtime.

Firebase Cloud Messaging allows defining things like sound and priority on a per notification basis.

All 7 comments

My understanding is that notification channels are static and must be defined in AndroidManifest.xml which means we can't modify it during runtime.

Firebase Cloud Messaging allows defining things like sound and priority on a per notification basis.

Not sure if they can be defined in the manifest but they can definitely be added and modified programmatically.

@quthla yup, my ring app does that as i add/remove ring devices.

My bad, I misread the FCM docs!

this will also support different messages being able to be send in do not disturb mode.
So same as critical messages on iphone.

Even static notification channels would be good. Like 3 channels for priorities like "low", "normal, "critical" so we can customize the channels with different sounds and settings in the android.
I'd like to set up critical notifications for things like "flooded bathroom" that ignore do not disturb mode but at the same time I don't want to low priority notifications like "plant needs water" to wake me up at night.

Closed by #574 currently waiting on https://github.com/home-assistant/mobile-apps-fcm-push/pull/13 to be merged so the feature can work properly. Once its working will get the docs updated.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tiagofreire-pt picture tiagofreire-pt  路  3Comments

Anonym-tsk picture Anonym-tsk  路  3Comments

N-Schaef picture N-Schaef  路  5Comments

Hypfer picture Hypfer  路  3Comments

andriej picture andriej  路  4Comments