Tiledesk Developer Hub
WebsiteCommunityTutorialsGet started
  • Introduction
  • Community
  • Ask for Support
  • Public Roadmap and Changelog
  • Tutorials
  • Widget
    • Widget SDK
    • Javascript API: Methods
    • Javascript API: Attributes
    • Javascript API: Listeners/Events
    • Widget Authentication
    • Widget Angular integration
    • Widget React integration
    • Widget for Android with WebView
    • Widget for iOS with WKWebView
    • Widget for Flutter with WebView
    • Widget for React with WebView
    • Widget for Wix Website platform
    • Tutorials
      • Hide widget
      • Show/Hide widget programmatically
      • Force widget loading without user interaction
      • Mobile positioning
      • Custom size (width/height)
      • Installing widget on selected pages
    • Conversation Embedded Apps
      • Payment App Tutorial
      • Prechat form App Tutorial
    • Advanced
      • Preset the Widget on a specific Department
      • Authentication Flow
      • Widget protocol specs
      • Prechat Form JSON specs
      • Prevent multiple conversations
      • Old versions
        • Web SDK v4
  • External Chatbot
    • Introduction
    • Hello World tutorial
    • Chatbot to Human handoff
    • Send Text Buttons
    • Advanced Tutorials
      • Introduction
      • Tutorial 1 - Dialogflow as external chatbot
      • Tutorial 2 - Buttons and images
      • Tutorial 3 - Automatic human handoff with fallback intent
      • Tutorial 4 - Explicit Human handoff with user intent
      • Tutorial 5 - Gracefully handling operating hours during handoff
      • Generate Dialogflow Google Credentials file
    • Rasa tutorials
      • Rasa Tutorial 1 - Rasa as external chatbot
  • Resolution bot
    • Introduction
    • Quickstart
    • Webhook service
    • Rich messages
    • Tutorials
      • Chatbot chooser (multilanguage)
      • Department chooser
      • Order info (webhook)
  • APIs
    • REST APIs
      • Introduction
      • Authentication
      • Requests
      • Leads
      • Messages
      • Activities
      • Projects
      • Team
      • User
      • Analytics
      • Canned responses
      • Tags
      • Events
      • Jwt
      • Labels
      • Images
      • Files
      • Segments
      • Chatbots
      • Knowledge Bases
        • Knowledge Base
        • Contents
        • Question & Answer
      • Management Api
        • Departments
        • Groups
    • NodeJS SDK
    • Webhooks
      • Subscriptions
    • Conversation Messages APIs tips
    • Realtime API
    • JWT Authentication
      • JWT Custom authentication Tutorial
    • Tutorials
      • REST API
        • Sending and receiving messages with Tiledesk APIs
        • PHP Tiledesk REST API example
        • Import multiple messages into Tiledesk using REST APIs from third party app
      • Webhooks
        • Custom Request assignment
        • Request transcript on close
  • Apps
    • Build Custom App - Quick start
    • External Channels integration flow diagram
    • Telegram integration tutorial
  • Dashboard & AgentChat SDK
    • Dashboard SDK
    • Agent Chat SDK
  • Architecture
    • Architecture overview
    • Components list
    • Bot Design diagram
    • Multi Channel Message Flow
  • Installation
    • Installation
    • Running Tiledesk using Docker Compose
    • Running Tiledesk with Kubernetes using Helm
    • Choosing Hardware
  • Configuration
    • Chat21 channel configuration
    • Email parameters and templates configuration
    • Configure the logging system
Powered by GitBook
On this page
  • Overview
  • How to set singleConversation mode
  • Set property from tiledeskSettings
  • Set property from URL
  • Make a Sign Out

Was this helpful?

  1. Widget
  2. Advanced

Prevent multiple conversations

PreviousPrechat Form JSON specsNextOld versions

Last updated 1 year ago

Was this helpful?

A new feature in Tiledesk widget settings will prevent your customers from starting a new conversation if they already have one open. This change makes conversations more of a continuous thread, preventing customers from reaching out to your team multiple times, which saves your team time and effort. This feature is named as Single Conversation

Overview

Once the user has been authenticated, the widget proceeds with the normal initialization flow of a new conversation only if the user has no active conversation previously, otherwise, the widget will load the most recent active conversation

How to set singleConversation mode

As with the other widget setting parameters, singleConversation mode can be enabled in various ways: as a url parameter or as a property of tiledeskSettings.

Set property from tiledeskSettings

You can passing the parameters to window.tiledeskSettings object as shown in the example below

<script type="application/javascript">
    window.tiledeskSettings = 
        {
            projectid: "<YOUR_PROJECT_ID>",
            singleConverstion: true
        };
    (function(d, s, id) {
        var w=window; var d=document; var i=function(){i.c(arguments);}; 
        i.q=[]; i.c=function(args){i.q.push(args);}; w.Tiledesk=i; 
        var js, fjs=d.getElementsByTagName(s)[0]; 
        if (d.getElementById(id)) return; 
        js=d.createElement(s); 
        js.id=id; js.async=true; js.src="https://widget.tiledesk.com/v6/launch.js";
        fjs.parentNode.insertBefore(js, fjs);
    }(document,'script','tiledesk-jssdk'));
</script>

The above script can start widget with the single conversation mode, immediately

Set property from URL

You can pass the a tiledesk widget property as a Url parameter with the tiledesk_ prefix. For example, in this case:

https://widget.tiledesk.com/6/assets/twp/index.html?tiledesk_projectid=<YOUR_PROJECT_ID>&tiledesk_singleConversation=true

Make a Sign Out

In this mode, the user can still logout from the system by using the menu at the top right corner in the conversation header, as shown in the figure below.

Once you have make a sign out, widget restarts itself and create a new user. New initialization flow of a new conversation starts and new user can starts to chat again!!

Tiledesk Widget can handle only one conversation at a time by properly setting the singleConversation property. In fact, just set singleConversation to true (see how to do this ) to be able to show the widget user only one conversation at a time. This option disables the possibility of viewing the home with the list of open conversations and those already archived as image below highlight.

singleConversation
here