ZohoSalesIQ.Chat.startWithTrigger()

The ZohoSalesIQ.Chat.startWithTrigger() API allows initiating a chatbot-triggered chat or using the specified chat ID.

Note: 

  • This API is supported from version 8.0.0
  • For this API to work, the bot should be proactive/trigger (Settings > Zobot > Select the bot > Bot Configuration > When the bot should initiate the chat and enable When visitors click the chat widget).

Parameters

  • customChatId (Optional) - Unique ID of the conversation to trigger a chat.
  • departmentName (Optional) - Department to which the chat should be routed.
  • callback (Optional) - The callback to get the result.

Example

CopiedZohoSalesIQ.chat.startWithTrigger("custom_chat_id", "department_name").then((value) =>
{
      // Handle success
}).onError((error, stackTrace) => {
      // Handle error
});