Sessions metadata endpoint
Manage the metadata of learner sessions.
Endpoints:
Usage
The format of requests to the Data API use the following syntax:
https://data.learnosity.com/{LTS_VERSION}/{endpoint}
For example, to use the v2025.1.LTS
version and the itembank/items
endpoint, you would create a request like so:
https://data.learnosity.com/v2025.1.LTS/itembank/items
Important Data API is not a REST API. All requests must use the POST method with the action
request body parameter specifying the operation to use. The Learnosity SDK must be used to make requests to Data API.
Note Data API usage is subject to rate limits.
Related articles:
- Getting Started with the Data API
- See Release Cadence and Version Lifecycle for more information on available LTS versions.
Change Sessions Metadata
Update or override the metadata of the given sessions.
You would want to use this to add your own additional custom information related to sessions or apply session Tags.
Endpoint | /{LTS_VERSION}/jobs/sessions/metadata |
---|---|
HTTP method | POST |
Action type | "set" |
Request body parameters
Body content type: application/json
-
session_metadata array[object]
An array of session metadata objects representing the sessions to update.
Maximum entries:
100
-
metadata object
The metadata to apply to the session. Any existing metadata will be overwritten.
-
session_tags array[TagsV2]
A list of session Tags to be applied to the session.
-
-
session_id string
The session ID to update.
-
user_id string
The user ID recorded against the session.
Must match the
user_id
provided when the session was initialized.
-
Request body example
{ "session_metadata": [ { "user_id": "e2c1ae85-bc62-4b70-ada2-fd8cb3949644", "session_id": "9ce7daeb-e117-4d14-9452-c94a0afe203b", "metadata": { "session_tags": [ { "type": "assignment_type", "name": "homework" } ] } } ] }
Responses
Response example
{ "meta": { "status": true, "timestamp": 1487049275 }, "data": { "job_reference": "8a3d0ca2-eaa4-4c18-b9b9-1b12164e8b4e" } }