Skip to main content

         This documentation site is for previous versions. Visit our new documentation site for current releases.      

Processing events received from the CTI server

Updated on December 28, 2022

The HandleEvent activity converts incoming event data to the Pega format. OpenCTI provides data transforms, decision trees, and activities to achieve this conversion. Override these rules in the OpenCTI adapter layer and modify them according to the needs of your adapter.

You need to map event data received from the Computer Telephony Integration (CTI) server to a clipboard page by using a parse rule, such as an XML or JSON parser.

After you map the event data to the clipboard page, call the HandleEvent activity of ChannelServices-Embed-Adapter-OpenCTI, which maps these properties to the ChannelServices-Event-CTILink clipboard page. The HandleEvent activity starts the processing of an event.

The processing of an event consists of the following actions:

  • Retrieving the CSR's device presence data with the RetrieveDevicePresence activity.
  • Identifying the corresponding OpenCTI event with the SetEventType decision tree.
  • Filtering the event based on your selected telephony mode with the FilterEvent activity.
  • Filtering the event based on device capabilities with the FilterEventsOnDeviceCapabilities decision tree.
  • Mapping events to a format recognized by Pega Call with the ConvertEvent activity.
  • Sending the event to the CSR desktop.
  • Specialized processing of the event after sending the event to the CSR desktop with the EventPostProcessing activity.

The activities listed in the following section are used to process events. These activities use the OpenCTI adapter class rules to receive any format of event data and modify it into the data structure required by the Call Control Panel.

Copy these activities from the OpenCTI base adapter class and implement them in your implementation class.

RetrieveDevicePresence activity
This activity is used in the retrieval of the CSR workstation ID and client handle from the CSR presence object. The contextual data retrieved is used in building the event in a Pega format and delivering the event to the Call Control Panel. Override the PopulatePresenceKeys data transform to populate the OpenCTI adapter implementation presence keys, if the implementation uses a different key than the key provided by the OpenCTI interface.
IdentifyEvent activity
This activity identifies which Pega Call event corresponds to the event received. This activity uses the decision tree SetEventType to identify the event. You need to override this only if a different decision rule type is needed by your adapter.
SetEventType decision tree
This rule converts the CTI server event agent state or call state into the agent or call state used by the Call Control Panel. You can copy this decision tree into the adapter class and modify it to identify the corresponding Pega Call event.
For example, if the CTI server event agent state is Talking, then add an if condition to this rule: if AgentState = “Talking”, return “Busy”. When modifying existing if conditions, do not change the return value. The return values listed in the decision tree are the states used by the Call Control Panel.
FilterEvent activity
This activity is used to filter any events that are not required by Pega Call. This activity uses the FilterEvent when rule to update the SendEvent property. Override this when rule to set the SendEvent property to either True or False depending on the event type. By default, this when rule returns False.
FilterEventsOnDeviceCapabilities decision tree
This decision tree is used to filter call or agent state events based on the Call Control Panel capabilities.
ConvertEvent activity
This activity maps properties to the Pega Call event page with data for each Pega Call event by using PopulateEventData data transforms. These data transforms are called from the ConvertEvent activity.
PopulateEvent data transforms
These are a collection of data transforms that represent the events that are recognized by Pega Call. These data transforms copy the data from the OpenCTI adapter implementation page to the CTI event page. Copy these data transforms from the OpenCTI interface class into the OpenCTI implementation adapter class and map the values of the properties on the source side of the data transform with the corresponding property from the adapter.
Do not change the contents of the event name property.
There may be instances where the event data model from the CTI server system does not fit into the OpenCTI event model when using the listed decision tree and data transforms. In these cases, there are two activities that can be copied and overridden.
This activity allows for any processing that might be required after the event is sent.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best. is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us