getDefaultNotificationBuilder
fun getDefaultNotificationBuilder(context: Context, message: NotificationMessage, channelId: String, @DrawableRes smallIconResId: Int): NotificationCompat.Builder
This method will build out a NotificationCompat.Builder with the defaults typically used by the SDK. It will set the following:
title text
alert text
small icon
large icon
big image
sound (Only works on devices prior to Android O)
You will need to set the NotificationCompat.Builder.setContentIntent and wrap the PendingIntent using NotificationManager.redirectIntentForAnalytics to receive open analytics when the notification is clicked.
Return
Parameters
context
The context provided by the SDK.
message
The message provided by the SDK.
channelId
The notification channel ID. If this channel does not exist then your notification will not be displayed on devices running Android O (Oreo) or newer.
smallIconResId
The resource id for the small icon to be used in the notification.