Interface ICallOptions

ICallOptions ICallOptions

Hierarchy

  • ICallOptions

Properties

audio?: boolean

Overrides client's default audio constraints. Defaults to true

callerName?: string

Name to use as the caller ID name when dialing out to a destination.

callerNumber?: string

Number to use as the caller ID when dialing out to a destination. A valid phone number is required for dials out to PSTN numbers.

camId?: string

deviceId to use as webcam. Overrides the client's default one.

clientState?: string

Telnyx's Call Control client_state. Can be used with Connections with Advanced -> Events enabled. clientState string should be base64 encoded.

customHeaders?: {
    name: string;
    value: string;
}[]

Add custom headers to the INVITE and ANSWER request.

Type declaration

  • name: string
  • value: string
debug?: boolean

Enable debug mode for this call.

debugOutput?: "file" | "socket"

Output debug logs to a file.

destinationNumber: string

Phone number or SIP URI to dial.

iceServers?: RTCIceServer[]

Overrides client's default iceServers.

id?: string

Custom ID to identify the call. This will be used as the callID in place of the UUID generated by the client.

localElement?: string | HTMLMediaElement

Overrides client's default localElement.

localStream?: MediaStream

If set, the call will use this stream instead of retrieving a new one.

mediaSettings?: {
    sdpASBandwidthKbps?: number;
    useSdpASBandwidthKbps?: boolean;
}

Configures media (audio/video) in a call.

Type declaration

  • Optional sdpASBandwidthKbps?: number
  • Optional useSdpASBandwidthKbps?: boolean
micId?: string

deviceId to use as microphone. Overrides the client's default one.

onNotification?: Function

Overrides client's default telnyx.notification handler for this call.

preferred_codecs?: RTCRtpCodecCapability[]

Preferred codecs for the call.

remoteElement?: string | HTMLMediaElement

Overrides client's default remoteElement.

remoteStream?: MediaStream

If set, the call will use this stream instead of retrieving a new one.

speakerId?: string

deviceId to use as speaker. Overrides the client's default one.

telnyxCallControlId?: string

Telnyx Call Control ID, if using Call Control services.

telnyxLegId?: string

Telnyx call leg ID, if using Call Control services.

telnyxSessionId?: string

Telnyx call session ID, if using Call Control services.

useStereo?: boolean

Uses stereo audio instead of mono.

video?: boolean

Overrides client's default video constraints. Defaults to false