Discussions

Ask a Question
Back to All

Exposing rejected time-offs request to the public API

Exposing rejected time-offs request to the public API

Hello Personio team,

Currently, there is no easy way of checking whether a previously created time-off has been rejected in personio, because the entries are deleted.

The only 2 ways to check if entries have been removed is

  1. polling GET /company/time-offs/{id} for each id that should be checked, and checking for 404
  2. polling GET /company/time-offs, and checking if the records returned still contain the id in question.

Both of which are quite a strain on the public API.

Some suggested ways to fix the issue

  1. Don't delete time-offs, just change the status field
  2. In the request GET /company/time-offs, if the updated_from parameter is set, send some sort of tombstone for the deleted ids
  3. In the request GET /company/time-offs, allow querying for a list of ids. (can still get quite large if a lot of time-offs need to be checked

I know you are currently testing webhooks in alpha, and I suspect you also plan on exposing webhooks for time-offs, but making this functionality available via the REST-API would be much appreciated.

Thanks in advance!