Skip to content

ConnectOptions

Options of KheelonaVoice.connect.

clientSecret: string

The short-lived secret your server got from POST /v1/sessions. Never your API key.


optional endpoints?: object

Where to connect, if your server’s POST /v1/sessions answer gave addresses (connect.webrtc_url and connect.websocket_url). Defaults to the production service.

optional webrtcUrl?: string

optional websocketUrl?: string


optional microphone?: false | { deviceId?: string; }

false for typed turns only (no microphone is opened); deviceId picks the input device.


sessionId: string

The session id returned alongside the secret.


optional transport?: "webrtc" | "websocket" | "auto"

Default auto: WebRTC, falling back to the WebSocket when the network refuses WebRTC.


optional workletBaseUrl?: string

Where the AudioWorklet modules are served from, for a strict CSP.