Account Owner, Account Administrators, Department Administrators, or custom roles.
Department Administrators and users with a custom role can get list of enrollments assigned to learners belonging to the departments they manage and their sub-departments.
You can get a list of enrollments of the entire account, certain learners, courses, or last two parameters together. |
Request Headers
Header | Description |
|---|---|
| Authorization (required) | Access token. You can obtain a token by making a request |
| Parameter | Description |
| learnerIds (optional) | The IDs of the users whose enrollments you would like to get |
| courseIds (optional) | The IDs of the courses which enrollments you would like to get |
| Parameter | Description |
|---|---|
response | An array with enrollment data |
| enrollmentId | The ID of the enrollment |
| courseId | The ID of the course |
| learnerId | The ID of the user enrolled in the course |
| accessDate | The date the learner is supposed to start studying the course |
| dueDate (optional) | Course completion date. This parameter appears in the response if a due date is specified |
| expirationDate (optional) | Course completion date. This parameter appears in the response if a due date is specified and shouldLockAfterDueDate is equal to 1 |
| shouldLockAfterDueDate | Possible values: 0 means that access is granted 1 means that access is denied |
| сertificate | Certificate info |
| issuedCertificateId | The certificate ID (token) from the list of enrollments |
| issueDate | The date the certificate was issued |
| expiryDate | The certificate’s expiration date |
| enrollmentTypeGroup | Possible values: 0 — assigned by an administrator 1 — added from the catalog |
The date of issue and expiration of the certificate can only be received for active enrollments. When using this method, you cannot get the data for archived or deleted enrollments. |
Code | Text | Description |
|---|---|---|
| 200 | OK | The request has been successfully processed. The response body will contain data with the enrollments |
| 400 | Bad Request | A request error |
| 401 | Unauthorized | An authorization error |
| 403 | Permission Denied | The user doesn't have enough permissions to get a list of enrollments |
GET /enrollment?courseIds[]=146ac240-d54f-11e9-9b88-0a580af40973&learnerIds[]=00de7a40-deb5-11e9-8afe-0a580af40764 https/1.1 Host: api-learn.ispringlearn.com Authorization: p-1sJDjmULL5DdpXPJTcbm4jVIaWVHvNmrjAxATRbNE |
GET /enrollment?courseIds=146ac240-d54f-11e9-9b88-0a580af40973,a2239d7c-0a37-11ec-b63a 0242ac140033&learnerIds[]=a59c152e-1603-11ec-872d-0242ac160034 https/1.1 Host: api-learn.ispringlearn.com Authorization: p-1sJDjmULL5DdpXPJTcbm4jVIaWVHvNmrjAxATRbNE |
https/1.1 200 OK
<?xml version="1.0" encoding="UTF-8"?>
<response>
<enrollment>
<enrollmentId>fc1fc35c-040d-11ed-a2ba-b6f58d6fa7b5</enrollmentId>
<courseId>1cf62af4-02c3-11ed-8874-3ebfbdfaeb70</courseId>
<learnerId>d9261766-040d-11ed-ae50-da994e0c8f89</learnerId>
<accessDate>2022-07-14</accessDate>
<enrollmentTypeGroup>0</enrollmentTypeGroup>
<shouldLockAfterDueDate>0</shouldLockAfterDueDate>
<certificate>
<issuedCertificateId>66b4ed00-040e-11ed-a8a2-b6f58d6fa7b5</issuedCertificateId>
<issueDate>2022-07-15T07:19:00+00:00</issueDate>
<expiryDate>2022-07-15T07:21:00+00:00</expiryDate>
</certificate>
</enrollment>
</response> |