# Time Off Entries

Time Off Entries represent the time and dates that a user has requested off from work, such as PTO or vacation days.

## Fetching a list of Time Off Entries

 - [GET /time_off_entries](https://developer.kantata.com/kantata/specification/time-off-entries/get-time-off-entries.md): Returns time off entries which are visible to the user. Items are visible to a user if
they are on the same account.


This endpoint returns structured Time Off Entry objects.
As with all Kantata OX API endpoints, the returned data will be referenced in sorted order in the results array
and will be indexed by ID in the time_off_entries top-level JSON key.
Please see our Response Format section for more information.

## Creating one or many Time Off Entries

 - [POST /time_off_entries](https://developer.kantata.com/kantata/specification/time-off-entries/create-time-off-entry.md): Creates a single or multiple time off entries for a user. Multiple time off entries can be created for
the same day, in a single request or separate requests. Entries for the same day are combined into one
time off entry. Time off hours cannot exceed the user's possible workday hours for that day.


This endpoint returns structured Time Off Entry objects.
As with all Kantata OX API endpoints, the returned data will be referenced in sorted order in the results array
and will be indexed by ID in the time_off_entries top-level JSON key.
Please see our Response Format section for more information.

## Delete multiple time off entries

 - [DELETE /time_off_entries](https://developer.kantata.com/kantata/specification/time-off-entries/delete-time-off-entries.md): The IDs of the time off entries to delete can be provided in the ids query parameter or via the request body.

Request body example:
{
  "ids": "1,2,3"
}

If any specified time off entries cannot be deleted, the entire request will fail and an error message
will be returned that specifies which ones could not be deleted and why.


This endpoint returns structured Time Off Entry objects.
As with all Kantata OX API endpoints, the returned data will be referenced in sorted order in the results array
and will be indexed by ID in the time_off_entries top-level JSON key.
Please see our Response Format section for more information.

## Updating an existing Time Off Entry

 - [PUT /time_off_entries/{id}](https://developer.kantata.com/kantata/specification/time-off-entries/update-time-off-entry.md): Update a Time Off Entry. Only the hours and external references can be modified. Time off hours cannot
exceed the user's possible workday hours for that day.


This endpoint returns structured Time Off Entry objects.
As with all Kantata OX API endpoints, the returned data will be referenced in sorted order in the results array
and will be indexed by ID in the time_off_entries top-level JSON key.
Please see our Response Format section for more information.

## Deleting an existing Time Off Entry

 - [DELETE /time_off_entries/{id}](https://developer.kantata.com/kantata/specification/time-off-entries/delete-time-off-entry.md): This will delete the time off entry.

The response will contain no content and an HTTP 204 status code if the request was
successful, or a standard Kantata OX error message explaining why the object could not be deleted.

