Zum Inhalt springen
Leadtime
Deutsch
Esc
↑↓navigieren↵öffnen⌘Jvorschau

Request sick days

Creates a new sick days record for the current employee.

How sick days work:

  1. Employee reports sick days with start and end dates
  2. Optional comment can be added
  3. Medical certificates can be attached (upload files first, then provide file IDs)
  4. System automatically checks for overlapping events

To upload medical certificates:

  1. Call POST /api/public/workspace/upload for each file
  2. Get the file ID from the response
  3. Include the file IDs in the attachedFilesIds array

Note: This endpoint is only available for employee accounts. The system validates that there are no overlapping events (vacations, other sick days, etc.) for the specified period.

POST/account/employee/sick-days/request
Authorization
AuthorizationOAuth2 access token · headerrequired
Scopes:api:write
or
AuthorizationBearer token (JWT) · headerrequired
Request body
requiredapplication/json
attachedFilesIdsstring[]

Array of file IDs for medical certificates (upload via POST /api/public/workspace/upload first)

commentstring

Optional comment about the sickness

dateFromstringrequired

Start date of sickness

dateTostringrequired

End date of sickness

Responses
200
successbooleanrequired

Operation success flag

400

Validation errors

errorsobject
Show properties
dateFromstring[]
dateTostring[]
globalErrorsstring[]
messagestring
statusCodenumber
401

Unauthorized - Invalid or missing authentication token

403

Forbidden - Insufficient API scopes or permissions

Try it
Server
Authorization
Bodyapplication/json
Request
curl -X POST "https://leadtime.app/api/public/account/employee/sick-days/request" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "attachedFilesIds": [
    "string"
  ],
  "comment": "Flu symptoms",
  "dateFrom": "2024-06-01T00:00:00.000Z",
  "dateTo": "2024-06-03T00:00:00.000Z"
}'
Response
{
  "success": true
}