Amol Patil
Amol Patil

Reputation: 491

How to get friend request information in quickblox for android

I want to know the current friend request status (if its accepted or still pending) in quickblox for android.Is there any way to store friend request information in quikblox or should i maintain my own remote database?

Upvotes: 0

Views: 513

Answers (1)

Faisal Khan
Faisal Khan

Reputation: 2614

in the onSuccess of Sing into chat use this code

QBRoster chatRosteR=QBChatService.getInstance().getRoster(QBRoster.SubscriptionMode.mutual, subscriptionListener);

and use this listener.

QBSubscriptionListener subscriptionListener = new QBSubscriptionListener() {
    @Override
    public void subscriptionRequested(final int userId) {
        Log.e("friend request", userId + "");
        //friend id
    }
};

Hope this will help you

Upvotes: 2

Related Questions