Creating a xAPI statement so it records a VAR value in a LRS?
Sep 23, 2018
I'm trying to figure out how create a xAPI SEND statement using javascript so I can record custom assessment values in an LRS.
I've looked at the multitude of discussions and links available (primarily Melissa Milloway's brilliant posts and videos here: https://www.linkedin.com/pulse/send-xapi-statements-from-storyline-5-short-videos-milloway-msit/?trackingId=azDPaBpFJjkSgxhlQnL9Zg%3D%3D )
but just cannot workout how to get the LRS record to display the VALUE of the score and not simply the name of the VAR I am using to track the score.
The javascript statement I am using is this:
send_statement('http://adlnet.gov/expapi/verbs/scored', 'scored', 'http://example.com/B1SCORE'. '%B1_SCORE%', 'CMCP Foundation Assessment');
But the result is that the LRS literally writes "%B1_SCORE%" not the value (I have also tried it without the % marks - and I'll get "B1_SCORE".
As you might suspect B1_SCORE is the VAR I have created in Storyline3 to track the B1 SCORE (and for testing I have set this to 80).
So is there is a simple way to create the statement I need so that the LRS records the value of the B1_SCORE (80) and not the name of the VAR?
I'm feeling seriously stupid asking this as although I'm not a programmer it is puzzling why I cannot work out why this is so hard to work out - or am I missing something key about how xAPI works?
4 Replies
Hi Kevin, I also run thru the examples of Mel you mentioned above. Just see there my comment in extending that example with sending variables. There you find what you are looking for. If you face issues let us know.
Best
Claudius
Hi Claudius - which discussion thread should I look at to locate your comments?
The one you mentioned here above.
Hey Kevin,
The link to the other conversation thread on LinkedIn is shared above, and I'll share it again here for ease of use :)
This discussion is closed. You can start a new discussion or contact Articulate Support.