Activity-Tags - Endpoints - Data API

Activity Tags endpoint

Manage Tags associated with Activities in your Item bank.

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:

Set Activities Tags

Overwrite Tags for Activities in your Item bank.

You would want to use this to make bulk replacements of Tags for many Activities.

Important Existing Tags assigned to Activities will be removed from the Activity and replaced with the new Tags.

Endpoint /{LTS_VERSION}/itembank/activities/tags
HTTP method POST
Action type "set"

Request body parameters

Body content type: application/json

  • organisation_id integer

    Specifies the Item bank to update.

    The API consumer making the request will need to have access to the Item bank. This access can be checked via the API consumer's configuration in the Learnosity Console.

    Default: the primary Item bank associated with the API consumer.

  • activities array[object]

    A list of definition objects for Activities with Tags to be assigned.

    Maximum entries: 50

    • reference string

      The reference for the Activity.

    • tags array[TagsV2]

      A list of Tags to assign to the Activity.

      See TagsV2 for more information.

  • meta object

    (optional) A metadata object which will be applied to all Activities in this request.

    • user object

      (optional) Details of the user issuing this request. The user details are recorded in the audit trail for each of the new or modified Activities, and will be shown in Learnosity Author Site when viewing the history of changes on an Activity.

      Default: Manual User/Data GUI

      • id string

        The ID of the user issuing this request.

        Important If the ID provided does not exist, a new user will be created. If the ID provided already exists, then all the attributes provided (meta.user.firstname, meta.user.lastname, or meta.user.email) will overwrite the existing attributes.

        Note The user ID value is shown in the Learnosity Author Site audit trail if both meta.user.firstname and meta.user.lastname are not provided.

        Maximum length: 50

      • firstname string

        (optional) First name of the user issuing the request. This first name is recorded in the audit trail for each of the created Activities.

        Maximum length: 50

      • lastname string

        (optional) Last name of the user issuing the request. This last name is recorded in the audit trail for each of the created Activities.

        Maximum length: 50

      • email string

        (optional) Email address of the user issuing the request. This email address is recorded in the audit trail for each of the created Activities.

        Maximum length: 255

Request body example

{
    "activities": [
        {
            "reference": "activity1",
            "tags": {
                "demo-tagtype-1": [
                    "tag1",
                    "tag2"
                ],
                "demo-tagtype-2": [
                    "tag3"
                ]
            }
        }
    ]
}

Responses

Response example

{
    "meta": {
        "status": true
    },
    "data": []
}

Append Activities Tags

Add new Tags to Activities in your Item bank. Existing Tags assigned to these Activities will not be removed.

You would want to use this to make bulk additions of Tags to Activities.

Endpoint /{LTS_VERSION}/itembank/activities/tags
HTTP method POST
Action type "update"

Request body parameters

Body content type: application/json

  • organisation_id integer

    Specifies the Item bank to update.

    The API consumer making the request will need to have access to the Item bank. This access can be checked via the API consumer's configuration in the Learnosity Console.

    Default: the primary Item bank associated with the API consumer.

  • activities array[object]

    A list of definition objects for Activities with Tags to be assigned.

    Maximum entries: 50

    • reference string

      The reference for the Activity.

    • tags array[TagsV2]

      A list of Tags to assign to the Activity.

      See TagsV2 for more information.

  • meta object

    (optional) A metadata object which will be applied to all Activities in this request.

    • user object

      (optional) Details of the user issuing this request. The user details are recorded in the audit trail for each of the new or modified Activities, and will be shown in Learnosity Author Site when viewing the history of changes on an Activity.

      Default: Manual User/Data GUI

      • id string

        The ID of the user issuing this request.

        Important If the ID provided does not exist, a new user will be created. If the ID provided already exists, then all the attributes provided (meta.user.firstname, meta.user.lastname, or meta.user.email) will overwrite the existing attributes.

        Note The user ID value is shown in the Learnosity Author Site audit trail if both meta.user.firstname and meta.user.lastname are not provided.

        Maximum length: 50

      • firstname string

        (optional) First name of the user issuing the request. This first name is recorded in the audit trail for each of the modified Activities.

        Maximum length: 50

      • lastname string

        (optional) Last name of the user issuing the request. This last name is recorded in the audit trail for each of the affected Activities or Tags.

        Maximum length: 50

      • email string

        (optional) Email address of the user issuing the request. This email address is recorded in the audit trail for each of the affected Activities or Tags.

        Maximum length: 255

Request body example

{
    "activities": [
        {
            "reference": "activity1",
            "tags": [
                {
                    "type": "subject",
                    "name": "math"
                }
            ]
        }
    ]
}

Responses

Response example

{
    "meta": {
        "status": true,
        "timestamp": 1499223766
    },
    "data": []
}
Was this article helpful?

Did you arrive here by accident? If so, learn more about Learnosity.