Get the enrolments created for an upload, in the form of employee records.
Query parameters
-
The maximum number of records to return per page.
Minimum value is
100, maximum value is500. Default value is200. -
The page number to return in the list of records.
Minimum value is
1. Default value is1.
GET
/uploads/{upload_id}/enrolments
curl \
--request GET 'https://payroll-api.getpenfold.dev/v4/uploads/{upload_id}/enrolments' \
--header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
"page_number": 1,
"page_size": 200,
"total_items": 1,
"items": [
{
"id": "e1234-abcd-5678-efgh",
"upload_id": "string",
"employer_id": "r9876-wxyz-4321-stuv",
"email": "john.doe@example.com",
"created_at": "2023-03-01T12:00:00Z",
"updated_at": "2023-03-15T12:00:00Z",
"forename": "John",
"surname": "Doe",
"title": "Mr.",
"date_of_birth": "1990-01-01",
"address_line1": "123 Main Street",
"postcode": "AB12 3CD",
"national_insurance_number": "AA123456C",
"employment_start_date": "2023-01-01",
"exit_date": "2023-12-31",
"opt_out_date": "2026-05-04",
"opt_in_date": "2026-05-04",
"opt_out_window_start_date": "2023-01-01",
"opt_out_window_end_date": "2023-01-31"
}
]
}
Response examples (400)
{
"error": "Bad request: invalid data provided."
}
Response examples (401)
{
"error": "Bad request: invalid data provided."
}
Response examples (404)
{
"error": "Bad request: invalid data provided."
}