Documentation
zim_API In-app Chat
Documentation
Demo APP
SDK Center
API Center
FAQ
Code Market
Console
Sign Up
Log In
中文站 English
  • Documentation
  • In-app Chat
  • Function Overview
  • Function Overview

Function Overview

Last updated:2025-03-22 00:13

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.

SDK Initialization Related Functions

Method Description
querySubscribedUserStatusList This command is used to query the user status subscription list of the current user.
queryUsersStatus Query the user statuses of other users.
subscribeUsersStatus Subscribe to the user status of other users
unsubscribeUsersStatus This command is used to batch unsubscribe the target users in the current user subscription list.
updateUserOfflinePushRule Modify the custom rule of offline push
querySelfUserInfo Query user information and user rules.
create Create a ZIM instance.
create Create a ZIM instance.
getVersion Gets the SDK's version number.
getInstance Get the ZIM singleton object.
setEventHandler Set the event notification callbacks that need to be handled. If the eventHandler is set to [null], all the callbacks set previously will be cleared.
setLogConfig Set log related configuration.
setGeofencingConfig Set geofence-related configurations.
setCacheConfig Set cache related configuration.
login Login, you must log in before using all functions.
login Login, you must log in before using all functions.
login Login, you must log in before using all functions.
renewToken Update the authentication token.
queryUsersInfo Query user information.
updateUserName Update user's user name.
updateUserAvatarUrl Update user's avatar URL.
updateUserExtendedData Update user's user extended data.
uploadLog Upload log and call after setting up log path.
logout Log out of ZIM service.
destroy Destroy the ZIM instance.
onError The callback for error information.
onTokenWillExpire A reminder callback that the token is about to expire.
onUserInfoUpdated Callback for user information update.
onUserRuleUpdated Callback of user rule changes.

Room functions

Method Description
createRoom Create and join a room.
queryRoomMembers Query the information of up to ten users in the specified room.
setRoomMembersAttributes Set room member attributes (use this for all additions and changes).
queryRoomMembersAttributes Batch query the room user attributes of the members in the room.
queryRoomMemberAttributesList paginate the room user properties that have room property members in the room.
createRoom Create a room with advanced settings
enterRoom Enter the room. If the room does not exist, it will be created automatically.
switchRoom Switch from one room to another. If the room does not exist, it will decide whether to create the corresponding room based on the passed parameters.
joinRoom Join a room.
leaveRoom Leave a room.
leaveAllRoom Leave all rooms entered.
queryRoomMemberList Query the list of members in the room.
queryRoomOnlineMemberCount Query the number of online members in the room.
queryRoomAllAttributes Query all properties of the room.
setRoomAttributes Set room attributes (use this for all additions and changes).
deleteRoomAttributes Delete room attributes.
beginRoomAttributesBatchOperation Open combination room attribute operation.
endRoomAttributesBatchOperation Complete the property operation of the combined room.
onReceiveRoomMessage The callback for receiving room message.
onRoomStateChanged event callback when the room connection status changes.
onRoomMemberJoined Callback when other members join the room.
onRoomMemberLeft Callback when other members leave the room.

Message functions

Method Description
editMessage Edit message.
sendMessage send message.
sendMediaMessage Send media messages.
insertMessageToLocalDB Insert a message to the local DB.
clearLocalFileCache Clear the local message cache of the current user.
queryLocalFileCache Query the local message cache of the current user.
exportLocalMessages Example Export the local message of the current user.
importLocalMessages Example Import the local message of the current user.
sendConversationMessageReceiptRead Sets all received receipts for the conversation as read.
sendMessageReceiptsRead Set the receipt of a batch of messages to become read.
queryMessageReceiptsInfo Query the receipt information of a batch of messages.
queryGroupMessageReceiptReadMemberList Query the list of read members of the group
queryGroupMessageReceiptUnreadMemberList Query the list of read members of the group.
searchLocalMessages Search local message list.
searchLocalConversations Search local conversations on local messages.
searchGlobalLocalMessages Search global local message list.
replyMessage send reply message.
queryMessageRepliedList Query the reply list.
sendMediaMessage Send media messages.
downloadMediaFile Download media file message content.
downloadMediaFile Download media message content.
sendPeerMessage Send peer-to-peer messages.
sendRoomMessage Send room messages.
sendGroupMessage Send group messages.
queryHistoryMessage Query historical messages.
queryMessages Query messages based on the message seq list.
deleteAllConversationMessages Delete all messages for all sessions.
queryCombineMessageDetail query combine message detail
revokeMessage revoke message.
deleteMessages delete message.
addMessageReaction add message reaction
deleteMessageReaction delete message reaction
queryMessageReactionUserList query message reaction userlist
deleteAllMessage Delete all message.
updateMessageLocalExtendedData Update the local expandable field of the message.
onGroupMessageReceived The callback for receiving group message.
onPeerMessageReceived The callback for receiving peer-to-peer message.
onRoomMessageReceived The callback for receiving room message.
onMessageEdited The callback for receiving edited message.
onMessageRevokeReceived The callback for receiving revoke message.
onMessageSentStatusChanged The callback for received message send status change.
onBroadcastMessageReceived The callback of the broadcast message received by all employees.
onMessageReactionsChanged The callback of the reactions change.
onMessageDeleted Callback when the message is deleted.
onReceivePeerMessage The callback for receiving peer-to-peer message.
onMessageRepliedCountChanged Reply to the event that the number of message trees has changed.
onMessageRepliedInfoChanged The reply information of a reply message is changed.
onReceiveGroupMessage The callback for receiving group message.

Group functions

Method Description
createGroup Create groups.
searchLocalGroups Search local groups.
searchLocalGroupMembers Search local group members.
createGroup Create a group with the andvanced info such as group attributes and group notice.
joinGroup join a goup.
leaveGroup Leave the group.
dismissGroup Disband the group.
kickGroupMembers kick some members out of the group.
inviteUsersIntoGroup invite some members into the group.
transferGroupOwner Transfer the group owner.
updateGroupAlias Update the group alias.
updateGroupName Update the group name.
muteGroup Mute a group
muteGroupMembers Mute group members.
updateGroupAvatarUrl Update the group avatar URL.
updateGroupNotice Update group announcements.
updateGroupJoinMode Update group verification mode.
updateGroupInviteMode Update group verification mode.
acceptGroupInviteApplication Accept an application to invite to the group.
acceptGroupJoinApplication Accept an application to join the group.
queryGroupApplicationList Query the group application list.
rejectGroupInviteApplication Reject an application to invite to the group.
rejectGroupJoinApplication Reject an application to join the group.
sendGroupInviteApplications Send an application to invite the group.
sendGroupJoinApplication Send an application to join the group.
updateGroupBeInviteMode Update group verification mode.
queryGroupInfo Query group information.
queryGroupList Query group list.
setGroupAttributes Add or update group attributes.
deleteGroupAttributes Delete group attribute.
queryGroupAttributes Query group attributes by keys.
queryGroupAllAttributes Query all attributes of the group.
setGroupMemberRole Set the group member role.
setGroupMemberNickname Set group member nickname.
queryGroupMemberInfo Query group member information.
queryGroupMemberList Query the list of group members.
queryGroupMemberMutedList Query the list of group muted members.
queryGroupMemberCount Query the number of group members in a specified group.
onGroupStateChanged Group state change notification callback.
onGroupAliasUpdated Group alias update notification callback.
onGroupNameUpdated Group name update notification callback.
onGroupAvatarUrlUpdated Group avatar URL update notification callback.
onGroupNoticeUpdated Notification callback for group announcement updates.
onGroupMutedInfoUpdated Notification callback for group mute info updates.
onGroupVerifyInfoUpdated Notification callback for group verification mode update.
onGroupAttributesUpdated Group property update attributes callback.
onGroupMemberStateChanged Group member state change notification callback.
onGroupMemberInfoUpdated Group member basic information change notification.
onGroupApplicationListChanged This method will be called back when the group application list changes.
onGroupApplicationUpdated This method will be called back when the group application list changes.

Conversation functions

Method Description
queryConversation Query a conversation by conversation ID and conversation type.
queryConversationList Query the conversation list.
queryConversationList Query the conversation list by filter options.
queryConversationPinnedList Query the conversation pinned list.
queryConversationTotalUnreadMessageCount Query the conversations total unread message count by config.
updateConversationPinnedState Modify the conversation pinned state.
deleteAllConversations delete all conversations.
deleteConversation delete the conversation.
setConversationDraft Set a conversation draft.
clearConversationTotalUnreadMessageCount clear all conversations unreads.
clearConversationUnreadMessageCount clear session unreads.
setConversationMark Set or unset conversation marks.
setConversationNotificationStatus Set the conversation notification state.
onConversationChanged Received notification callback for session update.
onConversationMessageReceiptChanged Callback for notifications of read updates for sessions that receive receipts.
onConversationsAllDeleted The callback of all conversation deletion was received.
onMessageReceiptChanged The notification callback for the read update of the message that received the receipt.
onConversationTotalUnreadMessageCountUpdated Notification callback for session total unread updates.

Call Invitation functions

Method Description
callInvite Initiate a call invitation.
callJoin Join an advanced mode call, or switch the main device for the advanced mode call (multi-terminal login only).
callCancel Cancel the call invitation.
callAccept Accept the call invitation.
callReject Reject the call invitation.
callQuit Reject the call invitation.
callEnd End the call invitation.
callingInvite Invite other users to join the call invitation
queryCallInvitationList Query call invitation list
onBlacklistChanged This method will be called back when the blacklist is updated or changes occur.
onCallInvitationReceived The notification callback for the call invitation received by the invitee.
onCallInvitationCreated The notification callback for the call invitation created by the caller.
onCallInvitationCancelled The notification callback received by the invitee to cancel the invitation.
onCallInvitationTimeout Callback for notification of called call invitation timeout.
onCallInvitationAccepted The notification callback received by the inviter that invitee has accepted the invitation.
onCallInvitationRejected The inviter receives the notification callback that the invitee reject the invitation.
onCallInviteesAnsweredTimeout Callback for notification of caller call invitation timeout.
onCallInvitationEnded Callback for notification of caller call invitation ended.
onCallUserStateChanged Call the notification of the user status in the invitation invitation.

Blacklist functions

Method Description
addUsersToBlacklist Add users to blacklist.
removeUsersFromBlacklist Remove the user from the blacklist.
queryBlacklist Query the blacklist.
checkUserIsInBlacklist Check if the user is on the blacklist.

Friend functions

Method Description
addFriend Add friends directly.
sendFriendApplication Send a friend application.
deleteFriends Delete friends.
checkFriendsRelation Check friend relationships.
updateFriendAlias Update friend alias.
updateFriendAttributes Update friend attributes.
acceptFriendApplication Accept to friend request.
rejectFriendApplication Accept to friend request.
queryFriendsInfo Query friend information in batches.
queryFriendList Query the friends list.
queryFriendApplicationList Query the friend application list.
searchLocalFriends Search local friends.
onFriendListChanged This method will be called back when the friend list is updated or changes occur.
onFriendApplicationListChanged This method will be called back when the friend application list changes.
onFriendApplicationUpdated The current method will be called when there is an update in the friend request list.
onFriendInfoUpdated This callback will be triggered when there is an update in the friend information.
Page Directory
  • Free trial
  • 提交工单
    咨询集成、功能及报价等问题
    电话咨询
    400 1006 604
    Get Consulting
    Scan Wechat QR code