Sendbird Firebase push data question


According to the article Push notifications | Chat Android SDK | Sendbird Docs, Sendbird sends push data when chat message is received via firebase when application is in background.

    "category": "messaging:offline_notification",
    "app_id": string,               // Application's unique ID
    "unread_message_count": int,    // Total number of new messages unread by the user
    "channel": {

Property unread_message_count shows the number of total unread message counts on all channels where user is joining. However we want to get unread message count filtered out by channels custom types.

Channel name Custom type Unread messages
google America 30
apple America 20
samsung Korea 30

In this case, I want to get unread message count filtered out by channel custom type ‘America’. I want to receive 50 instead of 80. Is it possible?



Unread message counts are not provided grouped by custom type.

The channel’s unread_message_count represents the number of unread messages for the channel.

The total number of messages for each t type you want is a statistic.

Channels Custom types have many customers who are divided into hundreds or thousands of channels, and it is impossible to provide statistically all of these data at once.

A possible way would be to list the channels of the desired custom type and then sum them.

Hello Scott Kim

I’m not sure you understood my request. I just want to unread_message_count in Firebase push data to deliver some specific channels (filtered out by custom type) unread message count not total channel’s one.

I found Sendbird already provides the number of unread message count filtered out by channel custom type on below. So I think Sendbird can apply same logic to Firebase Push Data too

    public static void getTotalUnreadMessageCount(List<String> channelCustomTypes, GroupChannelTotalUnreadMessageCountHandler handler) {
        localGetTotalUnreadMessageCount((SuperChannelFilter)null, channelCustomTypes, handler);

Yes, you can get UnreadMessageCount of channel custom types through SDK.
Not supported with Sendbird sends push data.