General - Get employee holidays
API Url
Used for loading all available holidays for an employee under each valid vacation type.
http://localhost:16010/ProMarkREST/rest/General/employees/{empId}/holidays
Permissions: user
Request headers
| Field | Type | Description |
|---|---|---|
Accept-Languageoptional | String | =en-GB Language use for localization. |
X-Clientoptional | String | =Client type. "Portal""Mobile""Admin" |
X-Roleoptional | Number | ProMark role (1: Employee, 2: User). {12} |
X-WebPart-Idoptional | Number | Unique web-part identifier. |
Path parameters
| Field | Type | Description |
|---|---|---|
| empId | String | Employee Identifier |
Query parameters
| Field | Type | Description |
|---|---|---|
fromoptional | integer | From holding period year (if viewDate is used this value is ignored) |
tooptional | integer | To holding period year (if viewDate is used this value is ignored) |
typeoptional | String | Holiday type |
viewDateoptional | date | View available holidays to till this date |
Success 200
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data. |
| holidays | Object[] | Collection of employee holidays |
accruedoptional | Date | Accrued holidays in accrued period |
accruedUntiloptional | Date | Accrued holidays till "view at" date for periodic accrued holiday types |
| description | String | Holiday type description |
| empId | String | Employee Identifier |
formatoptional | String | Account format ("HH:MM", "HH.CC", ".1", ".2" and so on) |
fromLastYearoptional | Date | Holidays from last year |
leftToTransferoptional | Number | Left holidays to transfer |
maxTransferoptional | Number | Maximun days to transfer |
| periodEnd | Date | Holiday period end date |
| periodStart | Date | Holiday period start date |
plannedoptional | Number | Planned holidays in the holiday period in future. If "view at" is defined, planned holidays after that date |
remainingoptional | Number | Remaining holidays at the end of holiday period |
remainingUntiloptional | Number | Remaining holidays until "view at" date against accured until date |
totaloptional | Number | Total holidays in the holiday period |
transferredoptional | Number | Transferred holidays in the holiday period |
transferRequestoptional | Number | Requested transfer holidays in the holdiday period |
| type | String | Holiday type identifier |
unitoptional | Number | Accounts unit (1: hours, 2: days). |
usedoptional | Number | Used holidays in the holiday period until today. If "View at" is defined, used holidays till that date |
messageoptional | Object | Object containing response messages. |
| code | Number | Message code. |
| text | String | Message text. |
| type | String | Type of message. "warning""info" |
Success example:
HTTP/1.1 200 OK{"response": {"data": {"holidays": [{"empId": "468","type": "EXTRA","description": "Extra Holiday","periodStart": "2017-01-01","periodEnd": "2017-12-31","fromLastYear": 0,"accrued": 0,"total": 0,"used": 0,"planned": 0,"remaining": 0,"maxTransfer": 0,"transferRequest": 0,"transferred": 0,"leftToTransfer": 0,"unit": 1,"format": "HH:MM"},{"empId": "468","type": "EXTRA","description": "Extra Holiday","periodStart": "2018-01-01","periodEnd": "2018-12-31","fromLastYear": 0,"accrued": 180000,"total": 180000,"used": 0,"planned": 0,"remaining": 180000,"maxTransfer": 36000,"transferRequest": 0,"transferred": 0,"leftToTransfer": 36000,"unit": 1,"format": "HH:MM"}]},"errorCode": 0,"errorMessage": ""}}