Rate this page:

Events

The events that are triggered by Client instance. See the getInstance method.

Constants

ACDError

Copy URL

Triggered when the Web SDK detects incorrect usage of the ACD module, e.g., usage of the same credentials in the different browsers or multiple browser windows. This event can also trigger when you make a request, reload the page and receive response after the page reloads.

Parameters

  • code:

    number

  • message:

    string

ACDStatusUpdated

Copy URL

Triggered when a contact center agent's status changes via SDK or within the contact center. Works both for SmartQueue and ACD v1.

Parameters

AuthResult

Copy URL

Triggered after the Client.login, Client.loginWithOneTimeKey and Client.loginWithToken methods call.

Parameters

  • Optional

    Optional. Authentication result code.

  • displayName:

    string

    Optional

    Optional. Authorized user's display name

  • key:

    string

    Optional

    Optional. Use to calculate the hash parameter for Client.loginWithOneTimeKey method. Triggers the AuthResult event with the key after the Client.requestOneTimeLoginKey method is called.

  • result:

    boolean

    Whether the refresh is successful

  • Optional

    Optional. New tokens structure

ConnectionClosed

Copy URL

Triggered if a connection to Voximplant Cloud has been closed because of network problems or the Client.disconnect function call.

See: Client.connect, Client.disconnect

ConnectionEstablished

Copy URL

Triggered after connection to the Voximplant Cloud has been established successfully.

See: Client.connect

ConnectionFailed

Copy URL

Triggered if a connection to the Voximplant cloud could not be established.

See: Client.connect

Parameters

  • message:

    string

    Failure reason description

IncomingCall

Copy URL

Triggered when there is a new incoming call to current user

Parameters

  • call:

    Call

    Incoming call instance. See the Call interface for details

  • headers:

    Object

    Optional

    Optional. SIP headers received with the message

  • video:

    boolean

    Optional

    Optional. Whether the caller initiated a video call

MicAccessResult

Copy URL

Parameters

  • fallback:

    boolean

    Optional
  • result:

    boolean

    Whether access is granted

  • stream:

    MediaStream

    MediaStream object

PlaybackError

Copy URL

PlaybackFinished

Copy URL

Triggered after sound playback has been stopped.

See: Client.playToneScript, Client.stopPlayback

Reconnected

Copy URL

Triggered when reconnection to the server is successful.

Reconnecting

Copy URL

Triggered when the SDK client loses connection with the Voximplant cloud and tries to reconnect, for example, when a customer's internet connection fails.

RefreshTokenResult

Copy URL

Triggered after the LoginTokens.refreshToken call

Parameters

  • Optional

    Optional. Authentication result code.

  • result:

    boolean

    Whether the refresh is successful

  • Optional

    Optional. New tokens structure

SDKReady

Copy URL

Triggered after SDK has been successfully initialized after the Client.init function call

Parameters

  • version:

    string

    SDK version

SQError

Copy URL

Triggered when the Web SDK detects incorrect use of the SmartQueue module, e.g., Using the same credentials in the different browsers or multiple browser's windows.

Parameters

  • code:

    number

  • message:

    string

SQMessagingStatusUpdated

Copy URL

Triggered when SmartQueue messaging status of current user changed from SDK or from inside the SmartQueue messaging service.

Parameters