Get the ID of user's active enrollments via API

This article describes how you can get the ID of a user's active enrollments in LMS365 (Learn365) with the help of an LMS365 (Learn365) API endpoint.

To get the ID of the user's active enrollments, follow these steps:

To be able to use the LMS365 (Learn365) API, you should be authorized with the relevant API key on https:/ For details, see this article.

1.  In https:/, navigate to the Enrollments section.

2. Select the GET/odata/v2/Enrollments endpoint (that returns the list of current user's active enrollments) and select Try it out.


3. The opened Parameters section includes the query parameter fields that can be completed if you want to narrow down the response data. 

  • If you want to retrieve data on all users' active enrollments on the tenant, leave the fields empty and proceed to the next step.
  • If you want to narrow down the response data, specify query parameters in the query fields. The returned response data will contain only the filtered data.


To retrieve active enrollments in a specific course:

  • In the $filter field, enter CourseId eq ID, where ID is the ID of the relevant course. For more information about how to get the course ID, see this article. In this case, the response will contain active enrollments of all learners only for this course.
  • If you would like to get the active enrollment ID of a specific learner in this course, get the user ID and use it to further filter the returned data in the Response block. 


3. Select Execute to run the request. 

4. Go to the Responses block to check the results. 

  • Number 2xx (for example, 200) under Code shows that the request worked correctly.
  • If no query parameters were set in the Parameters block to narrow down the response, you can see data on all active enrollments of all users on the tenant, including the enrollment ID.
  • The value next to the Id parameter shows the unique enrollment ID for each user in each course.
  • If query parameters were set in the Parameters block, you'll see only the relevant requested data.
  • To narrow down the response, use Ctrl+F and the searched data.
  • You can use the Download option to save the results in the. JSON format to your device.


Was this article helpful?
0 out of 0 found this helpful


Article is closed for comments.