Pat Long - Munkii Yebee
Pat Long - Munkii Yebee

Reputation: 3629

Android Notifications - Popup but with no Sound

We are sending Push Notifcations to our Android app. We want them to appear as a "Pop-Up" by default.

The only way I have been able to get that to work dfo that seend to do that is to target a specific notification channel with an Importance of High.When we do that we do get a visible pop-up for our Notification.

The problem with setting the importance is that by default we then get a Sound playing as well.

  1. Is the only way to get a Pop-Up to use a High Importance channel?
  2. If using a High Importance channel how to we specify a sound of "Silent"?

Upvotes: 0

Views: 558

Answers (1)

Ganso Doido
Ganso Doido

Reputation: 607

As far I know you will have to set the channel sound explicitly to null:

channel.setSound(null, null)

The problem is that Android does not allow you to change a Channel sound configuration after creation. You may need to use another channel with importance HIGH and sound set to null. Hope it helps.

Upvotes: 1

Related Questions