Sync Absences

How to retrieve absences in your PayFit API?

Overview

PayFit's API allows you to fetch the complete list of absences for a company or an individual employee using the contract ID. By default, the API returns the last 10 absences, sorted by the modification date. You can customize the number of results using the appropriate query parameter.

Absence Details

The API provides all validated absences, regardless of type, for all supported countries (France, UK, Spain).

Absence Types

Below is the table listing all possible absence types, their corresponding countries, and their descriptions:

Absence TypeCountryDescription
fr_conges_payes🇫🇷Paid leave
fr_rtt🇫🇷RTT leave
fr_absence_remuneree🇫🇷Paid absence
fr_repos🇫🇷Rest day
fr_sans_solde🇫🇷Unpaid leave
fr_maladie_ordinaire🇫🇷Ordinary sickness
fr_accident_travail🇫🇷Work accident
fr_accident_trajet🇫🇷Commuting accident
fr_maladie_professionnelle🇫🇷Occupational disease
fr_temps_partiel_therapeutique🇫🇷Therapeutic part-time
fr_paternite🇫🇷Paternity leave
fr_maternite🇫🇷Maternity leave
fr_second_parent🇫🇷Second parent leave
fr_pathologique🇫🇷Pathological leave
fr_naissance🇫🇷Birth leave
fr_enfant_malade🇫🇷Child sickness leave
fr_parental_education🇫🇷Parental education leave
fr_mariage🇫🇷Marriage leave
fr_deces🇫🇷Death leave
fr_deuil🇫🇷Mourning leave
fr_mise_a_pied🇫🇷Suspension
fr_activite_partielle🇫🇷Partial activity leave
fr_autre🇫🇷Other leave
fr_ecole🇫🇷School leave
uk_annual_leave🇬🇧Annual leave
uk_maternity🇬🇧Maternity leave
uk_paternity🇬🇧Paternity leave
uk_kit🇬🇧Keeping in touch days
uk_adoption🇬🇧Adoption leave
uk_sick_leave🇬🇧Sick leave
uk_covid🇬🇧COVID-19 related leave
uk_paid_leave🇬🇧Paid leave
uk_jury_service🇬🇧Jury service leave
uk_unpaid_leave🇬🇧Unpaid leave
uk_compassionate_leave🇬🇧Compassionate leave
uk_bereavement_leave🇬🇧Bereavement leave
es_vacaciones🇪🇸Vacations
es_visita_medica🇪🇸Medical visit
es_asunto_personal🇪🇸Personal matters
es_asunto_familiar🇪🇸Family matters
es_cuidado_de_hijos🇪🇸Childcare leave
es_permisos🇪🇸Permissions
es_compensacion_dias_trabajados🇪🇸Compensation for worked days
es_baja_medica🇪🇸Medical leave
es_otros🇪🇸Other
colleague_leaveAllColleague leave
colleague_partial_leaveAllColleague partial leave
colleague_schoolAllColleague school leave
colleague_remoteAllColleague remote work
otherAllOther

Example Request

Here is an example of how to use the API to retrieve absences:

GET /companies/abcdefabcdefabcdefabcdef/absences?contractId=aaaaaaaaaaaaaaaaaaaaaaaa&maxResults=50
Authorization: Bearer {api_token}

By adjusting the maxResults parameter, you can fetch the desired number of absence records.

For more detailed information, visit the PayFit API reference.