Rate this page:

SmartQueueTask

A SmartQueue task is for a certain agent, which can be a call or a chat.
Add the following line to your scenario code to use the class:

require(Modules.SmartQueue);

Methods

addEventListener

Copy URL
addEventListener(event: 

SmartQueueEvents

,
callback:

Function

):

void

Adds a handler for the specified SmartQueueEvents event. Use only functions as handlers; anything except a function leads to the error and scenario termination when a handler is called.

Parameters

Returns

  • type:

    void

end

Copy URL
end(description: 

string

):

void

Ends the current task.

Parameters

  • description:

    string

Returns

  • type:

    void

removeEventListener

Copy URL
removeEventListener(event: 

SmartQueueEvents

,
callback:

Function

):

void

Removes a handler for the specified SmartQueueEvents event.

Parameters

Returns

  • type:

    void

Props

agentCall

Copy URL
agentCall: 

Call

|

null

The agent's Call object.

clientCall

Copy URL
clientCall: 

Call

|

null

The client's Call object.

id

Copy URL
id: 

string

A SmartQueue task's ID.

settings

Copy URL
settings: 

SmartQueueTaskParameters

SmartQueue task's settings, such as required skills, priority, queue and more.

status

Copy URL
status: 

SmartQueueTaskStatus

Current status of the task, whether it is distributing, connecting, connected, ended or failed.

terminationStatus

Copy URL
terminationStatus: 

TerminationStatus

|

null

Reason of task's termination.