GET /api/v1/paths/sessions/{sessionId}/stats/users
Return users statistics for the specified path session.
Fields
-
sessionId
: Identifier for the session -
sessionName
: the name of the session -
pathName
: name of the path -
pathId
: id of the path -
userStats
: Array of statistics for each user in the session, with the following fields:-
_id
: Identifier for the user. -
deleted
:true
if the user is deleted;false
otherwise. -
firstName
: First name of the user. -
lastName
: Last name of the user. -
mail
: Email of the user. -
totalTimeSpentInSeconds
: Number of seconds spent by the user on the path session. -
progress
: Percentage (in integer) of the user’s completion rate on the path session.0
if the user hasn’t started it yet. -
score
Percentage (in integer) of the user’s score on the path session.null
if the user hasn’t completed it yet. -
completedAt
: Date when the user has completed the path session.null
if the user hasn’t completed it yet. Expressed in ISO 8601 format — example: 2022-05-16T22:00:00.000Z. [ISO 8601]. -
detailedStatus
: Detailed status of the user, with the following fields:type
: Possible values are:awaitingCorrection
: The user reached an assessment step that the assessor hasn't validated yet.late
: The user started the path, but they are late on relative steps due dates for at least one mandatory step.notYetStarted
: The user is enrolled in an ongoing path session but they haven't started the path yet.onTime
: The user started the path, they haven't completed all the mandatory steps, and they haven't reached a blocking point.sessionNotOpened
: The user is enrolled in a path session that hasn't started yet.successful
: The user completed all the mandatory steps and fulfilled all the required conditions (time limit, minimum score, and/or mandatory replay).toRetake
: The user completed all the mandatory steps without fulfilling all the required conditions (time limit, minimum score, and/or mandatory replay), but they still haven't reached the maximum amount of authorized attempts (if any).unsuccessful
: The user had the statusnotYetStarted
,onTime
,late
, ortoRetake
when the path session ended; or the user completed the path without fulfilling all the required conditions (time limit, minimum score, or mandatory replay), and they reached the maximum amount of authorized attempts.
reason
(optional): Only the following values are included in specific cases:sessionEnded
whentype
isunsuccessful
because the session ended when the user status was eithernotYetStarted
,onTime
,late
, ortoRetake
mandatoryReplay
whentype
istoRetake
because the user completed some mandatory steps outside the path with mandatory replay.
archivedAt
: date and time (in ISO 8601 format) when the user was unenrolled from the path session. This field is not shown if the user is still enrolled. The other fields keep the value they had at the time the user was last enrolled.
-
-
certificate
:true
if the user received a certificate for that path session;false
otherwise. -
status
: Status of the user. Possible values:completed
: all mandatory steps have been completed.onTime
: all steps with a due date that is passed have been completed, or are optional.late
: at least one non-optional step with a due date that is passed has not been completed.successful
: all steps have been completed.unsuccessful
: the minimum score of a step has not been reached.
-
customFields
: Array of custom fields for the user, with the following three fields:customFieldId
: Identifier for the custom field.value
: value of the custom field.
Parameters (optional)
You can add the following optional parameters to the query:
completedAfter
: return statistics for users who completed the path session that at or after the specified date. Expressed in ISO 8601 format — example: 2022-05-16T22:00:00.000Z.completedBefore
: return statistics for users who completed the path session that at or before the specified date. Expressed in ISO 8601 format — example: 2022-05-16T22:00:00.000Z.
If both completedBefore
and completedAfter
are added to the query, the statistics for users who completed the session between the dates provided as values for the completedAfter
and completedBefore
parameters are returned.
Error messages
Status code | Error body | Reason |
---|---|---|
400 | { "error": "inconsistent_dates" } | Dates added as parameter values for completedAfter or completedBefore are not consistent, for example, completedAtBefore=2022-10-04T22:00:00.000Z&completedAtAfter=2022-10-14T22:00:00.000Z |
404 | { "error": "path_session_not_found" } | The path session ID is incorrect (the session doesn’t exist, or exists in another platform). |
Servers
- https://app.360learning.com
Path parameters
Name | Type | Required | Description |
---|---|---|---|
sessionId |
String | Yes |
ID of the path session. |
Query parameters
Name | Type | Required | Description |
---|---|---|---|
company |
String | No |
(Optional) Include the company ID to authenticate calls via the API key as query parameter. For more information on the authentication methods supported by our API, see Authentication Methods. |
apiKey |
String | No |
(Optional) Include the API key to authenticate calls via the API key as query parameter. For more information on the authentication methods supported by our API, see Authentication Methods. |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.