(Quick Reference) Service: Show an employee

Description: Returns the requested employee in json format when successful. Returns a json response, describing the failure condition when unsuccessful.

URL:

https://BASE_URL/api/VERSION/employees/{id}

URL with external_id:

https://BASE_URL/api/VERSION/employees/reference/{id}

Method: GET

Parameters:

NameDescriptionTypeRequiredExample values
idThe ID of the desired employeeLong/Stringyes12

Success Output

Success case: response.status=200

{
  "id": 22,
  "reference": "emp22",
  "firstName": "Jane",
  "lastName": "Doe",
  "mobile": "001-555-555-1212",
  "enabled": true,
  "managerReference": "emp-00",
  "employeeGroupReference": "60837-111",
  "manager": {
    "id": 3,
    "reference": "emp-00",
    "href": "/api/v1.0/employees/3"
  },
  "employeeGroup": {
    "id": 1,
    "reference": "60837-111",
    "name": "Group1",
    "href": "/api/v1.0/employeeGroups/1"
  },
  "avatar": null,
  "organization": "entity1",
  "dateCreated": "2016-08-17T13:45:17Z",
  "lastUpdated": "2016-08-17T13:45:17Z"
}

To get resized images, add prefix small_ or medium_ to the link url before the image's name, for example:
<BASE_URL>/entity1-1450169988465/avatar/medium_1471442935596_1448038178_supportfemale.png

Failure Output

Failure case:response.status = 400
{
  "error": "invalid_param_type",
  "error_description": "The type of parameter id you provided is not valid for this request."
}

Failure case:response.status = 404
{
  "error": "not_found",
  "error_description": "The employee with the id 7065 doesn't exist."
}