Forum Discussion

ThomasTShaffner's avatar
ThomasTShaffner
Community Member
24 hours ago

Competency Asserted… (Custom xAPI)

Several of my customers needed to track their students' achievement of specific competencies in Storyline. So, I developed a custom xAPI statement, trigger, and variables. I started with the schema that the ADL described for tracking competency using xAPI in their TLA Profile. Here's what I did.

Prerequisites: Before you begin, you must “crosswalk” your objectives and quizzes and build a table of how they relate. Using this, you can then encode the degree of confidence that a student shows in an objective with their score in the quiz as evidence, which expresses their competence. Each Quiz slide must point to a separate Results slide that points back at it.

  1. In Storyline, open your course, and open the Results slide.
  2. In the Slide palette, in the Triggers section, click the Manage project variables button.
  3. In the Variables dialog box, click the Create a new variable button.
  4. Add ActivityName and enter the name of your course as the Default Value, add CompetencyId, and add CompetencyName.
  5. Click the OK button.
  6. Create a new trigger.
  7. In the Trigger Wizard, change the Action to More > Adjust Variable
  8. Change the Variable to CompetencyId, and enter a value, such as Objective12, the second objective of the first lesson.
  9. Click the OK button.
  10. Open the Trigger Wizard again and change the Action to More > Adjust Variable, again.
  11. Change the Variable to CompetencyName and paste a short string of the objective. A good practice is to add a prefix like "Objective 1.02 - " to help sort and filter the objects in the LRS.
  12. Click the OK button.
  13. Open the Trigger Wizard again and change the Action to More > Send xAPI Statement.
  14. In the Trigger Wizard, in the Statement, click + xAPI….
  15. In the xAPI Statement Editor, replace the JSON code with this:

{   "verb": {
        "id": "https://w3id.org/xapi/tla/verbs/asserted",
        "display": {"en-US": "asserted"}},
    "object": {
        "objectType": "Activity",
        "id": "%Project.ActivityId%/%Slide.Id%/%CompetencyId%",
        "definition": {
            "name": {"en-US": "%CompetencyName%"},
            "type": "https://w3id.org/xapi/tla/activity-types/competency"}},
    "context": {
        "contextActivities": {
            "parent": [{
                "objectType": "Activity",
                "id": "%Project.ActivityId%/%Slide.Id%",
                "definition": {
                    "name": {"en-US": "%Project.SlideTitle%"},
                    "type": "http://adlnet.gov/expapi/activities/module"}}],
            "grouping": [{
                "objectType": "Activity",
                "id": "%Project.ActivityId%",
                "definition": {
                    "name": {"en-US": "%ActivityName%"},
                    "type": "http://adlnet.gov/expapi/activities/course"}}]},
        "extensions": {
            "https://w3id.org/xapi/tla/extensions/evidence": "[QuizName]",
            "https://w3id.org/xapi/tla/extensions/confidence": %[QuizName].ScorePercent%}}}
  1. Replace each instance of [QuizName] with the name in the Quiz Settings for the Results slide. A good practice is to match the Quiz Name to the Objective ID from the crosswalk: for example, enter “Quiz12” to match “Objective12”.
  2. In the xAPI Statement Editor, click the OK button.
  3. In the Trigger Wizard, click the OK button.

Because this information reflects the performance of students, be careful with it.

No RepliesBe the first to reply