Implement Inbox Messaging on Android

The Salesforce Engagement SDK for Android provides convenience methods for refreshing the app inbox and managing messages, including retrieving, reading, and deleting them. Enable inbox messaging during SDK initialization to access message properties, manage Alert + Inbox notifications, and customize message handling for your app users.

Enable Inbox Messaging during the SDK initialization process. The configuration varies based on your SDK version.

1SFMCSdk.configure(applicationContext as Application, SFMCSdkModuleConfig.build {
2  engagementModuleConfig = MarketingCloudConfig.builder().apply {
3    // Other configuration values
4    setInboxEnabled(true) // Enable Inbox messaging, default = false
5  }.build(applicationContext)
6}) {
7  // Handle initialization status
8}
1SFMCSdk.configure(applicationContext as Application, SFMCSdkModuleConfig.build {
2  pushModuleConfig = MarketingCloudConfig.builder().apply {
3    // Other configuration values
4    setInboxEnabled(true) // Enable Inbox messaging, default = false
5  }.build(applicationContext)
6}) {
7  // Handle initialization status
8}
1MarketingCloudSdk.init(applicationContext as Application, with(MarketingCloudConfig.builder()) {
2  // Other configuration values
3  setInboxEnabled(true) // Enable Inbox messaging, default = false
4}.build(applicationContext)) {
5  // Handle initialization status
6}

For more information about inbox message management methods, see InboxMessageManager Method Reference.

Public Properties 

Access inbox message properties to retrieve and manage messages. The SDK provides convenience methods for getting all messages, unread messages, read messages, and deleted messages. Each message object contains properties like ID, subject, dates, custom keys, and message type information.

Alert + Inbox Messages 

Configure Alert + Inbox message handling to enable users to tap on inbox push notifications and get redirected to the corresponding inbox message. Control whether inbox messages are automatically marked as read when users tap notifications.

See Also