Skip to main content
Version: 8.0

Webitel integration basics

Level: advanced

Webitel integration is implemented in the form of separate Creatio modules. Modules in the integration include:

The WebitelCore package – modules that contain low-level interactions with Webitel using the Verto module and the CTI panel on the Creatio application page.

The WebitelCollaborations package implements basic interfaces for working with Webitel in Creatio. The package contains the WebitelCtiProvider module, the WebitelCtiProvider class, Webitel connector, the connection parameters settings page, the lookup to edit Webitel users directly in Creatio.

Detailed information about Webitel architecture can be found in the documentation.

Interaction of components

The WebitelCtiProvider class (the heir of the Terrasoft.BaseCtiProvider class) implements the required interaction between CtiModel and the Webitel low-level global object (the WebitelCore.WebitelModule.js module).

The integration is as follows. If a user has set the system setting of the Webitel integration library, CtiProviderInitializer loads the WebitelCtiProvider module. Next, it calls the init method in WebitelCtiProvider, which carries out the user login in the telephony session (the LogInMsgServer of the MsgUtilService.svc service). If the login was successful, the connect method is invoked, which verifies that you don't have an existing connection (the this.isConnected property is set to false and this.webitel – to empty). After that, the connect method requests the connection settings to Webitel that are stored in the system settings of the webitelConnectionString and webitelWebrtcConnectionString.

After receiving the system settings, the user settings are received from the Webitel users lookup by using the GetUserConnection method of the WUserConnectionService customer service. After receiving the user settings, the WebitelModule and WebitelVerto are loaded if the Use web phone checkbox is selected in the user settings. Next, the onConnected method is called that creates the Webitel global object, in which properties are populated with the connection settings. The subscription to Webitel object events occurs and the connect method is invoked, which performs connection via WebSocket, authorization of Webitel and other low-level connection operations. When the onConnect event occurs, the connection is considered successful and the user can work with calls. During the connector operation, WebitelCtiProvider reacts to Webitel object events, processes them, and optionally generates connector events described in the Terrasoft.BaseCtiProvider class. To manage calls, WebitelCtiProvider implements abstract methods of the Terrasoft.BaseCtiProvider class by using the Webitel object methods.

Examples of CtiPanel, CtiModel and WebitelCtiProvider interaction

Outgoing call to a subscriber: putting a call on hold, taking a call off hold by a subscriber and finishing a call.

Webitel list of ports

  • 871 – the WebSocket port for the Webitel server and receiving events.
  • 5060 and 5080 – signal ports for SIP phones and telephony providers.
  • 5066 – the port for the Web phone and WebRTC signal port.
  • 4004 – the port for receiving call records.

Webitel events

Event

Description

onNewCall

New call start event.

onAcceptCall

Accept call event.

onHoldCall

Call hold event.

onUnholdCall

Call Unhold event.

onDtmfCall

Tone dialing event.

onBridgeCall

Connection to channel event.

onUuidCall

Call UUID change event.

onHangupCall

Call stop event.

onNewWebRTCCall

New WebRTC session event.