Queue Management – Log in or Log out Agents

Bulk log in or log out dynamic agents in the specified queue.

Request URL

GET {base_url}/{api_path}/queue/agent_login?access_token={access_token}

Request parameters

Parameter Required Type Description
ext_ids Yes String The extension ID(s) of the dynamic agent(s).
Note:
queue_id Yes Integer The unique ID of the queue.
Note: You can query the queue's ID using Search Specific Queues.
operation Yes String Log in or log out agents in the queue.
Valid value:
  • login: Log in the dynamic agent to the queue.
  • logout: Log out the dynamic agent from the queue.
is_paused No Integer Whether to pause service for dynamic agents after logging them to the queue.
Valid value:
  • 0: Do NOT pause service for agents after logging them to the queue.
  • 1: Pause service for agents after logging them to the queue.
Note: If you don't configure this parameter, it will be filled with the default value 0.
max_threshold_for_pause_time No Integer The amount of time in seconds that the dynamic agent(s) will pause service.
Valid value:
  • 0: Remain paused unless a new request is made to unpause service for the agents.
  • 10 or greater: The specific pause time. After the timeout, automatically unpause service for agents.
max_threshold_for_logout_time No Integer The amount of time in seconds that the dynamic agent(s) will log out from the queue.

Valid value:

  • 0: Remain logout unless a new request is made to log the agents to the queue.
  • 10 or greater: The specific logout time. After the timeout, automatically log the agents to the queue.
reason No String Feature code for the pause reason.
Valid value: The feature code for the existing pause reasons on PBX.
Note:
  • If the PBX plan subscription is NOT Enterprise Plan or Ultimate Plan, do NOT pass this parameter, otherwise the request will fail.
  • You can query the feature code for the existing pause reasons using Query Queue Pause Reason List.

Response parameters

Parameter Type Description
errcode Integer Returned error code.
  • 0: Succeed.
  • Non-zero value: Failed.
Note: You can check the error code and error message in Error Code and Error Message.
errmsg String Returned message.
  • SUCCESS: Succeed.
  • FAILURE: Failed.

Examples

Request example

Log in two dynamic agents (Extension ID: 21 & 24) to a queue (ID: 1) and pause service for the two agents for 5 minutes after login.

GET /openapi/v1.0/queue/agent_login?access_token=pL1Xyk5cHf13p2eCkuJBX9i94O9OpMtf&ext_ids=21,24&queue_id=1&operation=login&is_paused=1&max_threshold_for_pause_time=300 HTTP/1.1
Host: 192.168.5.150:8088
Response example
HTTP/1.1 200 OK
{
    "errcode": 0,
    "errmsg": "SUCCESS"
}