heihei blog

Blog icon by Unsplash https://unsplash.com/@virussinside

Notes - Modern Android Notifications (Android Dev Summit '18)


本記事は、Modern Android Notifications (Android Dev Summit '18)の記事です。


  • Respect user's settings
  • Send well-structured notification
  • Send relevant and timely notification
  • Make use of Auto-cancelling
  • Make use of Timeouts
  • No notifications that are not actionable

Notification Channels

  • Used to empower users
  • Help user categorize the notification
  • Help user customize the setting


  • Don't use only one channel
  • Don't use wrong/blocked channel

What's new in Notifications

  • API 28: New person class
// create new Person
val sender = Person.Builder().setName(name)

// create message with image
val message = Notification.MessagingStyle.Message("Picture", time, sender)
  .setData("image/", imageUri)

val style = Notification.MessagingStyle(sender)
  .addMessage("Check this out!", time, sender)

val builder = Notification.Builder(this, CHANNEL_ID)


  • Do not auto-cancel messaging notification after sending
    • Let user swipe the notification when they finish their conversation

Digital Wellbeing

  • Overview of app usage
  • Dashboard for notification received, time spending on apps
  • To manage notifications, reduce interruptions

How are notifications counted?

=> If notifications were sent to blocked channel they are not counted, otherwise counted.

Reduce interruptions

  • Empower user

Work with Do not Disturb

  • Set category
  • Tag people
    • Add person
    • Set the URI associated with the person


Don't annoy the user. Respect them. Empower them. Delight them.

Connect them to the people they care about.