Specification

In addition to the documentation on this page, you can also download a spec file describing the API:

Resources

Person

Get all persons as bulk download

A GET request is used to retrieve all persons that have hr data and download them as bulk.

Curl request
$ curl 'http://localhost:8080/api/person/bulk' -i -X GET \
    -H 'Accept: application/vnd.hal+json'
HTTP request
GET /api/person/bulk HTTP/1.1
Accept: application/vnd.hal+json
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/vnd.hal+json
Content-Length: 1082

{"_embedded":{"employeeDataList":[{"_links":{"self":{"href":"http://localhost:8080/api/person/pkid999"}},"active":true,"costCenter":"costcenter","department":"department","email":"email","firstname":"firstname","hr":{"address":{"city":null,"country":null,"countryCode":null,"postcode":null,"street":null},"contracts":[{"area":{"code":"10","name":"area 1"},"businessUnit":{"code":"1100","name":"business unit"},"company":{"code":"0020","name":"company 20"},"costCenterCode":null,"department":{"code":null,"name":null},"employeeClass":null,"functionCodeName":null,"group":{"code":null,"name":null},"hireDate":null,"locationName":null,"logaCompany":null,"logaPnr":null,"managementLevel":null,"manager":null,"managerPkId":null,"sapPnr":null,"subteam":{"code":null,"name":null},"team":{"code":null,"name":null},"terminationDate":null}],"dateOfBirth":null,"firstname":null,"lastname":null,"nationalId":null,"nationality":null,"pkId":"pkid999","secondTitle":null,"title":null},"identification":"pkid999","lastname":"lastname","phoneNumber":"1234567890","phoneNumberMobile":"1234567890"}]}}
HTTPie request
$ http GET 'http://localhost:8080/api/person/bulk' \
    'Accept:application/vnd.hal+json'
Request body
Response body
{"_embedded":{"employeeDataList":[{"_links":{"self":{"href":"http://localhost:8080/api/person/pkid999"}},"active":true,"costCenter":"costcenter","department":"department","email":"email","firstname":"firstname","hr":{"address":{"city":null,"country":null,"countryCode":null,"postcode":null,"street":null},"contracts":[{"area":{"code":"10","name":"area 1"},"businessUnit":{"code":"1100","name":"business unit"},"company":{"code":"0020","name":"company 20"},"costCenterCode":null,"department":{"code":null,"name":null},"employeeClass":null,"functionCodeName":null,"group":{"code":null,"name":null},"hireDate":null,"locationName":null,"logaCompany":null,"logaPnr":null,"managementLevel":null,"manager":null,"managerPkId":null,"sapPnr":null,"subteam":{"code":null,"name":null},"team":{"code":null,"name":null},"terminationDate":null}],"dateOfBirth":null,"firstname":null,"lastname":null,"nationalId":null,"nationality":null,"pkId":"pkid999","secondTitle":null,"title":null},"identification":"pkid999","lastname":"lastname","phoneNumber":"1234567890","phoneNumberMobile":"1234567890"}]}}
Response fields
Path Type Description

_embedded.employeeDataList

Array

list of persons, incl. hr data

_embedded.employeeDataList[].identification

String

the employee’s pk id

_embedded.employeeDataList[].firstname

String

the employee’s first name

_embedded.employeeDataList[].lastname

String

the employee’s last name

_embedded.employeeDataList[].email

String

the employee’s email

_embedded.employeeDataList[].phoneNumber

String

the employee’s phone number

_embedded.employeeDataList[].phoneNumberMobile

String

the employee’s mobile phone number

_embedded.employeeDataList[].costCenter

String

the employee’s cost center

_embedded.employeeDataList[].department

String

the employee’s department

_embedded.employeeDataList[].active

Boolean

the employee’s active state

_embedded.employeeDataList[].hr

Object

the employee’s hr data (only present in bulk download)

Get all persons

A GET request is used to retrieve all persons.

Curl request
$ curl 'http://localhost:8080/api/person/pkid110' -i -X GET \
    -H 'Accept: application/vnd.hal+json'
HTTP request
GET /api/person/pkid110 HTTP/1.1
Accept: application/vnd.hal+json
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/vnd.hal+json
Content-Length: 343

{"_links":{"self":{"href":"http://localhost:8080/api/person/pkid110"},"related":{"href":"http://localhost:8080/api/person/hr/pkid110","name":"hr","title":"hr data"}},"active":null,"costCenter":null,"department":null,"email":null,"firstname":null,"hr":null,"identification":"pkid110","lastname":null,"phoneNumber":null,"phoneNumberMobile":null}
HTTPie request
$ http GET 'http://localhost:8080/api/person/pkid110' \
    'Accept:application/vnd.hal+json'
Relation Description

self

the page’s self link

related

the person’s hr data link

Path parameters
Table 1. /api/person/{pkId}
Parameter Description

pkId

the person’s pk id

Request body
Response body
{"_links":{"self":{"href":"http://localhost:8080/api/person/pkid110"},"related":{"href":"http://localhost:8080/api/person/hr/pkid110","name":"hr","title":"hr data"}},"active":null,"costCenter":null,"department":null,"email":null,"firstname":null,"hr":null,"identification":"pkid110","lastname":null,"phoneNumber":null,"phoneNumberMobile":null}
Response fields
Path Type Description

identification

String

the employee’s pk id

firstname

Null

the employee’s first name

lastname

Null

the employee’s last name

email

Null

the employee’s email

phoneNumber

Null

the employee’s phone number

phoneNumberMobile

Null

the employee’s mobile phone number

costCenter

Null

the employee’s cost center

department

Null

the employee’s department

active

Null

the employee’s active state

hr

Null

the employee’s hr data (only present in bulk download)

Get one person

A GET request is used to retrieve one person by id.

Curl request
$ curl 'http://localhost:8080/api/person/pkid110' -i -X GET \
    -H 'Accept: application/vnd.hal+json'
HTTP request
GET /api/person/pkid110 HTTP/1.1
Accept: application/vnd.hal+json
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/vnd.hal+json
Content-Length: 343

{"_links":{"self":{"href":"http://localhost:8080/api/person/pkid110"},"related":{"href":"http://localhost:8080/api/person/hr/pkid110","name":"hr","title":"hr data"}},"active":null,"costCenter":null,"department":null,"email":null,"firstname":null,"hr":null,"identification":"pkid110","lastname":null,"phoneNumber":null,"phoneNumberMobile":null}
HTTPie request
$ http GET 'http://localhost:8080/api/person/pkid110' \
    'Accept:application/vnd.hal+json'
Relation Description

self

the page’s self link

related

the person’s hr data link

Path parameters
Table 1. /api/person/{pkId}
Parameter Description

pkId

the person’s pk id

Request body
Response body
{"_links":{"self":{"href":"http://localhost:8080/api/person/pkid110"},"related":{"href":"http://localhost:8080/api/person/hr/pkid110","name":"hr","title":"hr data"}},"active":null,"costCenter":null,"department":null,"email":null,"firstname":null,"hr":null,"identification":"pkid110","lastname":null,"phoneNumber":null,"phoneNumberMobile":null}
Response fields
Path Type Description

identification

String

the employee’s pk id

firstname

Null

the employee’s first name

lastname

Null

the employee’s last name

email

Null

the employee’s email

phoneNumber

Null

the employee’s phone number

phoneNumberMobile

Null

the employee’s mobile phone number

costCenter

Null

the employee’s cost center

department

Null

the employee’s department

active

Null

the employee’s active state

hr

Null

the employee’s hr data (only present in bulk download)

HR

Get one person’s HR data

A 'GET' request is used to retrieve one person’s HR data by id

Curl request

$ curl 'http://localhost:8080/api/person/hr/pkid110' -i -X GET \
    -H 'Accept: application/vnd.hal+json'

HTTP request

GET /api/person/hr/pkid110 HTTP/1.1
Accept: application/vnd.hal+json
Host: localhost:8080

HTTP response

HTTP/1.1 200 OK
Content-Type: application/vnd.hal+json
Content-Length: 826

{"_links":{"self":{"href":"http://localhost:8080/api/person/hr/pkid110"}},"address":{"city":null,"country":null,"countryCode":null,"postcode":null,"street":null},"contracts":[{"area":{"code":"10","name":"area 1"},"businessUnit":{"code":"1100","name":"business unit"},"company":{"code":"0020","name":"company 20"},"costCenterCode":null,"department":{"code":null,"name":null},"employeeClass":null,"functionCodeName":null,"group":{"code":null,"name":null},"hireDate":null,"locationName":null,"logaCompany":null,"logaPnr":null,"managementLevel":null,"manager":null,"managerPkId":null,"sapPnr":null,"subteam":{"code":null,"name":null},"team":{"code":null,"name":null},"terminationDate":null}],"dateOfBirth":null,"firstname":null,"lastname":null,"nationalId":null,"nationality":null,"pkId":"pkid110","secondTitle":null,"title":null}

HTTPie request

$ http GET 'http://localhost:8080/api/person/hr/pkid110' \
    'Accept:application/vnd.hal+json'
Relation Description

self

the page’s self link

Path parameters

Table 1. /api/person/hr/{pkId}
Parameter Description

pkId

the person’s pk id

Request body

Response body

{"_links":{"self":{"href":"http://localhost:8080/api/person/hr/pkid110"}},"address":{"city":null,"country":null,"countryCode":null,"postcode":null,"street":null},"contracts":[{"area":{"code":"10","name":"area 1"},"businessUnit":{"code":"1100","name":"business unit"},"company":{"code":"0020","name":"company 20"},"costCenterCode":null,"department":{"code":null,"name":null},"employeeClass":null,"functionCodeName":null,"group":{"code":null,"name":null},"hireDate":null,"locationName":null,"logaCompany":null,"logaPnr":null,"managementLevel":null,"manager":null,"managerPkId":null,"sapPnr":null,"subteam":{"code":null,"name":null},"team":{"code":null,"name":null},"terminationDate":null}],"dateOfBirth":null,"firstname":null,"lastname":null,"nationalId":null,"nationality":null,"pkId":"pkid110","secondTitle":null,"title":null}

Response fields

Path Type Description

pkId

String

the person’s pk id

address

Object

the person’s living address (country, countryCode, city, postcode, street)

title

Null

the person’s title

firstname

Null

the person’s first name

lastname

Null

the person’s last name

dateOfBirth

Null

the person’s date of birth

secondTitle

Null

the person’s second title

nationalId

Null

the person’s national id

nationality

Null

the person’s nationality

contracts[].sapPnr

Null

the person’s SAP personal number

contracts[].costCenterCode

Null

the person’s cost center code

contracts[].employeeClass

Null

the person’s employee class

contracts[].hireDate

Null

the person’s hire date

contracts[].terminationDate

Null

the person’s termination date

contracts[].functionCodeName

Null

the person’s function code name

contracts[].managementLevel

Null

the person’s management level

contracts[].manager

Null

the person’s manager

contracts[].managerPkId

Null

the person’s manager - pk id

contracts[].locationName

Null

the person’s location name

contracts[].logaCompany

Null

the person’s loga company

contracts[].logaPnr

Null

the person’s loga personal number

contracts[].area

Object

the person’s area

contracts[].businessUnit

Object

the person’s business unit

contracts[].company

Object

the person’s company

contracts[].department

Object

the person’s department

contracts[].group

Object

the person’s group

contracts[].team

Object

the person’s team

contracts[].subteam

Object

the person’s sub-team