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

Set group member nickname

Modify a member’s group-specific nickname within a designated group.

Copy

Invoke setGroupMemberInfo() to update a member's group-specific nickname. This alias applies strictly within the target group and does not modify the user's account-wide profile nickname.

Parameters

ParameterTypeRequiredDescription
groupIDstringYesTarget group identifier.
userIDstringYesTarget member user ID.
nicknamestringYesNew group-specific nickname.

Code example

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

await setGroupMemberInfo({
  groupID: groupID,
  userID: targetUserID,
  nickname: 'Project Lead',
})

Return value

The Promise resolves with void once OpenIMServer updates the member nickname.

State changes after the call

A resolved Promise confirms that the request completed on OpenIMServer. Connected clients receive onGroupMemberInfoChanged, at which point the UI updates the member's group nickname matching groupID:userID. For complete member event handling, see Get group member list.