The Exotel transport connects CXB Core to Exotel’s App Bazaar Voicebot applet. Calls arrive as WebSocket connections from Exotel’s infrastructure, using the media pipeline framework’s built-in ExotelFrameSerializer.

Connection flow

Endpoint

WebSocket /exotel/{bot_id}
bot_id identifies which bot configuration to fetch from CXB API.

Audio format

PropertyValue
EncodingLINEAR16 (signed 16-bit PCM)
Sample rate8,000 Hz
ChannelsMono
TransportWebSocket (binary/JSON)

Handshake

Exotel uses the media pipeline framework’s standard telephony WebSocket handshake. CXB Core calls parse_telephony_websocket() which auto-detects Exotel from the WebSocket messages and returns call metadata:
FieldMapped from
stream_idcall_data.stream_id
caller_idcall_data.from
didcall_data.to

Hangup behavior

Bot-initiated: CXB Core closes the WebSocket connection. The Exotel App Bazaar flow moves to the Hangup applet, which tears down the telephony call. Customer hangup: Exotel sends a stop event, then closes the WebSocket. CXB Core receives WebSocketDisconnect and captures disconnected_by = "customer". Outside active hours: If CXB API returns no config (bot unavailable or outside its active-hours window), CXB Core returns without starting the pipeline and records disconnected_by = "outside_hours". The WebSocket close lets the Exotel flow tear down the call.

Limitations

Call transfer is not supported. Exotel’s current Voicebot applet does not expose a dynamic call control API for mid-call transfers. Transfer support is deferred until Exotel adds this capability.

Prerequisites

  • Exotel account with App Bazaar access
  • App Bazaar flow configured: Call Start → [Voicebot Applet] → [Hangup Applet]
  • Voicebot applet WebSocket URL pointing to CXB Core’s /exotel/{bot_id} endpoint
  • No Exotel credentials needed in CXB Core — call control is flow-based