NotificationConfig

data class NotificationConfig @JvmOverloads constructor(val pushNotificationsEnabled: Boolean = true, val ignorePushMessagesWhenUserOnline: Boolean = true, val pushDeviceGenerators: List<PushDeviceGenerator> = listOf(), val shouldShowNotificationOnPush: () -> Boolean = { true }, val requestPermissionOnAppLaunch: () -> Boolean = { true }, val autoTranslationEnabled: Boolean = false)

Push notifications configuration class

Constructors

Link copied to clipboard
constructor(pushNotificationsEnabled: Boolean = true, ignorePushMessagesWhenUserOnline: Boolean = true, pushDeviceGenerators: List<PushDeviceGenerator> = listOf(), shouldShowNotificationOnPush: () -> Boolean = { true }, requestPermissionOnAppLaunch: () -> Boolean = { true }, autoTranslationEnabled: Boolean = false)

Properties

Link copied to clipboard

Whether or not the auto-translation feature is enabled.

Link copied to clipboard

Push notifications are ignored and not displayed when the user is online (when there is an active WebSocket connection). Set to false if you would like to receive and handle push notifications even if user is online. Default value is true.

Link copied to clipboard
val pushDeviceGenerators: List<PushDeviceGenerator>

A list of generators responsible for providing the information needed to register a device

Link copied to clipboard

Enables/disables push notifications on the device. Device's token won't be registered if push notifications are disabled.

Link copied to clipboard

Allows SDK to request android.Manifest.permission.POST_NOTIFICATIONS permission for a connected user.

Link copied to clipboard

Allows enabling/disabling showing notification after receiving a push message.