Change Agent State
Use the User - Change agent state API to change the agent state to Ready.
This example uses the same agent information as the previous example.
Note | This example shows the URL field for a Unified CCE deployment. In a Unified CCX deployment, you must include the port number in the URL. |
-
In Postman, enter the following string in the URL field:
https://finesse1.xyz.com/finesse/api/User/1234
-
Enter the agent's ID (1234) and password (1001) in the two User Auth fields directly under the URL field.
-
In the Content Type field, enter application/XML.
-
In the area under Content Options, enter the following:
<User> <state>READY</state> </User>
-
(Optional) To add the requestId:
-
Click Headers.
-
In the Name field, enter requestId, and in the Value field, enter xyz.
-
Click Add/Change
-
-
Click PUT.
Postman returns the following response:
PUT on https://finesse1.xyz.com/finesse/api/User/1234 Status 202: Accepted
Finesse returns the following user notification:
<Update> <data> <user> <dialogs>/finesse/api/User/1234/Dialogs</dialogs> <extension>1001</extension> <firstName>John</firstName> <lastName>Smith</lastName> <loginId>1234</loginId> <loginName>jsmith</loginName> <roles> <role>Agent</role> </roles> <state>READY</state> <pendingState></pendingState> <settings> <wrapUpOnIncoming></wrapUpOnIncoming> <wrapUpOnOutgoing></wrapUpOnOutgoing> </settings> <stateChangeTime>2014-05-27T00:35:24.123Z</stateChangeTime> <teamId>1</teamId> <teamName>Default</teamName> <uri>/finesse/api/User/1234</uri> </user> </data> <event>PUT</event> <requestId>xyz</requestId> <source>/finesse/api/User/1234</source> </Update>