Skip to main content

Initialization

token

required
The only required option; your organization’s widget token. you can find it in Dashboard / Widget.

Branding

assets

object
default:{}

bot

object
Name and avatar of the bot.

humanAgent

object
Options applied for all human agents.

cssOverrides

string
default:"undefined"
A custom vanilla stylesheet to override the default styles.You will need to use the selectors to target the elements you want to override. Inspect the DOM and look for things that look like data-component="chat/input_box/root".If you want to customize a component and it doesn’t have a selector, let us know and we’ll add it.

disableTooltips

boolean
default:false
If true, tooltips will be disabled for all components.

inline

boolean
default:false
If this is set to true:
  1. The widget content will fill it’s parent element.
  2. The widget will always be open.
  3. The widget trigger will not be visible.
This is useful if you want to embed the widget in a parent element and have it always open.

language

default:"en"
The language of the widget’s interface.Supported languages are:
  • ar Arabic
  • da Danish
  • de German
  • en English
  • es Spanish
  • fi Finnish
  • fr French
  • it Italian
  • nl Dutch
  • no Norwegian
  • pl Polish
  • pt Portuguese
  • ro Romanian
  • sv Swedish
  • tr Turkish
You can request a language by contacting us or directly opening a PR.

textContent

object
default:"language-specific"
Custom text content to override the defaults in the widget.

timestamps

object
default:{}
Custom text content to override the defaults in the widget.

theme

object
Theme customization options.

translationOverrides

{ [key in Language]?: Partial<TranslationInterface> }
default:{}
Translation overrides per language per translation key. Check language for the list of supported languages.

headerButtons

{ sessionsScreen?: Array<HeaderButtonU>; chatScreen?: Array<HeaderButtonU>; }
default:{}
Custom header buttons to expand-shrink the size of the widget, close the widget, resolve the session, etc.
Using this option will remove the default close-widget button on small screens.

User

collectUserData

boolean
default:false
If turned on, the widget will have a login-like screen to collect user’s name and email. A non-verified contact will be created based on the provided information.

extraDataCollectionFields

Array<string>
default:[]
Extra data collection fields besides name and email. For this setting to take effect, collectUserData must be set to true.

prefillUserData

object
default:{}
Provide initial values for the name and email inputs in the welcome screen. For this setting to take effect, collectUserData must be set to true.

user

object
default:{}
Verified or non-verified contact data. If no data is provided, an anonymous contact will be created.For more details and recipes, check the Authentication page.

Chat

initialMessages

Array<string>
default:["Hello, how can I help you?"]
Initial messages that the user sees in a new chat session. These messages will disappear once the user sends their first message.

advancedInitialMessages

Array<{ message: string; persistent?: boolean }>
default:"undefined"
Initial messages that the contact sees in a new chat session. Similar to the initialMessages option, but with more control over the messages.If persistent is true, the message will be saved in the chat session and will stay at the top of the chat session.Using this option will override the initialMessages option.

initialQuestions

Array<string>
default:[]
Suggested initial questions that the contact sees in a new chat session. If a user clicks on one of the suggested questions, the widget will send it as the user’s first message.

initialQuestionsPosition

above-chat-input | below-initial-messages
default:"above-chat-input"
Where to display the suggested initial questions.

thisWasHelpfulOrNot

object
This shows when the AI’s response might have solved the user’s issue. The prompt shows as two buttons: “This was helpful” and “I need more help”.

Behavior

anchorTarget

_top | _blank
default:"_top"
The target attribute for all links in the AI or human agents responses.
  • _top opens links in the same tab.
  • _blank opens links in a new tab or window.

isOpen

boolean
default:false
Whether the widget is open or not.Can be used to have the widget open by default (useful when embedded in a webview for a mobile app). Also useful to open and close the widget programmatically.

oneOpenSessionAllowed

boolean
default:false
By default, the user can have multiple open sessions. Setting this option to true will hide the new conversation button if there is an open session.

openAfterNSeconds

number
default:"undefined"
Automatically open the widget after N seconds.

router

object
Customize routing rules between screens.

Context & Custom Data

context

object
default:{}
Dynamic context to be sent with each send-message request from the widget.

messageCustomData

object
default:{}
Dynamic custom data to be sent with each contact message. This custom data is intended for human use only; the AI will not see it and it will not affect the AI’s response.

sessionCustomData

Record<string, string | number | boolean>
default:{}
Custom data to be added to the session upon creation. This custom data is intended for human use only; the AI will not see it and it will not affect the AI’s response.

HTTP Actions

headers

Record<string, string>
default:{}
Custom headers to be sent with each AI action called.

queryParams

Record<string, string>
default:{}
Custom query params to be sent with each AI action called.

bodyProperties

Record<string, string>
default:{}
Custom body properties to be sent with each AI action called.

Components

modesComponents

Array<ModeComponent>
default:[]
Custom components to be mounted in the canvas if there is an active mode.