Corral
Learn > Documentation

Web Chat Widget

Add an AI chat widget to your website with a simple embed code.

Quick Start

Add this snippet to your HTML:

<script
  src="https://your-corral-instance.azurewebsites.net/widget.js"
  data-agent="your-agent-id"
></script>

Configuration Options

Customize the widget appearance:

<script
  src="https://your-corral-instance.azurewebsites.net/widget.js"
  data-agent="your-agent-id"
  data-theme="light"
  data-position="bottom-right"
  data-welcome="Hi! How can I help?"
></script>

Styling

OptionValuesDefault
data-themelight, dark, autoauto
data-positionbottom-right, bottom-leftbottom-right
data-primary-colorHex color#0066cc

Advanced Integration

For more control, use the JavaScript API:

window.CorralWidget.open();
window.CorralWidget.close();
window.CorralWidget.sendMessage('Hello');

Security

The widget uses secure communication:

  • HTTPS only
  • CORS protection
  • No PII stored in browser

Next Steps