Skip to content

stustoke-bot/bobblechat

Repository files navigation

bobblechat

Reusable Bobble Chat starter for new sites with configurable branding, Twilio SMS alerts, and live-agent reply links.

What this repo includes

  • on-site AI chat widget
  • callback booking flow
  • Twilio SMS notifications
  • email notifications via Microsoft Graph
  • CRM/webhook forwarding routes
  • live-agent web page for replying to visitors from a link
  • one central config file for branding and copy

First file to edit

Update lib/chatbot/config.ts first.

That file controls:

  • business name
  • bot name
  • logo path
  • avatar path
  • phone number
  • email and address
  • welcome copy
  • proactive prompts
  • booking flow text
  • live-agent labels
  • default AI facts
  • default SMS recipients

Environment variables

Copy .env.example to .env.local and set:

  • ANTHROPIC_API_KEY
  • CRM_BASE_URL
  • CRM_INGEST_TOKEN
  • AZURE_TENANT_ID
  • AZURE_CLIENT_ID
  • AZURE_CLIENT_SECRET
  • OUTLOOK_FROM_EMAIL
  • WEBSITE_NOTIFY_EMAIL
  • TWILIO_ACCOUNT_SID
  • TWILIO_AUTH_TOKEN
  • TWILIO_FROM_NUMBER
  • TWILIO_CALLBACK_RECIPIENTS

Local setup

npm install
npm run dev

Open http://localhost:3000.

Main files

  • components/chat/ChatWidget.tsx
  • app/api/chat/*
  • app/api/lead/route.ts
  • app/api/book/route.ts
  • app/agent/chat/page.tsx
  • lib/chatbot/config.ts
  • lib/chatbot/ai.ts
  • lib/chatbot/server.ts
  • lib/server/notifications.ts

Notes for the next Codex

  • This starter still uses mortgage-oriented defaults in the AI and booking copy because that is what the original build used.
  • Rebrand and adjust the compliance text in lib/chatbot/config.ts before going live.
  • The live-agent flow assumes your CRM service keeps the existing chat session endpoints.

About

Reusable Bobble Chat starter for new sites with configurable branding, Twilio SMS alerts, and live-agent reply links

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors