Releases: sendbird/sendbird-chat-sdk-android
Releases · sendbird/sendbird-chat-sdk-android
ktx/4.31.0
Features
- Added support for closing conversation manually for AI Agent in
GroupChannelGroupChannel.awaitCloseConversation()
chat/4.31.0
Features
- Added support for closing conversation manually for AI Agent in
GroupChannelGroupChannel.closeConversation(handler: CompletionHandler?)
ktx/4.30.0
Features
- Added
onConnectionDelayedcallback toConnectionHandler.- A new callback method that is invoked when the server is overloaded. This callback provides information about the delay time before automatic reconnection. After the delayed time period, the SDK automatically initiates reconnection and triggers the callback sequence:
onReconnectStarted→onReconnectSucceededinterface ConnectionHandler { fun onConnected(userId: String) {} fun onDisconnected(userId: String) {} fun onReconnectStarted() {} fun onReconnectSucceeded() {} fun onReconnectFailed() {} /** * A callback for when the connection is delayed. * * @param retryAfter The time in seconds to wait before the next reconnection attempt. */ fun onConnectionDelayed(retryAfter: Long) {} } runCatching { SendbirdChat.awaitConnect(USER_ID, AUTH_TOKEN) }.onSuccess { user -> // Connection successful }.onFailure { e -> val sendbirdException = e as SendbirdException if (sendbirdException.code == SendbirdError.ERR_CONNECTION_DELAYED) { val data = sendbirdException.data // The delay time in seconds before automatic reconnection val retryAfter: Long = data["retry_after"] as? Long ?: 0 // Server-provided reason code for the delay val message = data["message"] as? String ?: "" // Detailed error message explaining the delay val reasonCode: Int = data["reason_code"] as? Int ?: 0 // The SDK will automatically retry after the specified delay time // and the result will be notified through ConnectionHandler.onReconnectSucceeded(). } }
- A new callback method that is invoked when the server is overloaded. This callback provides information about the delay time before automatic reconnection. After the delayed time period, the SDK automatically initiates reconnection and triggers the callback sequence:
- Added
SendbirdChat.Options.setTypingIndicatorInvalidateTime(invalidateTimeMillis: Long)- Sets typing indicator invalidation time. Defaults to 10000 (10 seconds)
Improvements
- Added a condition in
AIAgentGroupChannelListQuery.belongsTo()to exclude non–AI Agent and non–Desk channels from the query results.
chat/4.30.0
Features
- Added
onConnectionDelayedcallback toConnectionHandler.- A new callback method that is invoked when the server is overloaded. This callback provides information about the delay time before automatic reconnection. After the delayed time period, the SDK automatically initiates reconnection and triggers the callback sequence:
onReconnectStarted→onReconnectSucceededinterface ConnectionHandler { fun onConnected(userId: String) {} fun onDisconnected(userId: String) {} fun onReconnectStarted() {} fun onReconnectSucceeded() {} fun onReconnectFailed() {} /** * A callback for when the connection is delayed. * * @param retryAfter The time in seconds to wait before the next reconnection attempt. */ fun onConnectionDelayed(retryAfter: Long) {} } SendbirdChat.connect(USER_ID, AUTH_TOKEN) { user, e -> if (e != null) { if (e.code == SendbirdError.ERR_CONNECTION_DELAYED) { val data = e.data // The delay time in seconds before automatic reconnection val retryAfter: Long = data["retry_after"] as? Long ?: 0 // Server-provided reason code for the delay val message = data["message"] as? String ?: "" // Detailed error message explaining the delay val reasonCode: Int = data["reason_code"] as? Int ?: 0 // The SDK will automatically retry after the specified delay time // and the result will be notified through ConnectionHandler.onReconnectSucceeded(). return@connect } } // Connection successful }
- A new callback method that is invoked when the server is overloaded. This callback provides information about the delay time before automatic reconnection. After the delayed time period, the SDK automatically initiates reconnection and triggers the callback sequence:
- Added
SendbirdChat.Options.setTypingIndicatorInvalidateTime(invalidateTimeMillis: Long)- Sets typing indicator invalidation time. Defaults to 10000 (10 seconds)
Improvements
- Added a condition in
AIAgentGroupChannelListQuery.belongsTo()to exclude non–AI Agent and non–Desk channels from the query results.
ktx/4.29.0
Features
- Added new properties to
Conversation:handedOverAt: Long?— The timestamp when the conversation was handed over to a human agent.aiAgentId: String?— The ID of the AI agent associated with the conversation.
- Added new properties to
GroupChannel:helpdesk: HelpdeskInfo— The helpdesk information of this channel for accessing helpdesk-related data.
Improvements
- Improved SQL safety in SDK local DB
chat/4.29.0
Features
- Added new properties to
Conversation:handedOverAt: Long?— The timestamp when the conversation was handed over to a human agent.aiAgentId: String?— The ID of the AI agent associated with the conversation.
- Added new properties to
GroupChannel:helpdesk: HelpdeskInfo— The helpdesk information of this channel for accessing helpdesk-related data.
Improvements
- Improved SQL safety in SDK local DB
chat/4.28.3
Improvements
- Fixed an issue where
BaseMessage.sendercould contain incorrect data in anOpenChannel
4.28.2
4.28.1
Improvements
- Update the logic for parsing the variables field of
MessageTemplateto use the raw JSON data instead.
4.28.0
Features
-
Added support for managing context objects for AI Agent in
GroupChannelGroupChannel.updateContext(aiAgentId: String, contextMap: Map<String, String>, handler: AIAgentContextHandler?)GroupChannel.patchContext(aiAgentId: String, contextMap: Map<String, String>, handler: AIAgentContextHandler?)GroupChannel.getContextObject(aiAgentId: String, handler: AIAgentContextHandler?)
-
Added AI Agent group channel query APIs to
SendbirdChat.AIAgentcreateMyGroupChannelListQuery()getMyGroupChannelChangeLogsByTimestamp()getMyGroupChannelChangeLogsByToken()getUnreadMessageCount()
Improvements
- Improved
SendbirdChat.init()to handle multiple synchronous calls more reliably