Updated on 2023-09-27 GMT+08:00

Querying the Statistics About a Set of Skill Queues

Prerequisites

  • The agent has signed in.

Description

This interface is used to query the statistics about a set of skill queues after an agent has signed in.

Interface Method

The request method must be set to POST. This interface supports only the POST method.

URI

https://ip:port/agentgateway/resource/queuedevice/{agentid}/queryacdstat

In the URL, ip indicates the IP address of the CC-Gateway server, and port indicates the HTTPS port number of the CC-Gateway server.

Table 1 Parameter in the URI

No.

Parameter

Data Type

Mandatory (Yes/No)

Description

1

agentid

string

Yes

Agent ID. The value ranges from 101 to 59999.

Method Name in Logs

queryStatInfoOfAcd

Request Description

  • Message header
    Table 2 Parameters in the request message header

    No.

    Parameter

    Value Type

    Mandatory (Yes/No)

    Description

    1

    Content-Type

    string

    Yes

    Coding mode of the message body. The default value is application/json; charset=UTF-8.

    2

    Guid

    string

    Yes

    GUID returned by the sign-in interface during static authentication (AUTHMODE is set to 1) or GUID returned by the polling event query interface during dynamic authentication (AUTHMODE is set to 2).

  • Message body
    Table 3 Parameters in the message body

    No.

    Parameter

    Value Type

    Mandatory (Yes/No)

    Description

    1

    skills

    List

    Yes

    Indicates a list of skill queue IDs. The maximum array size is 100.

Response Description

Table 4 Parameters in the message body

No.

Parameter

Value Type

Description

1

message

string

Description.

2

retcode

string

Error code. The options are as follows:

0: success

Other values: failure

3

result

array

Indicates the return result of a successful query, that is, skill queue statistics.

For details about the parameters of this object, see Table 5.

Table 5 Parameter description of result

No.

Parameter

Value Type

Description

4.1

pilotNbr

string

The pilot number of ACD group (It means accesscode.)

4.2

deviceNo

int

Skill queue ID.

4.3

queueSize

int

The number of calls in waiting queue

4.4

queueTime

long

The maximum duration of call in waiting queue (second)

4.5

loadFactor

int

It is not used.

4.6

estWaitTime

long

It is not used.

4.7

loggedOnAgents

int

Number of agents signing in to this ACD group.

4.8

availAgents

int

The number of available agents in this ACD group

4.9

transferFlg

int

Transfer flag (0: release; 2: transfer)

4.10

transferDeviceType

int

Device type. For details, see Device Type.

4.11

transferDeviceNo

int

Device number

4.12

skillDescrip

string

Skill description.

4.13

resourceIdleRate

int

It is not used.

4.14

serviceLevel

int

It is not used.

4.15

oldCallIdEx

object

The call ID information object of waiting maximum duration.

For details about the parameters of this object, see Table 6.

4.16

maxQueueSize

int

The max number of calls in the queue

Table 6 Parameter description of oldCallIdEx

No.

Parameter

Value Type

Description

4.15.1

dateTime

Date

The time of call entering

4.15.2

dsn

int

The task number of call entering

4.15.3

server

int

Unique server identifier.

4.15.4

handle

int

The number of times that a call enters a task.

The method of converting oldCallIdEx to callId:

StringBuilder buffer = new StringBuilder(24);

buffer.append(dateTime);

buffer.append('-');

long identify = ((long) server << 24) + ((long) handle << 16) + dsn;

buffer.append(identify);

Triggered Event

  • None

Error Code

  • 000-002
  • 100-006
  • 100-007

Example

  • Message header
    Content-Type:application/json; charset=UTF-8
    Guid: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.AgentGateway1
  • Request parameter
    {
        "skills": [
            1,
            10
        ]
    }
  • Response parameter
    {
        "message": "",
        "retcode": "0",
        "result": [
            {
                "pilotNbr": "",
                "deviceNo": 1,
                "queueSize": 0,
                "queueTime": 0,
                "loadFactor": 65535,
                "estWaitTime": 0,
                "loggedOnAgents": 1,
                "availAgents": 1,
                "transferFlg": 0,
                "transferDeviceType": 255,
                "transferDeviceNo": 65535,
                "skillDescrip": "chat_madeqiang",
                "resourceIdleRate": 100,
                "serviceLevel": 100,
                "oldCallIdEx": {
                    "dateTime": 4294967295000,
                    "dsn": 65535,
                    "server": 255,
                    "handle": 255
                },
                "maxQueueSize": 100
            },
            {
                "pilotNbr": "1009",
                "deviceNo": 10,
                "queueSize": 0,
                "queueTime": 0,
                "loadFactor": 65535,
                "estWaitTime": 0,
                "loggedOnAgents": 2,
                "availAgents": 2,
                "transferFlg": 0,
                "transferDeviceType": 255,
                "transferDeviceNo": 65535,
                "skillDescrip": "chat_jinsitao",
                "resourceIdleRate": 100,
                "serviceLevel": 100,
                "oldCallIdEx": {
                    "dateTime": 4294967295000,
                    "dsn": 65535,
                    "server": 255,
                    "handle": 255
                },
                "maxQueueSize": 100
            }
        ]
    }