AssessmentAttempts
Returns a paginated list of assessment attempts across your platform, optionally filtered by date range, course, or user
Returns a paginated list of assessment attempts across your platform, optionally filtered by date range, course, or user.
GET
https://example.thoughtindustries.com/incoming/v2/assessmentAttemptsExample request
curl "https://example.thoughtindustries.com/incoming/v2/assessmentAttempts" \
-H 'Authorization: Bearer YOUR_API_KEY'Parameters
| Name | Type | Required | Location | Description |
|---|---|---|---|---|
cursor | string | No | query | Opaque pagination cursor returned by a previous response; use to fetch the next page of results. |
startDate | epoch milliseconds | No | query | Filters results to attempts created at or after this Unix timestamp, in milliseconds. |
endDate | epoch milliseconds | No | query | Filters results to attempts created at or before this Unix timestamp, in milliseconds. |
courseId | uuid | No | query | Filters results to attempts belonging to the specified course. |
userId | uuid | No | query | Filters results to attempts belonging to the specified user. |
perPage | integer | No | query | Number of assessment attempts to return per page. |
Example response
{
"pageInfo": {
"hasMore": true,
"cursor": "string",
"perPage": 0
},
"assessmentAttempts": [
{
"id": "00000000-0000-0000-0000-000000000000",
"courseId": "00000000-0000-0000-0000-000000000000",
"course": {
"id": "00000000-0000-0000-0000-000000000000",
"title": "string"
},
"createdAt": "2024-01-01T00:00:00.000Z",
"updatedAt": "2024-01-01T00:00:00.000Z",
"grade": 0,
"passed": true,
"answers": [
{
"id": "00000000-0000-0000-0000-000000000000",
"question": "string",
"answer": "string",
"correct": true
}
],
"status": "string",
"timeElapsedInSeconds": 0,
"assessment": {
"id": "00000000-0000-0000-0000-000000000000",
"type": "string",
"title": "string"
},
"user": {
"id": "00000000-0000-0000-0000-000000000000",
"email": "string",
"firstName": "string",
"lastName": "string",
"clientId": "00000000-0000-0000-0000-000000000000",
"ref1": "string",
"ref2": "string",
"ref3": "string",
"ref4": "string",
"ref5": "string",
"ref6": "string",
"ref7": "string",
"ref8": "string",
"ref9": "string",
"ref10": "string"
}
}
]
}Response fields
| Field | Type | Description |
|---|---|---|
pageInfo | CursorPageInfo | Pagination metadata for the current result set. |
pageInfo.hasMore | boolean | Indicates whether additional pages of results are available. |
pageInfo.cursor | string | Opaque cursor to pass in the next request to retrieve the following page. |
pageInfo.perPage | integer | Number of items returned per page. |
assessmentAttempts | AssessmentAttempt[] | Array of assessment attempts matching the query. |
assessmentAttempts.id | uuid | Unique identifier of the assessment attempt. |
assessmentAttempts.courseId | uuid | Identifier of the course the assessment belongs to. |
assessmentAttempts.course | Course | Course the assessment attempt belongs to. |
assessmentAttempts.course.id | uuid | Unique identifier of the course. |
assessmentAttempts.course.title | string | Title of the course. |
assessmentAttempts.createdAt | ISO 8601 timestamp | Date and time the attempt was created. |
assessmentAttempts.updatedAt | ISO 8601 timestamp | Date and time the attempt was last modified. |
assessmentAttempts.grade | integer | Grade recorded for the attempt. |
assessmentAttempts.passed | boolean | Indicates whether the attempt passed. |
assessmentAttempts.answers | AssessmentAnswer[] | Array of answers submitted for the attempt. |
assessmentAttempts.answers.id | uuid | Unique identifier of the answer. |
assessmentAttempts.answers.question | string | The question text. |
assessmentAttempts.answers.answer | string | The submitted answer. |
assessmentAttempts.answers.correct | boolean | Indicates whether the answer was graded correct. |
assessmentAttempts.status | string | Current status of the assessment attempt. |
assessmentAttempts.timeElapsedInSeconds | integer | Time spent on the attempt, in seconds. |
assessmentAttempts.assessment | Assessment | Assessment the attempt belongs to. |
assessmentAttempts.assessment.id | uuid | Unique identifier of the assessment. |
assessmentAttempts.assessment.type | string | Type of the assessment. |
assessmentAttempts.assessment.title | string | Title of the assessment. |
assessmentAttempts.user | User | User who made the attempt. |
assessmentAttempts.user.id | uuid | Unique identifier of the user. |
assessmentAttempts.user.email | string | Email address of the user. |
assessmentAttempts.user.firstName | string | First name of the user. |
assessmentAttempts.user.lastName | string | Last name of the user. |
assessmentAttempts.user.clientId | uuid | Identifier of the client the user belongs to. |
assessmentAttempts.user.ref1 | string | Custom reference field 1 associated with the user. |
assessmentAttempts.user.ref2 | string | Custom reference field 2 associated with the user. |
assessmentAttempts.user.ref3 | string | Custom reference field 3 associated with the user. |
assessmentAttempts.user.ref4 | string | Custom reference field 4 associated with the user. |
assessmentAttempts.user.ref5 | string | Custom reference field 5 associated with the user. |
assessmentAttempts.user.ref6 | string | Custom reference field 6 associated with the user. |
assessmentAttempts.user.ref7 | string | Custom reference field 7 associated with the user. |
assessmentAttempts.user.ref8 | string | Custom reference field 8 associated with the user. |
assessmentAttempts.user.ref9 | string | Custom reference field 9 associated with the user. |
assessmentAttempts.user.ref10 | string | Custom reference field 10 associated with the user. |