/livekit/widget route is the entry point for embeddable browser web calls. A web visitor joins a LiveKit room from the browser, and this route asks a CXB Core worker to join the same room as the bot and run the standard pipeline — no telephony, no SIP.
Connection flow
Endpoint
X-CXB-Core-Secret header (403 without).
Request body
| Field | Type | Required | Description |
|---|---|---|---|
bot_id | string | Yes | Bot configuration to use |
room_name | string | Yes | LiveKit room the browser user is already in |
caller_id | string | No | Identifier for the web caller. Defaults to "widget-user". |
Response
Audio format
16 kHz mono LINEAR16 via the LiveKit SDK, same as the other LiveKit routes.Behavior notes
- Hangup: the bot ends a widget call with
transport.disconnect(), which leaves the LiveKit room. - No SIP transfer / Agent Desk: the widget route does not register a transfer or agent-desk callback —
build_and_run_pipeline()is called without them. Web widget calls are pure conversation. - Outside hours / unavailable bot: if config fetch returns
None, the call is dropped withdisconnected_by = "error"(the widget route does not useoutside_hours). - Standard pipeline: opening message, STT/LLM/TTS, and post-call analysis run exactly as on other transports.
Capacity
The route returns429 At capacity when the worker has no free slot. /livekit/widget is in the fleet nginx 429-retry list (proxy_next_upstream ... http_429), so nginx retries another worker — safe because CXB Core returns 429 before starting any side effects.