Install
Layout Modes
Set layout in Dashboard -> Widgets -> Appearance -> Layout, or passlayout in the script.
bubble: Default floating launcher bubble.tab: Vertical side tab launcher.- If
layoutis not provided, it defaults tobubble.
Constructor Options
widgetToken(required): Widget token from Dashboard.layout(optional):bubbleortab(default:bubble).bottomSpacing(optional): Distance in pixels from the page bottom (default:28).
Bottom Spacing Example
JavaScript API
After creating a widget instance, you can control it programmatically:widget.init(): Initialize the widget and load config from your widget token.widget.open(): Open chat UI (also makes a hidden widget visible).widget.close(): Close chat UI.widget.toggle(): Toggle between open and closed.widget.show(): Show widget UI if hidden.widget.hide(): Hide widget UI.widget.destroy(): Remove widget DOM and event listeners.