Updated on 2024-03-05 GMT+08:00

Processing Call Data

To obtain call data, you need to process and submit the integration address form on the server and add the processing logic to return the obtained data to the page. The processing varies according to the server. Table 1 describes the main call parameters passed. The sample code is in Java+Spring Boot+template (Thymeleaf) mode. For details, see the following steps.

Table 1 Parameter description

Parameter

Description

callerNum

Calling number.

  • When the call center receives an inbound call, the customer number is the calling number.
  • When the call center makes an outbound call, the system access code (or the outbound calling number configured in the system) is the calling number.

calledNum

Called number.

  • When the call center receives an inbound call, the system access code is the called number.
  • When the call center makes an outbound call, the customer number is the called number.

callid

Session ID.

Unique ID of the current session in a call. The value must be the same as that of Call S/N on the Customer Contact History > Contact Record page.

mediaType

Media type.

  • 1: voice or video call
  • 5: multimedia text chat

callType

Call type.

  • 0: inbound call
  • 1: outbound call (Multimedia text chats do not support this call type.)

workNo

Platform agent ID of the agent that performs the current operation.

callskill

Skill queue used by the agent in a call.

callskillid

ID of the skill queue used by the agent in a call.

agentName

Business account of the agent in a call.

  1. Create a Maven project.
  2. Add the dependency on the template engine Thymeleaf to the pom.xml file of the project.

          <dependency>
           <groupId>org.springframework.boot</groupId>
           <artifactId>spring-boot-starter-thymeleaf</artifactId>
       </dependency>

  3. Compile the controller. The controller is used to receive parameters submitted using the form, save the parameters to a map object (request in the following figure), and pass the parameters to the template. Figure 1 shows the sample code.

    Figure 1 Sample code of the controller

  4. Add the corresponding Thymeleaf template. Figure 2 shows the resource path.

    Figure 2 Resource path

    Figure 3 shows the content of hello.html.

    Figure 3 hello.html