Widget Demo

This page demonstrates how a host application embeds the AI Support Widget. The widget FAB button should appear in the bottom-right corner.

Integration Code

<script src="https://cdn.example.com/widget.js"></script>
<script>
  AISupportWidget.init({
    apiUrl: 'https://support-api.yourapp.com',
    tenantKey: '<your-tenant-key>',
    jwt: '<jwt-from-your-backend>',
    theme: 'dark',
    position: 'bottom-right',
    onTokenRefresh: async () => {
      const res = await fetch('/api/refresh-token');
      const { token } = await res.json();
      return token;
    }
  });
</script>

Host application content area

The widget operates independently via Shadow DOM