The creator can close the chat room by calling this interface. All online members will be forcibly kicked. The server API:
After logging out of IM using the disconnect method, you can call connect to log in again. After calling getInstance, a persistent connection will be established automatically without calling connect.
chatroom.disconnect({
done: function() {
chatroom.connect()
}
})
Disconnect from Chatroom, and destroy the Chatroom instance. If the instance is destroyed, you cannot call connect to reconnect to the chat room.
Disconnect from Chatroom, but do not destroy the Chatroom instance. You can call connect to connect again
Get the properties of a chat room. The server API:
Log out
Note: For SDK earlier than v9.6.0, it is recommended to logout first and disconnect/destroy to fully exit the chat room.. SDK v9.6.0 and later do not need to call this API, it will be called automatically before disconnect/destroy.
Update the chat room profile. The server API:
Business ID for moderation
Chat room fields to be updated
Extension field
Queue management permissions: 0: everyone has the permission to change the queue, 1: only the anchor administrator can operate the change
extension field of notifications
Whether a notification is required.
callback for the result
Update the tag for the current persistent connection. If you update the tags by calling Server API, tags associated with the current persistent connection.
The extension field of the notification, it is recommended to use a JSON string
Whether a notification is required for update. Default value: false The scope of target members is determined by notifyTargetTags (note that notifyTargetTags can be configured during initialization)
Notification tags. Tag expression, used to notify the members who match the tags, such as the notification for members going online and offline, and updating tags. No value or an empty string indicates notifications are sent to all members.
Tags. * Multiple tags are supported. Subsequent tags overwrite the pervious tags. For example: ["tag1", "tag2"]. To delete tags, set the value to null. An empty array enables the tags but does not belong to any tag.
callback for the result
Basic interface definition of Chatroom instance