SDKsiOS
Retrieve specified friend profiles
Retrieve relationship profiles for specified friends with OpenIM iOS SDK.
When you already know the friends' userID values, retrieve the corresponding OIMFriendInfo objects as needed:
[[OIMManager manager] getSpecifiedFriendsInfo:@[@"user_a", @"user_b"]
filterBlack:YES
onSuccess:^(NSArray<OIMFriendInfo *> *friends) {
[friendStore mergeFriends:friends];
}
onFailure:nil];The first argument is an array of user IDs. filterBlack determines whether blocked users are excluded. The success callback returns matching friend profiles; merge them by userID. An empty array can mean that the targets are not friends or were filtered out.
This query does not trigger a friendship delegate. If you only need to check relationship status, use checkFriend:onSuccess:onFailure:.
Was this page helpful?