Browse SDKs · uni-app / uni-app x
SDKsuni-app

Get selected friend profiles

Read friendship details for selected user IDs.

Copy
import { getSpecifiedFriendsInfo } from '@/uni_modules/unix-openim-sdk'

const result = await getSpecifiedFriendsInfo({
  userIDList: ['user_a', 'user_b'],
  filterBlack: false,
})
const friends = result?.friends ?? []

The result can be shorter or differently ordered. Map it by userID; missing users may not be friends, may be filtered, or may be inaccessible. filterBlack changes this result only and never removes blacklist relationships.