Skip to content

Absence Confirmations

Valid Attributes

AttributeDescriptionDetails
absence_idThe ID of the absence.Cannot be set.
actor_idThe ID of the actor (i.e. user) who confirmed the absenceCannot be set.
statusThe status of the absence confirmation entry.Must be either confirmed or rejected

Create

Example request:

{
"data": {
"id": "b9996264-9d3d-4658-bd81-fd744679904f",
"type": "absence_confirmation",
"attributes": {
"status": "confirmed"
}
}
}

Example response:

{
"data": {
"id": "a6e9e2f8-5b4e-4a4b-8c7e-6a5b85a3c2b1",
"type": "absence",
"attributes": {
"user_id": "9f8d7c6b-5a4e-3d2c-1b0a-9e8f7d6c5b4a",
"absence_type_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"starts_at": "2025-10-02",
"ends_at": "2025-10-10",
"status": "confirmed"
}
}
}

This endpoint creates a new absence_confirmation entry associated with the specified absence.

Once all required confirmations have been submitted, the corresponding absence record is automatically updated with the new status and returned in the response.

HTTP Request

POST /api/v1/absences/:absence_id/confirmation

URL Parameters

ParameterDescription
absence_idThe ID of the absence to confirm or reject

Delete

Example response:

{
"data": {
"id": "a6e9e2f8-5b4e-4a4b-8c7e-6a5b85a3c2b1",
"type": "absence",
"attributes": {
"user_id": "9f8d7c6b-5a4e-3d2c-1b0a-9e8f7d6c5b4a",
"absence_type_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"starts_at": "2025-10-02",
"ends_at": "2025-10-10",
"status": "created"
}
}
}

This endpoint withdraws a previously submitted absence_confirmation. If a user has confirmed or rejected an absence, their confirmation entry is discarded and the corresponding absence record is automatically reset to the status created.

HTTP Request

DELETE /api/v1/absences/:absence_id/confirmation

URL Parameters

ParameterDescription
absence_idThe ID of the absence to unconfirm