Quick Start
Get Bob connected to your website or front-office workflow in a few guided steps.
Create or select a tenant
Choose the tenant that owns the website, widget, and API credentials for this integration.
Generate credentials
Create a tenant-scoped widget key from Customer Portal → Widget Setup, or use a customer JWT for server-side automation.
Install the widget or call the API
Use the website widget for front-end chat or the API for server-side workflows.
Test with browser proof
Verify the integration from the live browser, not just a mock request.
<!-- Tenant-scoped bundle — replace YOUR_TENANT_UUID after onboarding -->
<script src="https://www.askbob.cool/widget/YOUR_TENANT_UUID/widget.js" async></script>
Setup
Complete these prerequisites before calling protected APIs or publishing the widget on production domains.
External integrations connect systems outside the platform to Bob. Day-to-day front-office work happens in the Customer Portal.
- Tenant created
- Business profile completed
- Website or channel configured
- API credentials generated
- Allowed origins configured
- Test conversation completed
| Environment | Purpose | Where to configure |
|---|---|---|
| Production | Live customer traffic | Customer Portal → Widget Setup |
| Staging / preview | Pre-launch verification | Allowed origins + test domain |
| Automation | Server-side webhooks & APIs | Customer JWT from portal login |
Authentication
Protected API requests must include a tenant-scoped credential. Keep private keys server-side and never expose them in browser code.
Generate credentials
requiredSign in to the Customer Portal and create widget keys in Widget Setup, or obtain a customer JWT via POST /api/customer/auth/login for automation.
Send Authorization header
Server-to-server automation uses Authorization: Bearer <token> with JSON bodies.
curl https://www.askbob.cool/api/customer-portal/widget-code \
-H "Authorization: Bearer YOUR_CUSTOMER_JWT" \
-H "Content-Type: application/json"
Handle auth errors
Return structured errors to your integration layer and retry only when appropriate.
| Status | Meaning |
|---|---|
| 401 | Missing or invalid credential |
| 403 | Credential is valid but lacks permission |
| 429 | Rate limit exceeded |
/api/customer/auth/login
Customer Portal login. Returns JWT for authenticated integration calls.
/api/auth/login
Mission Control operator login (platform administration only).
Chat & Conversations
Bob exposes three chat paths depending on caller context: same-origin anonymous, cross-origin widget, and authenticated Mission Control.
POST /api/chat. (2) Cross-origin embed → POST /api/widget/chat with X-Widget-Key. (3) Mission Control → POST /api/chat/message (requires chat.manage; not for anonymous public fetch)./api/chat
Public anonymous chat on your own domain. Body: message, session_id, optional business_id.
/api/widget/chat
Cross-origin widget chat. Headers: X-Widget-Key, Content-Type. Origin must be allowlisted.
/api/widget/chat/audio
Speech-to-text for widget voice input. Same key and origin rules as chat.
/api/chat/session
Create session when logged into Mission Control (RBAC + CSRF for cookies).
/api/chat/message
Authenticated admin UI send (chat.manage). Returns 401 if called anonymously.
/api/chat/history/:session_id
Conversation history (authenticated).
const response = await fetch('/api/chat', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
session_id: sessionId,
message: userMessage,
business_id: 'your-tenant-slug'
})
});
const data = await response.json();
Widget Installation
Install the widget on your site when you want Bob available directly to visitors. Use tenant-specific configuration from Customer Portal → Widget Setup.
After onboarding, your embed code is in the Customer Portal under Widget Setup. The publishable widget key (pk_live_…) is configured there—not embedded in static HTML.
<!-- Tenant-scoped bundle from Customer Portal → Widget Setup -->
<script src="https://www.askbob.cool/widget/YOUR_TENANT_UUID/widget.js" async></script>
| Item | Purpose | Example |
|---|---|---|
| Tenant UUID in script path | Identifies your widget bundle | From Widget Setup |
| Publishable widget key | Authenticates cross-origin chat | pk_live_… (configured in portal, not in HTML) |
| Allowed origins | Domains permitted to call widget chat | https://your-site.com |
/api/customer-portal/widget-code
Returns ready-to-paste embed markup. Requires customer JWT (config.read).
Dashboard Webhooks
Use outbound webhooks to receive updates when conversations, handoffs, leads, or workflow events change in your tenant.
| Event | Description |
|---|---|
| conversation.escalated | Human handoff requested |
| conversation.takeover.started | Agent took live control |
| conversation.takeover.released | Returned to Bob |
| lead.created | New intake captured |
| appointment.booked | Scheduling confirmation |
| billing.payment_failed | Account risk signal |
| billing.payment_recovered | Payment restored |
| webhook.test | Connectivity check from portal |
| * | All events above |
Create a subscription
Use a Customer Portal admin JWT. POST url, events, and description to /api/webhooks/subscriptions.
{
"url": "https://your-app.com/webhooks/bob",
"events": ["lead.created", "conversation.escalated"],
"description": "CRM intake"
}
Verify signatures
Verify webhook signatures server-side before trusting the payload.
{
"event": "lead.created",
"tenantId": "tenant_...",
"conversationId": "conv_...",
"createdAt": "2026-06-19T12:00:00Z",
"data": {}
}
/api/webhooks/subscriptions
List subscriptions (secrets are never returned).
/api/webhooks/subscriptions
Create subscription. Signing secret shown once in response.
/api/webhooks/subscriptions/:id
Remove a subscription.
/api/webhooks/subscriptions/:id/test
Queue webhook.test delivery.
/api/webhooks/deliveries
Delivery log including dead-letter rows.
Persona Automation
Persona automation controls how Bob represents your business, when to escalate, and how to handle boundaries.
persona.manage.Business voice
Tone, greeting style, and brand-aligned responses.
Escalation behavior
When Bob hands off to humans or creates tasks.
Topic boundaries
Approved topics and safe refusal patterns.
Workflow preferences
Department routing and automation hooks.
/api/personas
List personas for the authenticated tenant.
/api/personas/:id
Get one persona by id.
/api/personas
Create persona with name, tone fields, systemPrompt, etc.
/api/personas/:id
Update an existing persona.
Plans & Pricing APIs
Published pricebook endpoints power marketing surfaces and checkout. Billing management APIs are not public.
| Feature | Starter | Pro | Enterprise |
|---|---|---|---|
| List price (USD/mo) | $79 | $249 | $899 |
| Included AI credits / mo | 15,000 | 75,000 | 250,000 |
| Team seats | Up to 3 | Up to 10 | Unlimited |
| Standard integrations | 1 | 3 | 10 |
| Support | Priority | Dedicated |
/api/pricing/marketing-cards
Plan cards for marketing and checkout (public, no auth).
/api/pricing/snapshot
Public-safe full pricebook snapshot (no provider cost fields).
Health & Status
Use health and status information to verify availability, monitor upstream dependencies, and troubleshoot integration issues.
/api/health
Lightweight health probe for monitors and load balancers.
/api/health/public
Public status payload consumed by the System Status page.
Integration Examples
Practical starting points for common integration patterns.
Website chat widget
Add Bob to a marketing site or customer portal.
View example →Server-side conversation API
Same-origin anonymous chat from your app.
View example →Webhook listener
Verify signatures and process lead.created.
View example →CRM handoff flow
React to conversation.escalated events.
View example →Lead capture workflow
Subscribe to lead.created for intake.
View example →Support escalation
Monitor escalations and takeover events.
View example →const response = await fetch('https://www.askbob.cool/api/widget/chat', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-Widget-Key': 'pk_live_...',
'Origin': 'https://your-customer-site.com'
},
body: JSON.stringify({ session_id: sessionId, message: userMessage })
});
Architecture Overview
Ask Bob is a browser-based governed front office: Customer Portal for operators, Mission Control for platform administration, and public integration surfaces for your stack.
Customer Portal and Mission Control APIs are session-backed UI routes—not published here. For a concise platform diagram, see architecture overview and proof center.