What are the configuration settings for the ASAP iOS SalesIQ SDK?

What are the configuration settings for the ASAP iOS SalesIQ SDK?

Notes
The SalesIQ configuration included in the ASAP SDK from version 4.0.6 has some changes. In earlier versions leading up to 4.0.6, the preChatForm was set to disabled by default. However, starting from version 4.0.6, it will now be enabled by default. Please make sure to adjust your configurations accordingly.
To use SalesIQ configurations, import the ZohoDeskPortalSalesIQ module:
  1. import ZohoDeskPortalSalesIQ

setCallbackOnInit

For the SalesIQ configuration, you need to set up all the required configurations using the ZDPortalSalesIQ.setCallbackOnInit method.
Notes
Set this callback before the ASAP SDK initialization.
Parameters:
  1. onSuccess - A closure that is called when the SalesIQ SDK is successfully initialised.
  2. onError - A closure that is called when the SDK initialization fails.
Example

An example SalesIQ configuration set within the callback
  1. ZDPortalSalesIQ.setCallbackOnInit (
  2. onSuccess: {// On successfully initializing SalesIQ
  3.      //Add SalesIQ configurations here
  4.     },
  5.     onError: {//On Failed
  6.          print("Failed while initilaizing the SalesIQ")
  7. }
  8. )
For additional code snippet examples, refer here.

ShowLauncher

The ZDPortalSalesIQ.showLauncher(_ mode: ZDPSalesIQComponents.VisibilityMode) API allows you to manage the SalesIQ launcher's visibility based on the specified visibility mode.

Parameters of VisibilityMode:
  1. .always - The launcher will always be visible.
  2. .never - The launcher will always be hidden.
  3. .whenActiveChat - The launcher will be visible only when there is an active chat.
  1. ZDPortalSalesIQ.showLauncher(.never)

enableDragToDismiss

The ZDPortalSalesIQ.enableDragToDismiss(_ enable: Bool) allows you to close the SalesIQ launcher by dragging it and dropping it onto the close button.
  1. ZDPortalSalesIQ.enableDragToDismiss(false)

setConversationVisibility

This ZDPortalSalesIQ.setConversationVisibility(_ visible: Bool) API can turn the visitor conversation history on or off in the salesiQ UI.

Parameters:
  1. true - Displays the conversation screen. (Default) 
  2. false - Hides the conversation screen.
Notes
This API cannot enable conversation history in UI if it is disabled in portal settings.
  1. ZDPortalSalesIQ.setConversationVisibility(true)

setConversationTitle

This ZDPortalSalesIQ.setConversationTitle(_ title: String) API allows you to set the title for the conversations list screen in SalesIQ.
  1. ZDPortalSalesIQ.setConversationTitle("Conversations")

showOfflineMessage

The showOfflineMessage(_ show: Bool) API enables the display of an offline banner in the chat window during non-business hours, allowing visitors to leave a message even when agents are unavailable.

Parameters:
  1. true - Displays the offline message card. (Default) 
  2. false - Hides the offline message card.
  1. ZDPortalSalesIQ.showOfflineMessage(true)

setOfflineMessage

This ZDPortalSalesIQ.setOfflineMessage(_ message: String) API allows you to set the offline message in the salesIQ screen.
  1. ZDPortalSalesIQ.setOfflineMessage("Agents are currenlty offline. Please try again later.")

showFeedbackAfterSkip

The ZDPortalSalesIQ.showFeedbackAfterSkip(_ show: Bool) API allows you to manage the duration of the feedback card for 24 hours after the chat ends.

Parameters:
  1. true - The feedback card will be displayed permanently. (Default)
  2. false - The feedback card will displayed for 24 hours until feedback is given.
Notes
The feedback card will always have the Skip option. When enabled, it is "false," and the card is clicked on Skip. It will not be displayed again until the next chat.
  1. ZDPortalSalesIQ.showFeedbackAfterSkip(false)

hideQueueTime

The ZDPortalSalesIQ.hideQueueTime(_ show: Bool) API controls the visibility of the chat queue time in the chat window when connecting to an operator. 

Parameter:
  1. true - This hides chat queue time. (Default)
  2. false - This displays the chat Queue Time.
  1. ZDPortalSalesIQ.hideQueueTime(true)

setLoggerEnabled

This  ZDPortalSalesIQ.setLoggerEnabled(_ enable: Bool) API lets you request your application debug logs from visitors. By setting the bool value, you can enable or disable the request app log feature for your operators in the SalesIQ dashboard.

Parameter:
  1. true - Enables the logs.
  2. false - Disables the logs. (Default)
  1. ZDPortalSalesIQ.setLoggerEnabled(true)

setKnowledgeBaseVisibility

The ZDPortalSalesIQ.setKnowledgeBaseVisibility(_ enable: Bool) API allows you to manage the resource's visibility in the Mobilisten knowledge base section.

Parameters:
  1. true - This will display the resource. (Default)
  2. false - This will hide the resource.
Notes
The API will work when "Articles" is enabled under brand settings. To check, navigate to Settings > Brands > Personalisation > Knowledge Base > Article from your SalesIQ dashboard.
  1. ZDPortalSalesIQ.setKnowledgeBaseVisibility(true)

setChatVisibility

This  ZDPortalSalesIQ.setChatVisibility(_ component: ZDPSalesIQComponents.ChatComponent, visible: Bool) API lets you toggle the function of various components in SalesIQ.


Example code snippet for setChatVisbility:
  1. ZDPortalSalesIQ.setChatVisibility(.preChatForm, visible: false)
Notes

The components' settings are considered only if their function is enabled in the portal settings.

Parameters:

Chat component

Function description

Default setting

preChatForm

Enable/disable the pre-chat from before initiating a chat.

Enabled

attenderImageInChat

Enable/disable the attendee's profile image in the chat window.

Enabled

attenderImageOnLauncher

Enable/disable the ability to display the attender's profile picture on the launcher. (this option is considered only if there is one open chat available)

Disabled

visitorName

This option is used to configure the visibility of the visitor's name for all outgoing messages.

Disabled

fileSharing

Enable/disable the access to send files from the files application in chat.

Enabled

mediaCapture

Enable/disable taking photos and videos from the add attachments menu on the chat.

Enabled

photoLibrary

Enable/disable the option to access the photo library to send images and videos in chat.

Enabled

screenshotOption

Enable/disable the ability to take screenshots from the add attachments menu.

Enabled

inAppNotifications

Enable/disable in-app notifications when a new message is received in chat.

Enabled

emailTranscript

Enable/disable the option to request an email transcript for a chat.

Enabled

rating

Enable/disable the option to rate a chat after it has ended.

Enabled

feedback

Enable/disable the option to give feedback after a chat has ended.

Enabled

reopen

Show or hide the chat reopen option on the chat window.

Enabled

end

 

Controls the visibility of the end action option in the chat window.

Enabled

endWhenInQueue

 

Controls the visibility of the end action option in the chat window when the user is in the queue.

Enabled

endWhenBotConnected

Controls the visibility of the end action option in the chat window when the bot is connected.

Enabled

endWhenOperatorConnected

Controls the visibility of the end action option in the chat window when a human operator is connected.

Enabled

queuePosition

Controls the visibility of the queue position in the chat window. 

Enabled