logo
In-app Chat
On this page

Function Overview

2026-01-23

ZEGO ZIM SDKs provide rich APIs for you to quickly build in app chat capabilities into your applications.

ZEGO ZIM SDKs are available for all major platforms, including Android, iOS, Mac, Windows, and Web.

MethodDescription
CreateCreate a ZIM instance.
GetVersionGets the SDK's version number.
GetInstanceGet the ZIM singleton object.
SetLogConfigSet log related configuration.
SetCacheConfigSet cache related configuration.
LoginLogin, you must log in before using all functions.
LoginLogin, you must log in before using all functions.
RenewTokenUpdate the authentication token.
QueryUsersInfoQuery user information.
UpdateUserNameUpdate user's user name.
UpdateUserAvatarUrlUpdate user's avatar URL.
UpdateUserExtendedDataUpdate user's user extended data.
UploadLogUpload log and call after setting up log path.
LogoutLog out of ZIM service.
DestroyDestroy the ZIM instance.
OnErrorThe callback for error information.
OnTokenWillExpireA reminder callback that the token is about to expire.
OnUserInfoUpdatedCallback for user information update.
OnUserRuleUpdatedCallback of user rule changes.

Room functions

MethodDescription
CreateRoomCreate and join a room.
QueryRoomMembersQuery the information of up to ten users in the specified room.
SetRoomMembersAttributesSet room member attributes (use this for all additions and changes).
QueryRoomMembersAttributesBatch query the room user attributes of the members in the room.
QueryRoomMemberAttributesListpaginate the room user properties that have room property members in the room.
CreateRoomCreate a room with advanced settings
EnterRoomEnter the room. If the room does not exist, it will be created automatically.
JoinRoomJoin a room.
LeaveRoomLeave a room.
QueryRoomMemberListQuery the list of members in the room.
QueryRoomOnlineMemberCountQuery the number of online members in the room.
QueryRoomAllAttributesQuery all properties of the room.
SetRoomAttributesSet room attributes (use this for all additions and changes).
DeleteRoomAttributesDelete room attributes.
BeginRoomAttributesBatchOperationOpen combination room attribute operation.
EndRoomAttributesBatchOperationComplete the property operation of the combined room.
OnReceiveRoomMessageThe callback for receiving room message.
OnRoomStateChangedevent callback when the room connection status changes.
OnRoomMemberJoinedCallback when other members join the room.
OnRoomMemberLeftCallback when other members leave the room.

Message functions

MethodDescription
SendMessagesend message.
SendMediaMessageSend media messages.
InsertMessageToLocalDBInsert a message to the local DB.
SendConversationMessageReceiptReadSets all received receipts for the conversation as read.
SendMessageReceiptsReadSet the receipt of a batch of messages to become read.
QueryMessageReceiptsInfoQuery the receipt information of a batch of messages.
QueryGroupMessageReceiptReadMemberListQuery the list of read members of the group
QueryGroupMessageReceiptUnreadMemberListQuery the list of read members of the group.
SearchLocalMessagesSearch local message list.
SearchLocalConversationsSearch local conversations on local messages.
SearchGlobalLocalMessagesSearch global local message list.
ReplyMessagesend reply message.
DownloadMediaFileDownload media file message content.
DownloadMediaFileDownload media message content.
QueryHistoryMessageQuery historical messages.
queryPinnedMessageListQuery pinned message list.
RevokeMessagerevoke message.
DeleteMessagesdelete message.
AddMessageReactionadd message reaction
DeleteMessageReactiondelete message reaction
QueryMessageReactionUserListquery message reaction userlist
DeleteAllMessageDelete all message.
UpdateMessageLocalExtendedDataUpdate the local expandable field of the message.
OnMessageRevokeReceivedThe callback for receiving revoke message.
OnMessageSentStatusChangedThe callback for received message send status change.
OnBroadcastMessageReceivedThe callback of the broadcast message received by all employees.
OnMessageReactionsChangedThe callback of the reactions change.
OnMessageDeletedCallback when the message is deleted.
OnReceivePeerMessageThe callback for receiving peer-to-peer message.
OnMessageRepliedCountChangedReply to the event that the number of message trees has changed.
OnMessageRepliedInfoChangedThe reply information of a reply message is changed.
OnReceiveGroupMessageThe callback for receiving group message.

Group functions

MethodDescription
CreateGroupCreate groups.
SearchLocalGroupsSearch local groups.
SearchLocalGroupMembersSearch local group members.
CreateGroupCreate a group with the andvanced info such as group attributes and group notice.
JoinGroupjoin a goup.
LeaveGroupLeave the group.
DismissGroupDisband the group.
KickGroupMemberskick some members out of the group.
InviteUsersIntoGroupinvite some members into the group.
TransferGroupOwnerTransfer the group owner.
UpdateGroupNameUpdate the group name.
UpdateGroupAvatarUrlUpdate the group avatar URL.
UpdateGroupNoticeUpdate group announcements.
QueryGroupInfoQuery group information.
QueryGroupListQuery group list.
SetGroupAttributesAdd or update group attributes.
DeleteGroupAttributesDelete group attribute.
QueryGroupAttributesQuery group attributes by keys.
QueryGroupAllAttributesQuery all attributes of the group.
SetGroupMemberRoleSet the group member role.
SetGroupMemberNicknameSet group member nickname.
QueryGroupMemberInfoQuery group member information.
QueryGroupMemberListQuery the list of group members.
QueryGroupMemberCountQuery the number of group members in a specified group.
OnGroupStateChangedGroup state change notification callback.
OnGroupNameUpdatedGroup name update notification callback.
OnGroupAvatarUrlUpdatedGroup avatar URL update notification callback.
OnGroupNoticeUpdatedNotification callback for group announcement updates.
OnGroupAttributesUpdatedGroup property update attributes callback.
OnGroupMemberStateChangedGroup member state change notification callback.
OnGroupMemberInfoUpdatedGroup member basic information change notification.

Conversation functions

MethodDescription
QueryConversationQuery a conversation by conversation ID and conversation type.
QueryConversationListQuery the conversation list.
QueryConversationPinnedListQuery the conversation pinned list.
UpdateConversationPinnedStateModify the conversation pinned state.
DeleteConversationdelete the conversation.
ClearConversationUnreadMessageCountclear session unreads.
SetConversationNotificationStatusSet the conversation notification state.
OnConversationChangedReceived notification callback for session update.
OnConversationMessageReceiptChangedCallback for notifications of read updates for sessions that receive receipts.
OnConversationsAllDeletedThe callback of all conversation deletion was received.
OnMessageReceiptChangedThe notification callback for the read update of the message that received the receipt.
OnConversationTotalUnreadMessageCountUpdatedNotification callback for session total unread updates.

Call Invitation functions

MethodDescription
CallInviteInitiate a call invitation.
CallCancelCancel the call invitation.
CallAcceptAccept the call invitation.
CallRejectReject the call invitation.
CallQuitReject the call invitation.
CallEndEnd the call invitation.
CallingInviteInvite other users to join the call invitation
QueryCallInvitationListQuery call invitation list
OnCallInvitationReceivedThe notification callback for the call invitation received by the invitee.
OnCallInvitationCreatedThe notification callback for the call invitation created by the caller.
OnCallInvitationCancelledThe notification callback received by the invitee to cancel the invitation.
OnCallInvitationTimeoutCallback for notification of called call invitation timeout.
OnCallInvitationAcceptedThe notification callback received by the inviter that invitee has accepted the invitation.
OnCallInvitationRejectedThe inviter receives the notification callback that the invitee reject the invitation.
OnCallInviteesAnsweredTimeoutCallback for notification of caller call invitation timeout.
OnCallInvitationEndedCallback for notification of caller call invitation ended.
OnCallUserStateChangedCall the notification of the user status in the invitation invitation.

Previous

FAQ

Next

Class

On this page

Back to top