Currently Under Development and The Below is not accurate for now.
chat-bot-embed
chat-bot-embed
is a lightweight and framework-agnostic package that allows you to easily embed a chat bot into any web application via an iframe. It dynamically appends a chat bot window to the screen.
Usage
Appending the support bot to the dom
Use loadSupportBot to load the widget anonymously, without any user identification.
import { loadSupportBot } from 'chat-bot-embed';
loadSupportBot({
projectId: 'your-project-id',
appId: 'your-app-id',
reAppendOnRefresh: true,
url: 'https://chat.supportbotcentral.com',
});
Booting with User identification
Use bootSupportBot to initialize the chat bot with a user's information. This allows the chat bot to recognize the user across sessions.
import { bootSupportBot } from 'chat-bot-embed';
bootSupportBot({
userEmail: 'user-email@example.com',
userId: null,
});
Recommended Usage
The support bot widget should be loaded first using loadSupportBot().
The session will be anonymous until the widget is booted using bootSupportBot() with the users information.
Once booted all the users information will be transferred and findable under their email.
Local Development