You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What should happen when an Adapt course is launched from an LMS.
(With the adapt-contrib-xapi extension enabled and _specification set to "cmi5")
4.1 Read the URL params
The LMS should launch the adapt course with the following query params:
fetch : Used to get the authentication token. This token will be used in the header of all requests to the LRS
endpoint : The URL for the LRS. Used to send/read statements and state
actor : The learner that launched the course from the LMS. This actor will be used for all xAPI statements
registration : A registration ID corresponding to the learner's enrollment for the AU being launched. To be used in xAPI statements that require registration. Also used for requests to read/write state saved in the LRS.
activityId : A unique ID generated by the LMS (should not match the AUs publisher ID defined in the course structure). Must be used as the ID property of the object in all "cmi5 defined" xAPI statements.
Make a GET request to ${theLRSendpoint}activties/state with query string params ?stateId=LMS.LaunchData (other params needed too, see xapiWrapper.getState(activityid, agent, stateid, registration, since, callback))
The AU MUST get the contextTemplate value from the LMS.LaunchData State document. The AU MUST NOT modify or delete the LMS.LaunchData State document. The AU MUST use the contextTemplate as a template for the context property in all xAPI statements it sends to the LMS. While the AU MAY include additional values in the context object of such statements, it MUST NOT overwrite any values provided in the contextTemplate. NOTE: this will include the session ID specified by the LMS.
If a masteryScore is used, the "passed" or "failed" cmi5 defined statements MUST be based on the masteryScore provided
If the returnURL is provided in the LMS.LaunchData, the AU MUST attempt to get the returnURL value from the LMS.LaunchData state document. The AU MUST redirect the current browser window or frame to the returnURL when the AU is terminated if the returnURL is provided.
5.0 Properties schema update
5.1 Config
"cmi5" option to be added to _specification
help text to be updated, remove the "(coming soon)"
"_specification": {
"type": "string",
"enum": [
"xAPI"
],
"default": "xAPI",
"title": "Specification",
"inputType": {
"type": "Select",
"options": [
"xAPI",
"cmi5"
]
},
"validators": [],
"help": "Indicates whether the plugin should use standard xAPI or cmi5 profile."
},
"validators": [],
"help": "(cmi5 only) Some useful help text."},
Subject of the issue/enhancement/features
Add support for the cmi5 specification.
1.0 Overview
cmi5 Implementation Flow for an AU (Assignable Unit)
(Figure from https://aicc.github.io/CMI-5_Spec_Current/flows/au-flow.html)
2.0 Requirements
To support cmi5, the extension should enable an Adapt course to:
MUST
requirements outlined in the official specification docs for an AUhttps://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#70-au-requirements
3.0 Acronyms
4.0 Runtime Flow
What should happen when an Adapt course is launched from an LMS.
(With the adapt-contrib-xapi extension enabled and
_specification
set to"cmi5"
)4.1 Read the URL params
The LMS should launch the adapt course with the following query params:
fetch
: Used to get the authentication token. This token will be used in the header of all requests to the LRSendpoint
: The URL for the LRS. Used to send/read statements and stateactor
: The learner that launched the course from the LMS. This actor will be used for all xAPI statementsregistration
: A registration ID corresponding to the learner's enrollment for the AU being launched. To be used in xAPI statements that requireregistration
. Also used for requests to read/write state saved in the LRS.activityId
: A unique ID generated by the LMS (should not match the AUs publisher ID defined in the course structure). Must be used as the ID property of the object in all "cmi5 defined" xAPI statements.❓ How should we save these values? Set as model attributes on https://github.com/adaptlearning/adapt-contrib-xapi/blob/master/js/XAPI.js
4.2 Get the Auth Token
Before trying to communicate with the LRS, we need to used the
fetch
value provided by the LMS to get an authentication token.fetch
property.This POST request must only happen once.
The response should contain a JSON object with an
auth-token
property e.g.This
auth-token
should then be used in all requests made to the LRS.4.3 Set the xapiWrapper config
This plugin uses the xAPIWrapper.js library.
https://github.com/adlnet/xAPIWrapper
When loaded, the xAPIWrapper will check for some query params.
endpoint
and use it for thexapiWrapper.lrs.endpoint
valueactor
and use it for thexapiWrapper.lrs.actor
valueregistration
and use it for thexapiWrapper.lrs.registration
valueWe need to do a little extra to handle our
auth-token
andactivityId
e.g.4.4 Read State Document
When launched the LMS will write a state document with details needed for the AU to send valid xAPI statements during it's session.
https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#xapi_state
${theLRSendpoint}activties/state
with query string params?stateId=LMS.LaunchData
(other params needed too, seexapiWrapper.getState(activityid, agent, stateid, registration, since, callback)
)Example of
LMS.LaunchData
:https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#1021-contexttemplate
masteryScore
is used, the "passed" or "failed" cmi5 defined statements MUST be based on themasteryScore
providedlaunchParameters
exist, the AU should attempt to get them https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#launchparameters4.5 Read Agent Profile
https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#110-xapi-agent-profile-data-model
4.6 Order of xAPI Statements
4.7 Return to URL
https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#1026-returnurl
returnURL
is provided in the LMS.LaunchData, the AU MUST attempt to get the returnURL value from the LMS.LaunchData state document. The AU MUST redirect the current browser window or frame to the returnURL when the AU is terminated if the returnURL is provided.5.0 Properties schema update
5.1 Config
_specification
https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#moveon
https://github.com/AICC/CMI-5_Spec_Current/blob/quartz/cmi5_spec.md#9622-moveon-category-activity
6.0 Post Build actions
6.1 cmi5.xml - The Course Structure
7.0 Resources
x.x TODO: make notes about...
_defaultLanguage
from config be used to set<langstring lang="en-US">
in cmi5.xml?The text was updated successfully, but these errors were encountered: