Browse SDKs · WASM
SDKsWASM

Search group members

Search for members in a specified group.

Copy

Use searchGroupMembers() to find members or populate a list of @ mention candidates. The current API only uses the first entry in keywordList.

Parameters

ParameterTypeRequiredDescription
groupIDstringYesID of the target group.
keywordListstring[]YesSearch keywords.
isSearchUserIDbooleanYesWhether to match user IDs.
isSearchMemberNicknamebooleanYesWhether to match nicknames within the group.
offsetnumberYesPagination offset. Pass 0 for the first page.
countnumberYesMaximum number of members to retrieve.
const { data: members } = await openimsdk.searchGroupMembers({
  groupID,
  keywordList: [keyword.trim()],
  isSearchUserID: true,
  isSearchMemberNickname: true,
  offset: 0,
  count: 50,
});

When the Promise resolves, data is the current page of matching GroupMemberItem[]. For field descriptions, see List group members. Search results are a member snapshot for the current keyword and must not replace the complete member list.

Reset pagination whenever the keyword or filter criteria change.