Support Widget SOQ
Live screenshot from the SOQ beauty demo (aiacademy.aiee.dev). Controls in the image are not clickable.
What this is
A floating support chat on the public web layout and (optionally) the student / instructor / organization panel. Visitors sign in with Google as Public Chat Users (not TMS Students); the agent answers from a knowledge brief plus indexed Documentation pages, using the OpenAI key under AI Contents → Settings. Conversations are persisted for history and admin review. Interactive welcome tiles and follow-up chips ship with smart defaults (admin-editable). When needed, it offers WhatsApp/email or a Google Calendar booking URL for human handover. Footer credits QUICKSALES.AI.
Admin path
Use these admin screens and files to configure the widget. Paths use → for the menu trail.
| Item | Where / value |
|---|---|
| Settings | Admin → AI Contents → Support Widget (/admin/support-widget/settings) |
| Public Chat Users | Admin → AI Contents → Public Chat Users (/admin/support-widget/visitors) — Google-signed visitors and transcripts |
| OpenAI key | Reuses AI Contents → Settings (do not configure a second key here) |
| Welcome tiles / follow-ups | One line per prompt — Label | Prompt text | icon (saved in support_widget_settings) |
| Show on panel | Toggle to include the FAB on user panel layouts (not admin) |
| Knowledge brief | storage/support_agent/knowledge_base.md (handover copy: Desktop docs/engineering/product/support-agent-kb.md) |
| Documentation index | php artisan soq:support-docs-index → storage/support_agent/docs_index.json + docs/*.txt (optional SOQ_DOCS_PATH / --path=) |
| Booking URL | Paste Google Calendar appointment schedule URL for human handover |
| Google OAuth redirect | Add {APP_URL}/support-widget/google/callback in Google Cloud (separate from student /google/callback) |
| Surfaces | design_1.web.components.support_widget on web + panel layouts |
How to enable (demo / pitch)
- Ensure OpenAI is configured under AI Contents → Settings.
- Enable Google client ID/secret under Settings → General → Features.
- Add the widget callback URI in Google Cloud:
/support-widget/google/callback. - Run
php artisan soq:enable-features(or fullphp artisan demo:seed beauty) — mergessupport_widget_settingsincluding default prompt tiles. - Run
php artisan soq:support-docs-indexso the agent can retrieve panel/public Documentation pages. - Open Admin → AI Contents → Support Widget; edit tiles / follow-ups; set booking URL if you want calendar handover.
- Confirm the FAB; sign in with Google to chat; verify the visitor appears under Public Chat Users.
Notes
Prefer live contact CMS values over hardcoding. Public Chat Users are not Students. Quicksales.ai WhatsApp CRM remains planned and separate from this widget — the footer “Powered by QUICKSALES.AI” is branding only.