Channel Push Notification Settings

Activate / Deactivate Channel Push Notification

You can enable or disable channel push notification settings for current user.

// activate
TalkPlus.enableChannelPushNotification(channel, 
    new TalkPlus.CallbackListener<TPChannel>() {
        @Override
        public void onSuccess(TPChannel tpChannel) {
        }
        @Override
        public void onFailure(int errorCode, Exception exception) {
        }
    }
);

// deactivate
TalkPlus.disableChannelPushNotification(channel, 
    new TalkPlus.CallbackListener<TPChannel>() {
        @Override
        public void onSuccess(TPChannel tpChannel) {
        }
        @Override
        public void onFailure(int errorCode, Exception exception) {
        }
    }
);

Channel Push Notification Settings (Sound)

You can change channel push notification (FCM) sound settings for current user.

// change channel notification sound
TalkPlus.setChannelPushSound(channel, 
    "mySound.mp3", 
    new TalkPlus.CallbackListener<TPChannel>() {
        @Override
        public void onSuccess(TPChannel tpChannel) {
        }
        @Override
        public void onFailure(int errorCode, Exception exception) {
        }
    }
);

Last updated