> ## Documentation Index
> Fetch the complete documentation index at: https://solidroad.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# List an assignment's enrollments

> GET /v2/assignments/{id}/enrollments lists the learners in one assignment and where each one stands.

```
GET https://api.solidroad.com/v2/assignments/{id}/enrollments
```

Scope: `assignments:read`.

An enrollment is one learner in one assignment. Its status, score and progress are the same values that the assignment's page shows in the Solidroad app. The list sorts on `updatedAt`, newest first. Send `order=asc` for oldest first.

To read the enrollments in every assignment on one list, use [List enrollments](https://solidroad.mintlify.site/api-reference/v2/endpoint/enrollments/list.md).

## Path parameters

| Parameter | Type | Meaning |
| - | - | - |
| `id` | string | The assignment ID: `asg_` and a UUID. |

## Query parameters

| Parameter | Type | Default | Meaning |
| - | - | - | - |
| `limit` | integer | `50` | 1 to 100 records on a page. |
| `cursor` | string | none | `nextCursor` from the previous page. |
| `order` | string | `desc` | `asc` or `desc` on `updatedAt`. |
| `filter` | string | none | A CEL expression over the fields below. |

Read [Lists](https://solidroad.mintlify.site/api-reference/v2/lists.md) for how the parameters work, and [Filtering](https://solidroad.mintlify.site/api-reference/v2/filtering.md) for the filter syntax.

## Filter fields

| Field | Kind | Can be empty | Values |
| - | - | - | - |
| `learnerId` | ID | No | A person ID, `ppl_…` |
| `status` | Enum | No | `not_started`, `in_progress`, `retry_required`, `passed`, `failed`, `completed` |
| `groupId` | ID | No | A group ID, `grp_…` |
| `enrolledAt` | Time | No | `timestamp("…")` |
| `completedAt` | Time | Yes | `timestamp("…")` or `null` |
| `updatedAt` | Time | No | `timestamp("…")` |

These are the only fields that you can filter on. Read [Filtering](https://solidroad.mintlify.site/api-reference/v2/filtering.md) for the syntax and the operators that each kind takes.

A filter on `completedAt` reads the value in the [enrollment object](#enrollment-object). That value can be empty for a learner who completed some time ago, and it can follow `status` by a few minutes. Read [Times](#times). So `completedAt == null` can match a learner who has finished.

A filter on `status` reads the [status](#status) in the enrollment object, as it is when you send the request. For example, `status == "not_started"` lists every learner who has not started the assignment.

A filter on `groupId` reads the learner's group membership, as it is when you send the request:

* `groupId == "grp_…"` matches a learner who is a direct member of the group. It does not match a member of a subgroup. To include a subgroup, add its ID with `in`.
* `groupId in ["grp_…", "grp_…"]` matches a learner who is a direct member of one or more of the groups.
* `groupId != "grp_…"` matches a learner who is not a direct member of the group. This includes a learner who is in no group.

A group ID that is not in your workspace matches no learner. Read the group IDs from [List groups](https://solidroad.mintlify.site/api-reference/v2/endpoint/groups/list.md).

You can filter on `status` and `groupId` on this list only. [List enrollments](https://solidroad.mintlify.site/api-reference/v2/endpoint/enrollments/list.md) does not take them.

To read the attempts behind an enrollment, filter [List attempts](https://solidroad.mintlify.site/api-reference/v2/endpoint/attempts/list.md) on `enrollmentId`.

## Request

```bash theme={null}
curl --get https://api.solidroad.com/v2/assignments/asg_00000000-0000-4000-8000-000000000001/enrollments \
  -H "Authorization: Bearer $SOLIDROAD_API_KEY" \
  --data-urlencode 'filter=updatedAt > timestamp("2026-10-01T00:00:00Z")' \
  --data-urlencode "order=asc" \
  --data-urlencode "limit=100"
```

To get one learner's enrollment, filter on `learnerId`:

```bash theme={null}
curl --get https://api.solidroad.com/v2/assignments/asg_00000000-0000-4000-8000-000000000001/enrollments \
  -H "Authorization: Bearer $SOLIDROAD_API_KEY" \
  --data-urlencode 'filter=learnerId == "ppl_00000000-0000-4000-8000-000000000001"'
```

To list the learners in one group who have not started the assignment, filter on `status` and `groupId`:

```bash theme={null}
curl --get https://api.solidroad.com/v2/assignments/asg_00000000-0000-4000-8000-000000000001/enrollments \
  -H "Authorization: Bearer $SOLIDROAD_API_KEY" \
  --data-urlencode 'filter=status == "not_started" && groupId == "grp_00000000-0000-4000-8000-000000000001"' \
  --data-urlencode "limit=100"
```

Each row has a `learnerId`. To get the learner's name and email, read [Get a person](https://solidroad.mintlify.site/api-reference/v2/endpoint/people/get.md) with that ID.

## Response

```json theme={null}
{
  "data": [
    {
      "id": "enr_00000000-0000-4000-8000-000000000001",
      "object": "enrollment",
      "assignmentId": "asg_00000000-0000-4000-8000-000000000001",
      "learnerId": "ppl_00000000-0000-4000-8000-000000000001",
      "status": "passed",
      "averageScore": 86,
      "submittedItems": 2,
      "totalItems": 2,
      "enrolledAt": "2026-10-02T08:00:00.000Z",
      "completedAt": "2026-10-21T15:28:44.120Z",
      "createdAt": "2026-10-02T08:00:00.000Z",
      "updatedAt": "2026-10-21T15:32:10.044Z",
      "appUrl": "https://app.solidroad.com/dashboard/assignments/asg_00000000-0000-4000-8000-000000000001/records/enr_00000000-0000-4000-8000-000000000001"
    },
    {
      "id": "enr_00000000-0000-4000-8000-000000000002",
      "object": "enrollment",
      "assignmentId": "asg_00000000-0000-4000-8000-000000000001",
      "learnerId": "ppl_00000000-0000-4000-8000-000000000002",
      "status": "in_progress",
      "submittedItems": 1,
      "totalItems": 2,
      "enrolledAt": "2026-10-02T08:00:00.000Z",
      "createdAt": "2026-10-02T08:00:00.000Z",
      "updatedAt": "2026-10-29T16:40:12.004Z",
      "appUrl": "https://app.solidroad.com/dashboard/assignments/asg_00000000-0000-4000-8000-000000000001/records/enr_00000000-0000-4000-8000-000000000002"
    }
  ],
  "hasMore": false
}
```

## Enrollment object

| Field | Type | When present | Meaning |
| - | - | - | - |
| `id` | string | Always | The enrollment ID, `enr_…`. |
| `object` | string | Always | Always `enrollment`. |
| `assignmentId` | string | Always | The assignment ID, `asg_…`. |
| `learnerId` | string | When recorded | The learner's person ID, `ppl_…`. It stays after the learner leaves your workspace. It can be left out for a learner who left a long time ago. Read [Learner](#learner). |
| `status` | string | Always | Where the learner stands. Read the table below. |
| `averageScore` | integer | When scored | The learner's score for the assignment, as the app shows it. |
| `submittedItems` | integer | Always | The number of items that the learner has submitted. |
| `totalItems` | integer | Always | The number of items in the assignment. |
| `enrolledAt` | time | Always | When the learner was enrolled. |
| `completedAt` | time | When complete | When the learner reached their current `passed` or `completed` status. Read [Times](#times). |
| `createdAt` | time | Always | The same value as `enrolledAt`. |
| `updatedAt` | time | Always | When the learner's progress last changed. |
| `appUrl` | string | Always | Opens the learner's page in the assignment in the Solidroad app. |

### Status

| Value | Meaning |
| - | - |
| `not_started` | The learner has not started the assignment. |
| `in_progress` | The learner has started but has not finished. This includes a learner who has finished and is waiting for a score. |
| `retry_required` | The assignment requires more than one attempt (`requiresRetry` is `true`). The learner reached the passing score but must make another attempt. |
| `passed` | The learner finished and reached the passing score. Only on an assignment with a passing score. |
| `failed` | The learner finished and did not reach the passing score. Only on an assignment with a passing score. |
| `completed` | The learner finished. Only on an assignment with no passing score, where there is nothing to pass or fail. |

An assignment has a passing score when its `passingScore` is more than 0. Handle status values that you do not know: we can add values in version 2.

### Learner

`learnerId` is a person ID that you can read with [Get a person](https://solidroad.mintlify.site/api-reference/v2/endpoint/people/get.md). If the learner left your workspace, that endpoint returns `404`, so keep the details you already hold.

### Score

`averageScore` is left out until every scored simulation in the assignment has a score for the learner. A learner with status `completed` can have an `averageScore`.

### Items

An item is a simulation in the assignment, or a required system simulation. `submittedItems` counts the simulations that the learner has attempted and the required system simulations that they have completed. When `submittedItems` equals `totalItems`, the learner has submitted everything. The status tells you whether that passed.

### Times

`updatedAt` is when the status, score or submitted items last changed. It is not the time when Solidroad last wrote the record. Use it for an [incremental sync](https://solidroad.mintlify.site/api-reference/v2/syncing.md).

`completedAt` is when the learner reached their current `passed` or `completed` status. It is accurate to within a few minutes. A learner with status `failed` has no `completedAt`.

Another attempt does not change `completedAt` while the learner stays complete. If the learner stops being complete, for example after a score correction or a change to the assignment, the field is left out. It comes back with a new time when they complete again.

`completedAt` can be left out for a learner who completed some time ago, and for a few minutes after the status changes. `updatedAt` moves when it arrives, so an [incremental sync](https://solidroad.mintlify.site/api-reference/v2/syncing.md) picks it up.

## Errors

| Status | `code` | Cause |
| - | - | - |
| 400 | `invalid_request` | A parameter, the filter or the cursor is not valid. |
| 401 | `unauthorized` | The API key is missing or not valid. |
| 403 | `insufficient_scope` | The key does not have `assignments:read`. |
| 404 | `not_found` | No assignment with this ID is in your workspace. |
| 429 | `rate_limited` | You sent too many requests. |

Read [Errors](https://solidroad.mintlify.site/api-reference/v2/errors.md) for every code.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.