UnbluClientDelegate
protocol UnbluClientDelegate : AnyObject
The delegate for Unblu. Callbacks are always called on the Main thread.
-
Called when Unblu is initialized
Declaration
Swift
func unbluDidInitialize() -
Called when Unblu is de-initialized
Declaration
Swift
func unbluDidDeinitialize() -
Called when the Unblu UI is ready
Declaration
Swift
func unbluUiIsReady() -
Called when Unblu successfully preloads it’s UI. This will only be called if preloading is enabled via
UnbluClientConfiguration.Declaration
Swift
func unbluDidPreloadUi() -
Called when the Unblu UI inside the
UnbluViewis transitioned, e.g. when the Unblu UI fades in.Declaration
Swift
func unblu(didTransitionUiWithTransition transition: UnbluUiVisibilityTransition) -
Called when the number of unread messages is updated
Declaration
Swift
func unblu(didUpdateUnreadMessages count: Int) -
Called when the
PersonInfois updatedDeclaration
Swift
func unblu(didUpdatePersonInfo personInfo: PersonInfo) -
Called when the
PersonActivityInfois updatedDeclaration
Swift
func unblu(didUpdatePersonActivityInfo personActivity: PersonActivityInfo) -
Called when the current open conversation is changed
Declaration
Swift
func unblu(didChangeOpenConversation openConversation: (any UnbluConversation)?) -
Called when Unblu requests the
UnbluViewis hiddenDeclaration
Swift
func unblu(didRequestHideUi reason: UnbluUiHideRequestReason, conversationId: String?)Parameters
conversationIdThe id of the conversation where the request originated, or nil if the request did not come from a conversation.
-
Called when an
UnbluViewplaced in a modal window is hidden by a swipe down gesture.Declaration
Swift
func didHideModalUi() -
Called when Unblu requests the
UnbluViewis shownDeclaration
Swift
func unblu(didRequestShowUi reason: UnbluUiRequestReason, requestedByUser: Bool)Parameters
requestedByUserA Bool value indicating whether the request was made by the user, e.g. in response to tapping on a notification.
-
Called when the Unblu call UI is shown/hidden
Declaration
Swift
func unblu(didToggleCallUi isOpen: Bool) -
Called when Unblu receives an error
Declaration
Swift
func unblu(didReceiveError type: UnbluClientErrorType, description: String)Parameters
descriptionA String representing more information about the error
-
Called when a custom conversation action was invoked for the mobile SDK
Declaration
Swift
func unblu(onCustomConversationActionInvocation invocation: CustomConversationActionInvocation) -
Called when a custom message action was invoked for the mobile SDK
Declaration
Swift
func unblu(onCustomMessageActionInvocation invocation: CustomMessageActionInvocation) -
Called when a custom person action was invoked for the mobile SDK
Declaration
Swift
func unblu(onCustomPersonActionInvocation invocation: CustomPersonActionInvocation) -
Called when the
ConversationInfos are updatedDeclaration
Swift
func unblu(updatedConversationInfos conversationInfos: [ConversationInfo]) -
Called whenever an active conversation button is clicked to define the behavior and potentially implement a custom handling of clicks
Declaration
Swift
func handleActiveConversationButtonClick() -> ButtonInterceptorAction -
Called each time a menu item or collapse button is clicked.
Declaration
Swift
func handleUnbluCollapsed() -> ButtonInterceptorAction -
Called when the Call UI component lifecycle is about to be changed before it’s either getting created or destroyed. If you need to perform asynchronous work, call
completed()once done.Declaration
Swift
func unblu(onCallUiComponentAction action: UnbluCallUiComponentAction, completed: @escaping () -> Void)Parameters
completedCall to signal that handling is complete so the SDK can respond to the web view.
-
Single-parameter variant. The default implementation calls
completed()immediately.Declaration
Swift
func unblu(onCallUiComponentAction action: UnbluCallUiComponentAction)