Tempo e presenze
Orario di lavoro, ferie, turni e festività — registra e leggi le presenze programmaticamente.
Orario di Lavoro
Endpoint
| GET | /employee-working-hours | Recupera la raccolta di risorse WorkTime. |
| POST | /employee-working-hours | Crea una risorsa WorkTime. |
| GET | /employee-working-hours/{id} | Recupera una risorsa WorkTime. |
| PATCH | /employee-working-hours/{id} | Aggiorna la risorsa WorkTime. |
| DELETE | /employee-working-hours/{id} | Rimuove la risorsa WorkTime. |
| GET | /work-times | Recupera la raccolta di risorse WorkTime. |
| POST | /work-times | Crea una risorsa WorkTime. |
| GET | /work-times/{id} | Recupera una risorsa WorkTime. |
| PATCH | /work-times/{id} | Aggiorna la risorsa WorkTime. |
| DELETE | /work-times/{id} | Rimuove la risorsa WorkTime. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | integer | |
| employee* | string (iri-reference) | |
| project* | string (iri-reference) | |
| date* | string (date-time) | |
| seconds* | integer | |
| description | stringnull | |
| projectTask | string,null (iri-reference) | Optional link to a {@see ProjectTask}. Nullable; existing rows have no link. Set by the Surface 1 picker chip and by Surface 2's close-and-log panel. The validator {@see \App\Validator\WorkTime\WorkTimeProjectTaskConsistencyConstraint} enforces that projectTask.project === workTime.project when this FK is set. On ProjectTask deletion the column is SET NULL — the time logged is preserved, the link is forgotten. |
| createdAt | string (date-time) | |
| updatedAt | string (date-time) | |
| deletedAt | string,null (date-time) | |
| deleted | boolean | Check if the entity has been soft deleted. |
Festività
Endpoint
| GET | /holidays | Recupera la raccolta di risorse Holiday. |
| POST | /holidays | Crea una risorsa Holiday. |
| GET | /holidays/{id} | Recupera una risorsa Holiday. |
| PATCH | /holidays/{id} | Aggiorna la risorsa Holiday. |
| DELETE | /holidays/{id} | Rimuove la risorsa Holiday. |
| GET | /holidays/active | Recupera la raccolta di risorse Holiday. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | integer | |
| type* | string | #4548. `Holiday` is writable directly (`holiday:create`), so it carries the same unbounded-free-text defect the request did. `max` tracks `length`. |
| employee* | string (iri-reference) | |
| manager | string (iri-reference) | |
| description | stringnull | #4548, and it is reachable two ways: written directly through `holiday:create`, and copied from the accepted request by `HolidayRequestDecider:47`. Both columns are VARCHAR(255), so bounding the request at 255 keeps that copy safe — this bounds the direct path. |
| dateFrom* | string (date-time) | |
| dateTo* | string (date-time) | |
| seconds | integernull | |
| requestedSeconds | integernull | |
| notify | boolean | Should this absence tell the employee it was created? (#4705) |
| payrollEligible | boolean | May payroll act on this absence? (#4017) |
| holidayRequests | array | |
| createdAt | string (date-time) | |
| updatedAt | string (date-time) | |
| deletedAt | string,null (date-time) | |
| employeeFullname | string | |
| employeeReversedFullname | string | |
| relatedEmployee | string,null (iri-reference) | |
| deleted | boolean | Check if the entity has been soft deleted. |
Turno
Endpoint
| GET | /schedules | Recupera la raccolta di risorse Schedule. |
| POST | /schedules | Crea una risorsa Schedule. |
| GET | /schedules/{id} | Recupera una risorsa Schedule. |
| PATCH | /schedules/{id} | Aggiorna la risorsa Schedule. |
| GET | /schedules/plan/{date} | Recupera la raccolta di risorse Schedule. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| name | string | |
| description | stringnull | |
| numberOfDays | integer | |
| regular | boolean | |
| overwriteBankHolidays | boolean | |
| scheduleRanges | array | |
| scheduleEmployees | array |
Festa Nazionale
Endpoint
| GET | /bank-holidays | Recupera la raccolta di risorse BankHoliday. |
| POST | /bank-holidays | Crea una risorsa BankHoliday. |
| GET | /bank-holidays/{id} | Recupera una risorsa BankHoliday. |
| PATCH | /bank-holidays/{id} | Aggiorna la risorsa BankHoliday. |
| DELETE | /bank-holidays/{id} | Rimuove la risorsa BankHoliday. |
| GET | /holiday-days-frees | Recupera la raccolta di risorse BankHoliday. |
| POST | /holiday-days-frees | Crea una risorsa BankHoliday. |
| GET | /holiday-days-frees/{id} | Recupera una risorsa BankHoliday. |
| PATCH | /holiday-days-frees/{id} | Aggiorna la risorsa BankHoliday. |
| DELETE | /holiday-days-frees/{id} | Rimuove la risorsa BankHoliday. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| date* | string | |
| publicNotes | stringnull | |
| yearFrom | integernull | |
| yearTo | integernull |
Richiesta di ferie
Endpoint
| GET | /holiday-requests | Recupera la raccolta di risorse HolidayRequest. |
| POST | /holiday-requests | Crea una risorsa HolidayRequest. |
| GET | /holiday-requests/{id} | Recupera una risorsa HolidayRequest. |
| PATCH | /holiday-requests/{id} | Aggiorna la risorsa HolidayRequest. |
| DELETE | /holiday-requests/{id} | Rimuove la risorsa HolidayRequest. |
| POST | /holiday-requests/{id}/approve | Crea una risorsa HolidayRequest. |
| POST | /holiday-requests/{id}/reject | Crea una risorsa HolidayRequest. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | integer | |
| status | string | |
| employee | string (iri-reference) | |
| holiday | string,null (iri-reference) | |
| type* | string | Same defect, same processor, same flush (#4548). `type` is writable in the `holiday_request:create` group and nothing bounded it, so a 65-character value produced the identical SQLSTATE[22001]. Sentry only caught `description` because that is the one a user types freely. |
| description | stringnull | THE LENGTH IS THE COLUMN WIDTH, NOT A TASTE (#4548). Without it an over-long note travelled to MySQL and came back as `SQLSTATE[22001] … Data too long for column 'description'` — a fatal 500 from `HolidayRequestCreateProcessor:118`'s flush(), losing the request and telling the user nothing (Sentry PHP-SYMFONY-T7, prod). |
| dateFrom* | string (date-time) | |
| dateTo* | string (date-time) | |
| seconds | integernull | |
| requestedSeconds | integernull | |
| holidayRequestLogs | array | |
| createdAt | string (date-time) | |
| updatedAt | string (date-time) | |
| requestedAt | datetime |
Tipo di ferie
Endpoint
| GET | /holiday-types | Recupera la raccolta di risorse HolidayType. |
| POST | /holiday-types | Crea una risorsa HolidayType. |
| GET | /holiday-types/{id} | Recupera una risorsa HolidayType. |
| PATCH | /holiday-types/{id} | Aggiorna la risorsa HolidayType. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| status | string | |
| name* | string | |
| color | string | THE API HAS TO ACCEPT ITS OWN OUTPUT (#4407). |
| descriptionRequired | boolean | |
| icon | stringnull | |
| reducesWorkingTime | boolean | Does an absence of this type reduce the month's expected working hours? |
| requiresApproval | boolean | Does an absence of this type have to be approved by somebody? (#5068) |
Limite giorni di ferie
Endpoint
| GET | /holiday-days-limits | Recupera la raccolta di risorse HolidayDaysLimit. |
| POST | /holiday-days-limits | Crea una risorsa HolidayDaysLimit. |
| GET | /holiday-days-limits/{id} | Recupera una risorsa HolidayDaysLimit. |
| PATCH | /holiday-days-limits/{id} | Aggiorna la risorsa HolidayDaysLimit. |
| DELETE | /holiday-days-limits/{id} | Rimuove la risorsa HolidayDaysLimit. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | integer | |
| employee* | string (iri-reference) | |
| seconds* | integer | Leave allowance in SECONDS, not whole days (#3763). |
| holidayType | string,null (iri-reference) | |
| variant* | string | |
| allowRequestWhenUsed | boolean | NOT SERIALISED, AND THAT IS THE FIX (#4361). Do not re-add `#[Groups]`. |
| dateFrom | string (date-time) | |
| notes | stringnull | |
| createdAt | string (date-time) | |
| updatedAt | string (date-time) | |
| notApplicableReason | stringnull | Why this entitlement will not take effect yet, or NULL if it will (#4443). |
| vacationLimit | boolean | Is this row the ANNUAL LEAVE entitlement, as opposed to a granted balance of some other type (#4165)? |
| relatedEmployee | string,null (iri-reference) |
Limite predefinito giorni di ferie
Endpoint
| GET | /holiday-days-limit-defaults | Recupera la raccolta di risorse HolidayDaysLimitDefault. |
| POST | /holiday-days-limit-defaults | Crea una risorsa HolidayDaysLimitDefault. |
| GET | /holiday-days-limit-defaults/{id} | Recupera una risorsa HolidayDaysLimitDefault. |
| PATCH | /holiday-days-limit-defaults/{id} | Aggiorna la risorsa HolidayDaysLimitDefault. |
| DELETE | /holiday-days-limit-defaults/{id} | Rimuove la risorsa HolidayDaysLimitDefault. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | string | |
| holidayType | string (iri-reference) | |
| seconds* | integer | Default leave allowance in SECONDS, not whole days (#3763). This entity moves with `HolidayDaysLimit` rather than after it: both are returned through the same line in `HolidaysHelper::getHolidayDaysLimit()`, so leaving one in days would put two units on one code path. |
| variant* | string | |
| allowRequestWhenUsed | boolean | NOT SERIALISED (#4361) — see the full reasoning on {@see HolidayDaysLimit::$allowRequestWhenUsed}. Do not re-add `#[Groups]`. |
| dateFrom | string (date-time) | |
| createdAt | string (date-time) | |
| updatedAt | string (date-time) |
Orario dipendente
Endpoint
| GET | /schedule-employees | Recupera la raccolta di risorse ScheduleEmployee. |
| POST | /schedule-employees | Crea una risorsa ScheduleEmployee. |
| GET | /schedule-employees/{id} | Recupera una risorsa ScheduleEmployee. |
| PATCH | /schedule-employees/{id} | Aggiorna la risorsa ScheduleEmployee. |
| DELETE | /schedule-employees/{id} | Rimuove la risorsa ScheduleEmployee. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| employee | string (iri-reference) | |
| schedule | string (iri-reference) | |
| dateFrom | string (date-time) | |
| dateTo | string,null (date-time) | |
| type | string | |
| notifiedAt | string,null (date-time) |
Intervallo orario
Endpoint
| GET | /schedule-ranges | Recupera la raccolta di risorse ScheduleRange. |
| POST | /schedule-ranges | Crea una risorsa ScheduleRange. |
| GET | /schedule-ranges/{id} | Recupera una risorsa ScheduleRange. |
| PATCH | /schedule-ranges/{id} | Aggiorna la risorsa ScheduleRange. |
| DELETE | /schedule-ranges/{id} | Rimuove la risorsa ScheduleRange. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | string | |
| schedule | object | |
| day | integer | |
| timeFrom | integer | |
| timeTo | integer | |
| name | stringnull |
Trasferta
Endpoint
| GET | /delegations | Recupera la raccolta di risorse Delegation. |
| POST | /delegations | Crea una risorsa Delegation. |
| GET | /delegations/{id} | Recupera una risorsa Delegation. |
| PATCH | /delegations/{id} | Aggiorna la risorsa Delegation. |
| DELETE | /delegations/{id} | Rimuove la risorsa Delegation. |
Campi schema
| Campo | Tipo | Descrizione |
|---|---|---|
| id | integer | |
| employee* | string (iri-reference) | |
| project | string,null (iri-reference) | Nullable: a historical trip may name no project, and it must still be recorded. |
| projectTask | string,null (iri-reference) | |
| dateFrom* | string (date-time) | |
| dateTo* | string (date-time) | |
| seconds | integernull | Optional: the source history carries days, not hours. |
| description | stringnull | |
| createdAt | string (date-time) | |
| updatedAt | string (date-time) | |
| deletedAt | string,null (date-time) | |
| days | integer | Calendar days covered, INCLUSIVE — a trip that starts and ends on the same day is one day, not zero. This is the unit the travel analytics report, because the source history counts days rather than hours. |
| deleted | boolean | Check if the entity has been soft deleted. |