ZohoSalesIQChatDelegate

The Mobilisten iOS SDK provides a delegate for various chat event callbacks to help developers track different actions performed by the app user.

ZohoSalesIQChatDelegate Implementation

To start receiving various events within the Mobilisten, your class must conform to the  ZohoSalesIQChatDelegate  protocol. Then, set an instance of your class to the  ZohoSalesIQ.Chat.delegate  property to set your class as the delegate. The delegate methods give an instance of the  SIQVisitorChat  class, which contains information related to the chat.

SIQVisitorChat class contains the following properties:

PropertyDescription
referenceIDID of the chat
questionThe question with which the chat was started
unreadCountUnread message count of the chat
feedbackFeedback provided for the chat
ratingRating given for the chat
statusStatus of the chat
attenderIDUnique ID of the chat attender
isBotAttenderFlag to check if the chat is last attended by a bot
departmentNameDepartment to which the chat is connected to
attenderNameName of the chat attender
attenderEmailEmail ID of the chat attender
lastMessageLast message in the chat
lastMessageSenderName of the last message sender
lastMessageTimeTime when the last message was sent in chat

Supported chat event callbacks

MethodInvoked when
chatOpened:a new chat is initiated by the user
chatAttended:a chat is picked up by an operator or bot
chatMissed:a chat goes missed
chatClosed:a chat is closed
chatReopened:a chat is reopened
chatRatingRecieved:a user rate the chat session
chatFeedbackRecieved:a user provides feedback about the chat session
unreadCountChanged:a unread chat count changes

Setting the delegate

Copiedlet myChatEventHandler = MyChatEventHandler()
ZohoSalesIQ.Chat.delegate = myChatEventHandler