ABCDE
1
Data-In Scenario: Collection or Assessment Started / Completed Event
https://experienceapi.com/statements-101/
2
Level 1 KeyData TypeLevel 2 KeyData TypeShort Description
3
idUUIDUnique Id should be generated for every event sent. This eventId should be same for start and stop event
4
timestampLONGUTC current time in Millisecond
5
versionSTRINGVersion information and expected fixed value: "1.0.0"
6
actorJSONobjectTypeSTRINGFixed value: "Agent"
7
account.nameSTRINGUnique ID of user as exchanged with Gooru as part of user SSO/Sign-up/Roster
8
9
verbJSONidIRIhttps://registry.tincanapi.com/#home/verbs

Supported values:
Completed: http://activitystrea.ms/schema/1.0/complete
Started: http://activitystrea.ms/schema/1.0/start
10
display.en-usSTRINGFixed value: "Completed" / "Started"
11
12
objectJSONidIRI
Unique Id identifying the content item as IRI. Supported values (replace uuids with right content uuids):

CULC: "https://www.gooru.org/api/catalog/v1/course/47b13415-1df2-4c40-aaae-443a3524959d/unit/47b13415-1df2-4c40-aaae-443a3524959d/lesson/47b13415-1df2-4c40-aaae-443a3524959d/collection/47b13415-1df2-4c40-aaae-443a3524959d"
CULA: "https://www.gooru.org/api/catalog/v1/course/47b13415-1df2-4c40-aaae-443a3524959d/unit/47b13415-1df2-4c40-aaae-443a3524959d/lesson/47b13415-1df2-4c40-aaae-443a3524959d/assessment/47b13415-1df2-4c40-aaae-443a3524959d"
Collection: "https://www.gooru.org/api/catalog/v1/collection/47b13415-1df2-4c40-aaae-443a3524959d"
Assessment: "https://www.gooru.org/api/catalog/v1/assessment/47b13415-1df2-4c40-aaae-443a3524959d"
13
objectTypeSTRINGFixed value: "Activity"
14
definition.typeIRIhttps://registry.tincanapi.com/#home/activityTypes

Supported types: playlist, assessment
15
definition.extensions.durationSTRINGISO 8601 Durations - expected time to be spent on object; default: null
16
17
resultJSONscore.scaledDECIMALNormalized score; default: 0
18
score.minDECIMALMinimum value that can be scored; default: 0
19
score.maxDECIMALMaximum value that can be scored; default: 1
20
score.rawDECIMALUser score value between 0 and score.max; default: 0
21
durationSTRINGISO 8601 Durations - timespent by user on given content item
22
completionBOOLEANTRUE
23
successBOOLEANTRUE / FALSE
24
25
contextJSONextensions.session-idSTRINGSession id associated with the study activity. UUID expected.
26
teamSTRINGClass ID; default: null. If exists, the study is considered a class activity; otherwise an independent activity.
27
platformSTRINGApp ID shared with partner (mapped internally to Gooru AppIDs)
28
29
CURL Example: For Start Collection Event
30
curl 'https://www.gooru.org/api/pi-datain/v1/usercon/events' -X POST -H 'Authorization: Token MjoxNTE5ODczNzc2NjY1Ojk1YTc0NGUxLTYzMWUtNDY0Mi04NzVkLThiMDdhNWUzYjQyMTo6YmE5NTZhOTctYWUxNS0xMWU1LWEzMDItZjhhOTYzMDY1OTc2' --data-binary
'{"id":"45d53d9e-5fda-4339-85f8-3ab2e2aa42fe","timestamp":1475453112073,"version":"1.0.0","actor":{"objectType":"Agent","account":{"name":"6690e6c9-3ef0-4ed3-8b37-7f3964730bee"}},"verb":{"id":"http://activitystrea.ms/schema/1.0/start","display":{"en-US":"Started"}},"object":{"id":"https://www.gooru.org/api/catalog/v1/course/47b13415-1df2-4c40-aaae-443a3524959d/unit/47b13415-1df2-4c40-aaae-443a3524959d/lesson/47b13415-1df2-4c40-aaae-443a3524959d/assessment/47b13415-1df2-4c40-aaae-443a3524959d","objectType":"Activity","definition":{"type":"http://adlnet.gov/expapi/activities/assessment","extensions":{"duration":"PT1H0M0S"}}},"result":{"score":{"scaled":0,"raw":0,"min":0,"max":100},"success":false,"completion":false,"duration":null},"context":{"extensions":{"session-id":"406f6148-a52a-4c75-a91b-026740e181cf"},"platform":"47b13415-1df2-4c40-aaae-443a3524959d","team":"47b13415-1df2-4c40-aaae-443a3524959d"}}'
31
CURL Example: For Stop Collection Event
32
curl 'https://www.gooru.org/api/pi-datain/v1/usercon/events' -X POST -H 'Authorization: Token MjoxNTE5ODczNzc2NjY1Ojk1YTc0NGUxLTYzMWUtNDY0Mi04NzVkLThiMDdhNWUzYjQyMTo6YmE5NTZhOTctYWUxNS0xMWU1LWEzMDItZjhhOTYzMDY1OTc2' --data-binary
'{"id":"45d53d9e-5fda-4339-85f8-3ab2e2aa42fe","timestamp":1475453112073,"version":"1.0.0","actor":{"objectType":"Agent","account":{"name":"6690e6c9-3ef0-4ed3-8b37-7f3964730bee"}},"verb":{"id":"http://activitystrea.ms/schema/1.0/complete","display":{"en-US":"completed"}},"object":{"id":"https://www.gooru.org/api/catalog/v1/course/47b13415-1df2-4c40-aaae-443a3524959d/unit/47b13415-1df2-4c40-aaae-443a3524959d/lesson/47b13415-1df2-4c40-aaae-443a3524959d/assessment/47b13415-1df2-4c40-aaae-443a3524959d","objectType":"Activity","definition":{"type":"http://adlnet.gov/expapi/activities/assessment","extensions":{"duration":"PT1H0M0S"}}},"result":{"score":{"scaled":0,"raw":92,"min":0,"max":100},"success":true,"completion":true,"duration":"PT1H0M0S"},"context":{"extensions":{"session-id":"406f6148-a52a-4c75-a91b-026740e181cf"},"platform":"47b13415-1df2-4c40-aaae-443a3524959d","team":"47b13415-1df2-4c40-aaae-443a3524959d"}}'
33
34
** Endpoints might vary but structure would be as captured above
35
** Authorization token embeds tenant / partner information