Discussions

Ask a Question
Back to all

Cannot book hourly sickness absence till midnight (API inconsistency with Attendance)

We’ve created an absence type for hourly sickness. The issue is that the API does not allow booking an absence until midnight.

  • The system does not allow bookings that cross midnight.
  • It also does not allow an absence booking to _end exactly at midnight (00:00).
  • However, in the Attendance API, this does work — we can book until midnight.

Example request that works for Attendance but fails for Absence:

{
  "person": {
    "id": "..."
  },
  "starts_from": {
    "date_time": "2025-08-19T23:00:00"
  },
  "ends_at": {
    "date_time": "2025-08-20T00:00:00"
  },
  "absence_type": {
    "id": "..."
  },
  "comment": "Test"
}

Expected behavior:
Absence bookings should behave consistently with Attendance bookings. It should be possible to book hourly sickness until midnight (23:00 → 00:00).

Actual behavior:

  • Request fails when booking absence until 00:00.
  • Same time range works fine in Attendance API.

Impact:

  • I cannot accurately record late-night sickness absences.
  • Causes inconsistency between Attendance and Absence APIs.