Search absences
Operation ID: searchAbsences
Group: People Management › Absences
Open in the interactive reference
POST /people/absences/search
Read-only: A read that takes its filters in the body. Changes nothing, and ignores Idempotency-Key.
Searches absences.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Api-Version |
header | string · v1 | yes | The API version this request targets, named by its public identifier. Required on every request; omitting it, or naming a version this company does not have, is answered with 400. This document describes version v1. |
Request body
Required, application/json: searchAbsencesInput.
| Field | Type | Required | Description |
|---|---|---|---|
filters |
object | yes | The filters to apply. An absence must match every filter you send. Omit to return all absences. |
filters.employeeId |
string | no | Limits results to absences for this employee. |
filters.absenceTypeId |
string | no | Limits results to absences of this absence type. |
filters.status |
any | no | Limits results to absences with this status. One of: "requested", "approved", "rejected", "canceled". |
filters.startsAfter |
date-time | no | Limits results to absences whose startDate is on or after this value, in UTC. Format YYYY-MM-DDTHH:mm:ss.sssZ. |
filters.endsBefore |
date-time | no | Limits results to absences whose endDate is on or before this value, in UTC. Format YYYY-MM-DDTHH:mm:ss.sssZ. |
filters.descriptionContains |
string | no | Limits results to absences whose description contains this text. The match is case-insensitive. |
page |
object | no | Pagination controls. Omit for the first page. |
page.cursor |
string | no | The cursor from the previous response's pagination.nextCursor. Omit on the first request. |
page.size |
number | no | The number of absences per page, at most 100. Defaults to 25. A value above 100 is treated as 100, not rejected. |
{
"filters": {
"employeeId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"absenceTypeId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"status": "requested",
"startsAfter": "2026-01-15T09:30:00.000Z",
"endsBefore": "2026-01-15T09:30:00.000Z",
"descriptionContains": "<descriptionContains>"
},
"page": {
"cursor": "<cursor>",
"size": 0
}
}
Response
200 Success
Under data (searchAbsencesOutput):
| Field | Type | Required | Description |
|---|---|---|---|
items |
array<object> | yes | The absences on this page. An empty array when nothing matches. |
items[].id |
string | yes | The unique identifier for the absence. |
items[].leaveNumber |
string | no | The absence number. |
items[].employeeId |
string | yes | The employee the absence belongs to. See id on GET people/person/:id. |
items[].absenceTypeId |
string | yes | The type of the absence. See id on GET people/absence-types/:id. |
items[].startDate |
date-time | yes | The date and time the absence starts, in UTC. Format YYYY-MM-DDTHH:mm:ss.sssZ. |
items[].endDate |
date-time | yes | The date and time the absence ends, in UTC. Format YYYY-MM-DDTHH:mm:ss.sssZ. |
items[].days |
decimal | no | The number of absence days. May be fractional for partial days. |
items[].status |
any | no | The status of the absence. One of: "requested", "approved", "rejected", "canceled". |
items[].leaveDescription |
string | no | The reason for the absence. |
pagination |
object | yes | The pagination details for this page. |
pagination.nextCursor |
string | no | The cursor for the next page. Pass it as page.cursor. Absent on the last page. |
pagination.hasMore |
boolean | yes | Whether more absences remain after this page. |
{
"data": {
"items": [
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"leaveNumber": "<leaveNumber>",
"employeeId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"absenceTypeId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"startDate": "2026-01-15T09:30:00.000Z",
"endDate": "2026-01-15T09:30:00.000Z",
"days": "19.99",
"status": "requested",
"leaveDescription": "<leaveDescription>"
}
],
"pagination": {
"nextCursor": "<nextCursor>",
"hasMore": true
}
},
"diagnostics": [
{
"code": "<code>",
"message": "<message>",
"severity": "error",
"path": [
"<path>"
],
"details": "<details>"
}
]
}
Statuses
400— Invalid request or business failure401— The request carries no valid access token.403— Not authorized404— Not found429— Too many requests from this client address. The response has no body and noRetry-Afterheader.500— Internal server error