Use case 4: See the Extension or Workstation user name associated to an employee
Follow this example to see the Extension or Workstation username associated to an employee/user.
Prerequisites
- You have obtained the user/employee ID using the User Management API.
- Assume the user/employee ID is 4000.
Steps
- Use the GET method on the API with the end point /wfo/user-mgmt-api/v1/employees/4000/workspace.
Sample Response:
Copy"data" : [ { "type" : "workspace", "id" : "4000", "attributes" :
{ "assets" : [ { "dataSourceID" : 101, "employeeID" : 4000,
"loginName" : "domain\\somelogin"} ] } } ] }Or:
Copy{ "data" : [ { "type" : "workspace", "id" : "4000", "attributes" :
{ "assets" : [ { "dataSourceID" : 101, "employeeID" : 4000,
"dataPortID" : 51} ] } } ] } - If the Extension is associated to an employee, get the Extension by calling /api/em/v2/datasources/101/dataports/51.