List all enrollments: Migration guide
This guide outlines the changes introduced in the List all enrollments v2 endpoint (previously known as getGroups in v1).
Key changesPagination: The v2 endpoint is paginated and returns 5000 enrollments per page.
Documentation links
Here are the links to the API reference for:
Endpoint mapping
Here's the direct correlation between the v1 and v2 endpoint URLs:
- API v1:
/api/v1/paths/:path_id/users - API v2:
/api/v2/paths/{pathId}/enrollments
Input changes
This section details the specific alterations to the input requirements between API versions.
API v1 input example
curl --location -g 'https://{{host}}/api/v1/paths/567b608a1a92bb4fb526b31a/users?company={{company}}&apiKey={{apiKey}}'API v2 input example
curl --request GET \
--url https://app.360learning.com/api/v2/paths/507f1f77bcf86cd799439011/enrollments \
--header '360-api-version: v2.0' \
--header 'accept: application/json'Main input differences
Change type | API v1 | API v2 |
|---|---|---|
Modified |
|
|
Added |
| |
Added |
|
Output changes
This section details the specific alterations to the successful output returned between API versions.
API v1 output example
[
{
"_id": "5bead809990d886aa3c5146d",
"mail": "[email protected]",
"firstName": "Jean",
"lastName": "Martin1"
},
{
"_id": "5bead8aa990d8862f3c5146f",
"mail": "[email protected]",
"firstName": "Jean",
"lastName": "Martin2"
}
]API v2 output example
[
{
"_id": "507f1f77bcf86cd799439011",
"createdAt": "2025-07-01T08:17:42.042Z",
"isSelfEnrolled": true,
"sessionId": "507f1f77bcf86cd799439011",
"userId": "507f1f77bcf86cd799439011"
}
]Main output differences
API v2 introduces pagination for the List all enrollments endpoint. Instead of returning all enrollments in a single response, it now returns a maximum of 5000 enrollments per page. To retrieve subsequent pages, you need to follow the URL provided in the Link header of the response.
Change type | API v1 | API v2 |
|---|---|---|
Removed |
| Use the response property |
Removed |
| Use the response property |
Removed |
| Use the response property |
Added |
| |
Added |
| |
Added |
| |
Modified |
|
|
Modified |
|
|
Added |
|
Updated 7 days ago
