Wait until the API is ready
The embed dispatches browser events when it is ready. Prefer listening for these instead of polling. If your code might run before or after the embed is ready, check once and then listen:Auto-open on intent
Open the widget after a delay to invite engagement:Open after scroll depth
Open the chat once the visitor scrolls past a threshold:Trigger a product question
Inject a context-driven prompt from a product detail page.sendMessage opens the chat automatically if it is closed:
Attach metadata to the next message
Add context such as the current product before the visitor sends a message:Read the chat history
Read the current conversation, for example to forward it to your own analytics:Force a new conversation
Start a fresh conversation by settingnewChat: true: