Update group profile
Modify a group’s display name, introduction summary, and avatar URL.
Update basic group attributes from a profile editing form. Include only fields that have changed, and provide at least one mutable field alongside groupID. Do not mix announcements, join verification rules, or permission flags into this general profile update:
Code example
import sdk, { SetGroupInfoReq } from '@openimsdk/imsdk';
const request: SetGroupInfoReq = {
groupID: groupID,
groupName: groupName.trim(),
introduction: introduction.trim(),
faceURL: faceURL,
};
await sdk.setGroupInfo(request);Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
groupID | string | Yes | Target group identifier. |
groupName | string | No | New group display name. |
introduction | string | No | New group introduction text. |
faceURL | string | No | New group avatar image URL. |
Return value
Returns a Promise that resolves to void upon updating the group on the server.
State changes after the call
Resolving the Promise confirms that the server accepted the updates; it does not mean that the group change event has reached every member device yet. When EventOnGroupInfoChanged arrives, update local group state keyed by groupID. For event listener patterns, see Group overview. To fetch authoritative data immediately, call Retrieve specified group profiles.
Was this page helpful?