Embedding in website
Prerequisites
Embedding Process
Step 1: Access the Embedding Guide
Step 2: Copy the Embedding Code
<body>
<div class="container">
<h1>Waterflai Simple Chatbot Integration</h1>
</div>
<!-- Include the Waterflai Chatbot web component -->
<script src="https://app.waterflai.ai/web_components/waterflai-chat-web-component.js"></script>
<!-- Initialize the chatbot with settings -->
<waterflai-chatbot
id="myWaterflaiChatbot"
chatbot-id="YOUR_CHATBOT_ID"
api-key="YOUR_API_KEY"
api-url="https://api.waterflai.ai"
chatbot-type="simple"
welcome-message="Welcome! How can I assist you today?"
header-title="Chat with us"
input-placeholder="Type your message..."
primary-color="#6366f1"
stream-response>
</waterflai-chatbot>
</body>Step 3: Choose Your Display Mode
Step 4: Customize the Embedding Code
Step 5: Insert the Embedding Code
Customization Options
Required Attributes
Optional Attributes
Display Mode Considerations
Widget Mode
Inline Mode
Troubleshooting
Last updated