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

Update group profile

Update group display properties including group name, introduction, and avatar URL.

Copy

Invoke setGroupInfo() to modify primary display metadata for a group. Pass only the properties being updated; announcements, verification settings, and member permissions should be managed through their dedicated APIs.

Parameters

ParameterTypeRequiredDescription
groupIDstringYesThe ID of the target group.
groupNamestringNoNew display name for the group.
introductionstringNoNew introduction or description for the group.
faceURLstringNoNew avatar URL for the group.

Supply at least one modification field in addition to groupID.

Code example

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

await setGroupInfo({
  groupID,
  groupName: groupName.trim(),
  introduction: introduction.trim(),
  faceURL,
})

Return value

The Promise resolves with void once OpenIMServer updates the group profile.

State changes after the call

A resolved Promise confirms that the profile update was accepted by the server. Update the local group record optimistically, then confirm final state when onGroupInfoChanged arrives matching groupID. To calibrate state immediately, invoke Get specified group profiles. For complete group event listener registration, see Group overview.