Managing Your Chatbot
Add your AI chatbot to any website with a simple code snippet
Installing AI Chatbot on your website is easy and involves pasting a single code snippet into your website’s HTML.
Go to chatbot.ai and log in to your dashboard.
Click on Install Agent in the sidebar.
Make sure the JavaScript tab is selected, then click Copy Code.
Paste the code snippet into the <head> section of your website:
Replace YOUR_CHATBOT_ID with your actual chatbot ID from the dashboard.
If you prefer to embed the chatbot as an iFrame (useful for embedding in specific page sections), switch to the iFrame tab in the Install Agent section.
Paste the iFrame code into the <body> section where you want the chatbot to appear:
Replace YOUR_CHATBOT_ID with your actual chatbot ID from the dashboard.
// Server-side: Generate JWT token
const jwt = require('jsonwebtoken');
const token = jwt.sign({
user_id: user.id,
email: user.email,
name: user.name,
exp: Math.floor(Date.now() / 1000) + 3600
}, 'YOUR_SECRET_KEY', { algorithm: 'HS256' });
// Client-side: Pass token to chatbot
window.AI Chatbot.identify({
token: token
});
Identity verification allows you to personalize welcome messages using template tags and view conversation history per user.
Looking to install on a specific platform? Check out our detailed guides:
Ready to automate your customer service with AI?
Join over 1000+ businesses, websites and startups automating their customer service and other tasks with a custom trained AI agent.