SDKsFlutter
Set group member avatar
Update the in-group avatar for a specified group member using the OpenIM Flutter SDK.
Update the dedicated avatar displayed for a group member within the context of a specific group:
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
groupID | String | Yes | Target group ID. |
userID | String | Yes | Target member user ID. |
faceURL | String | Yes | New avatar URL to display for the member in this group. |
Code example
await OpenIM.iMManager.groupManager.setGroupMemberInfo(
groupMembersInfo: SetGroupMemberInfo(
groupID: groupID,
userID: targetUserID,
faceURL: avatarURL,
),
);An in-group avatar applies only within this specific group and does not modify the user's account-wide profile avatar. To update an account's global avatar, see Update self profile.
Return value
A successful Future indicates that the in-group avatar has been saved on the server.
State changes after the call
Connected clients in the group receive member profile update events. The client updates the local member avatar using groupID:userID as the key. For complete listener integration, see Retrieving group members overview.
Was this page helpful?