Payroll | Absence
Service to manage entities of type 'Absence'.
Overview
| URL | api/{tenantKey}/{orgKey}/payrollCore/absences | 
| Methods Supported | GET, POST, PUT, DELETE | 
All Operations
This service includes the following operations:
- GET:
 - POST:
 - PUT:
 - DELETE:
 
All Resources
This service uses the following resources:
All Enumerations
This service uses the following enumerations:
GET Absences
Returns the list of all the entity records available.
Response:
| When successful, the response body contains the list of records available. See AbsenceResource. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
GET Absences (paged)
Returns a page of the list of all the entity records available.
The following elements are optional:
| page | (int) The index of the page of the list that should be returned. This is a query string parameter. | 
| pageSize | (int) The number of page elements that should be returned (max. is 1000). This is a query string parameter. | 
Response:
| When successful, the response body contains the list of records available. See AbsenceResource. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
GET Absence by identifier
Returns the entity record that matches the specified identifier.
The following elements are required:
| id | (string) The record identifier. | 
Response:
| When successful, the response body contains the entity record. See AbsenceResource. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
GET Absence by key
Returns the entity record that matches the specified key.
The following elements are required:
| companyKey | (string) The company key. | 
| absenceKey | (int) Absence. | 
Response:
| When successful, the response body contains the entity record. See AbsenceResource. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
GET Print Absence by identifier
Prints the specified entity record.
The following elements are required:
| id | (string) The record identifier. | 
The following elements are optional:
| template | (string) The report template that should be used. This is a query string parameter. | 
Response:
| When successful, the response body contains a stream with the printed file. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 404 | NotFound. The specified resord does not exist. | 
Resource URL:
GET Print Absence by key
Prints the specified entity record.
The following elements are required:
| companyKey | (string) The company key. | 
| absenceKey | (int) Absence. | 
The following elements are optional:
| template | (string) The report template that should be used. This is a query string parameter. | 
Response:
| When successful, the response body contains a stream with the printed file. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
GET Original Print AbsenceOriginal by identifier
Prints the specified entity record.
The following elements are required:
| id | (string) The record identifier. | 
The following elements are optional:
| template | (string) The report template that should be used. This is a query string parameter. | 
Response:
| When successful, the response body contains a stream with the printed file. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 404 | NotFound. The specified resord does not exist. | 
Resource URL:
GET Original Print Absence by key
Prints the specified entity record.
The following elements are required:
| companyKey | (string) The company key. | 
| absenceKey | (int) Absence. | 
The following elements are optional:
| template | (string) The report template that should be used. This is a query string parameter. | 
Response:
| When successful, the response body contains a stream with the printed file. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
GET Export Absences
Custom operation 'ExportAbsences'.
The following elements are required:
| company | (string) Company. | 
| contract | (string) Contract. | 
| year | (int) Year. | 
| month | (int) Month. | 
Response:
| When successful, the response body contains a list of resources of type 'AbsencePartialResource'. See AbsencePartialResource. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
POST Absences
Creates a new entity record.
The following elements are required:
| absenceResource | (ApiAbsenceResource) The request body should contain the entity record that should be created. See ApiAbsenceResource.  | 
                            
Response:
| When successful, the response body contains the new entity record identifier. The resource header location property contains the URL for the new entity record. See ApiAbsenceResource. | 
Response status codes:
| 201 | Created. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
POST Import Absences
Custom operation 'ImportAbsences'.
The following elements are required:
| absences | (List | 
                            
Response:
| When successful, the response body is empty. | 
Resource URL:
PUT Set AbsenceWorkDays Absence
Updates the value of attribute 'AbsenceWorkDays' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (decimal) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
PUT Set AvailableAbsenseTypes Absence
Updates the value of attribute 'AvailableAbsenseTypes' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (int) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
PUT Set Company Absence
Updates the value of attribute 'Company' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (string) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
PUT Set Duration Absence
Updates the value of attribute 'Duration' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (decimal) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
PUT Set EndDate Absence
Updates the value of attribute 'EndDate' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (DateTime) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
PUT Set IsActive Absence
Updates the value of attribute 'IsActive' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (bool) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
PUT Set Remarks Absence
Updates the value of attribute 'Remarks' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (string) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
PUT Set StartDate Absence
Updates the value of attribute 'StartDate' in the specified entity record.
The following elements are required:
| absenceKey | (int) Absence. | 
| companyKey | (string) The company key. | 
| value | (DateTime) The request body should contain the new value for the attribute. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 200 | OK. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
Resource URL:
DELETE Absence by identifier
Deletes the entity record that matches the specified identifier.
The following elements are required:
| id | (string) The record identifier. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 204 | Deleted. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
DELETE Absence by key
Deletes the entity record that matches the specified key.
The following elements are required:
| companyKey | (string) The company key. | 
| absenceKey | (int) Absence. | 
Response:
| When successful, the response body is empty. | 
Response status codes:
| 204 | Deleted. The operation was completed successfully. | 
| 400 | BadRequest. The request parameters are invalid. | 
| 404 | NotFound. The specified record does not exist. | 
Resource URL:
Resources
AbsencePartialResource
The following elements are required:
| contract | (string) Contract. | 
| absenceType | (string) Absence Type. | 
| startDate | (DateTime) Start Date. | 
| company | (string) Company. | 
| absenceKey | (int) Absence. | 
| unit | (enum Unit) Unit.
									 See Unit.  | 
                            
| percentage | (decimal) Percentage. | 
The following elements are optional:
| duration | (decimal) Duration. | 
| endDate | (DateTime) End Date. | 
| availableAbsenseTypes | (int) Available Absense Types. | 
| employee | (string) Employee. | 
| remarks | (string) Remarks. | 
| absenceWorkDays | (decimal) Absence Work Days. | 
AbsenceResource
The following elements are required:
| absenceKey | (int) Absence. | 
| contract | (string) Contract.
									 (fk) Allowed value: the natural key of a record of type Contract. These records are accessibly through the Contracts service.  | 
                            
| absenceType | (string) Absence Type.
									 (fk) Allowed value: the natural key of a record of type AbsenceType. These records are accessibly through the AbsenceTypes service.  | 
                            
| startDate | (DateTime) Start Date. | 
| company | (string) Company.
									 (fk) Allowed value: the natural key of a record of type Company.  | 
                            
| unit | (enum Unit) Unit.
									 See Unit.  | 
                            
| percentage | (decimal) Percentage. | 
The following elements are optional:
| endDate | (DateTime) End Date. | 
| duration | (decimal) Duration. | 
| availableAbsenseTypes | (int) Available Absense Types. | 
| employee | (string) Employee.
									 (fk) Allowed value: the natural key of a record of type Employee. These records are accessibly through the Employees service.  | 
                            
| remarks | (string) Remarks. | 
| absenceWorkDays | (decimal) Absence Work Days. | 
ApiAbsenceResource
The following elements are required:
| contract | (string) Contract. | 
| absenceType | (string) Absence Type. | 
| startDate | (DateTime) Start Date. | 
| company | (string) Company. | 
| unit | (enum Unit) Unit.
									 See Unit.  | 
                            
| percentage | (decimal) Percentage. | 
The following elements are optional:
| endDate | (DateTime) End Date. | 
| duration | (decimal) Duration. | 
| availableAbsenseTypes | (int) Available Absense Types. | 
| remarks | (string) Remarks. | 
| absenceWorkDays | (decimal) Absence Work Days. |