Skip to main content

Interface: ConnectOptions

Options for BabelconnectClient.connect.

Properties

autoAnswer?

optional autoAnswer: boolean;

Auto-answer the agent's own OUTBOUND ringing leg (default true). INBOUND waits for BabelconnectClient.answerCall.


mediaFactory?

optional mediaFactory: null | MediaFactory;

Per-call WebRTC leg. Defaults to browserMediaFactory; pass null for a control-only client.


onError()?

optional onError: (err) => void;

Out-of-band server notices (command rejections) + local media failures.

Parameters

err

Error

Returns

void


onGap()?

optional onGap: () => void;

A state-update seq gap was detected (reconnect recommended).

Returns

void


onNotification()?

optional onNotification: (n) => void;

A transient CTI notification (screen-pop) — surfaced, not stored in the view.

Parameters

n

Notification

Returns

void


serverUrl

serverUrl: string;

babelconnect-server origin (gRPC-web), e.g. https://agent.example.com or http://localhost:7091.


token

token: string;

Bearer token (see passwordGrant or your host login).