The work schedule a team works on one calendar day (ploegenschema). An employee's schedule for a day is their ShiftDeviation of that day if there is one, else their team's shift.

Label in Fledge: Ploegenschema

URLhttps://odata-api.fledge.nl/v2-8/Shifts
Keyadministration_idday_numberteam_idyear
AdministrationRows belong to one administration: always filter on administration_id.
OperationsGET listGET onePOSTPATCHDELETE
Read licensesBASISBASISAPP
Write licensesPRODUCTIEFINANCIEELBEHEER
ScopesFLEDGE_PORTAL

Example requests

A page of rows, with only the fields you need. See Authentication for the token.

curl -G "https://odata-api.fledge.nl/v2-8/Shifts" \
  --data-urlencode '$filter=administration_id eq 1' \
  --data-urlencode '$select=day_number,team_id,year,date,employee_schedule_header_id' \
  --data-urlencode '$top=50' \
  -H "Authorization: Bearer $TOKEN"
const url = new URL('https://odata-api.fledge.nl/v2-8/Shifts');
url.searchParams.set('$filter', 'administration_id eq 1');
url.searchParams.set('$select', 'day_number,team_id,year,date,employee_schedule_header_id');
url.searchParams.set('$top', '50');

const response = await fetch(url, { headers: { Authorization: `Bearer ${token}` } });
const { value } = await response.json();
var url = "https://odata-api.fledge.nl/v2-8/Shifts" + "?" + string.Join("&",
    "$filter=" + Uri.EscapeDataString("administration_id eq 1"),
    "$select=" + Uri.EscapeDataString("day_number,team_id,year,date,employee_schedule_header_id"),
    "$top=" + Uri.EscapeDataString("50"));

http.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token);
var json = await http.GetStringAsync(url);

One row by its key:

GET https://odata-api.fledge.nl/v2-8/Shifts(administration_id=1,day_number={day_number},team_id={team_id},year={year})

Fields

FieldTypeDescription
administration_idkeyInt32Administratienummer
team_idkeyInt32Ploegnummer
day_numberkeyInt32Dagnummer binnen jaar.

The day of the year, counted from 0 (1 January); date is 1 January of year plus day_number days.

yearkeyInt32Jaar (niet boekjaar)

The calendar year, not the financial year.

dateDateKalenderdatum

The calendar date.

employee_schedule_header_idInt32Schemanummer

The work schedule of that day (EmployeeScheduleHeaders); empty means none.

Relations

Read a related row or list in the same request with $expand, and give it its own $select; a list also needs a $top.

NavigationEntity set
AdministrationAdministrationsone
EmployeeScheduleHeadersEmployeeScheduleHeadersone
TeamTeamsone
Wingman