Skip to main content
Use the browser SDK when you want a voice session inside your own web app, instead of the website widget. The SDK is @voice-session/web. Your backend mints { url, token } with your API key. The browser never sees the API key.

Flow

  1. Your backend calls Create realtime session with the assistant UUID.
  2. You send url and token to the browser.
  3. The SDK starts the microphone session and emits transcripts and agent state.

Install

Example

Events

Limits

  • 10 session creations per minute per API key.
  • 10 concurrent sessions per account. Unused tokens count until they expire (15 minutes). Live website-widget voice sessions on the same account also count.
  • A Call History row is created only after the browser connects. Unused tokens do not appear in Call History.

Security

  • Mint url and token only on your server.
  • Tokens expire after 15 minutes.
  • Do not accept a room name or media URL from the browser. Use only the values returned by Create realtime session.