Storyline Tincan and State API issue

Jan 14, 2015

Hi there,

We are developing a LRS system and try to test Articulate Storyline Tincan content.

However, we are having an issue with state API.

Articuatle Storyline 2 send state to LRS state API as a string. However, in the xAPI specs, it states that the document to send to state API need to be a JSON format.

Could you please explain the reason for sending this a string or do I misunderstood the xAPI specs?





10 Replies
Andrew Downes

Hi Kien!

I'd certainly recommend to the Articulate developers that they use a JSON document to store their bookmarking data. There's certain LRS requirements in the spec that allow values within bookmarking data to be individually updated if a JSON object is used, and I imagine that a JSON object would make things easier for developers wanting to access this data as part of a Storyline plugin or something. 

It's not a requirement of the spec to do so though and a plain text string is absolutely allowed. In fact, any type of document can be stored including media, office documents, PDFs, even things like Open Badges. 

It's also worth noting that building an LRS is hard. There are a number of commercial and open source LRS that will likely be cheaper than building one yourself. Email me if you'd like to chat about these in more detail. 

Kien Vu

Hi Andrew,

Thank you for this. 

In the xAPI specs, session 7.3 Document APIs, it states that:

"If the original document exists, and the original document or the document being posted do not have a Content-Type: of "application/json", or if either document cannot be parsed as JSON Objects, the LRS MUST respond with HTTP status code 400 Bad Request, and MUST NOT update the target document as a result of the request."

From this, I understand that the document need to be a JSON format, otherwise return 400 Bad request.

Could you please explain a bit more for us about this?

I tried read the specs many times but I could not see any place that it mentions about any type of document can be accepted for document API.

Thank you for your suggestion regarding using other LRS.











Andrew Downes


The important part of that quote for this question is the "If" at the start. This is specific behaviour if the Document is a JSON object and doesn't apply if the Document is not. This section also only relates to Documents stored using the POST method, whereas presumably (hopefully!) Storyline will be using PUT. 

The part of the spec that makes clear that documents can have any type is the table in section 5.1 which lists the type of the document contents as "Arbitrary binary data". See

Does that help clarify?


Sébastien Fraysse


I am also in the process of developing an LRS and I passed the xAPI conformance test.  

However, I had exactly the same issue when trying to play Articulate content.

Andrew, you are right when you say that documents can have any type.

However, my understanding of the spec is that the content-type in the request header should match with the content you really send to the LRS.

The problem is that Storyline set the content-type to "application/json", but the content is not a JSON content.

This may be considered as an inconsistency by the LRS and may result in an Error 400.

This discussion is closed. You can start a new discussion or contact Articulate Support.