Skip to main content
POST
/
stimuli
curl --request POST \ --url https://qti.alpha-1edtech.ai/api/stimuli \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "format": "json", "identifier": "stimulus-science-ecosystems", "title": "Forest Ecosystem Reading Passage", "content": "\n <div class=\"stimulus-content\">\n <h2>Forest Ecosystems</h2>\n <p>A forest ecosystem is a complex community of plants, animals, and microorganisms that interact with each other and their physical environment. These ecosystems play crucial roles in maintaining environmental balance and supporting biodiversity.</p>\n <h3>Layers of the Forest</h3>\n <p><strong>Canopy Layer:</strong> The uppermost layer formed by the crowns of tall trees. This layer receives the most sunlight and is home to many birds, insects, and mammals.</p>\n <p><strong>Understory:</strong> Below the canopy, this layer consists of smaller trees and shrubs that can tolerate lower light conditions. Many flowering plants and young trees grow here.</p>\n <p><strong>Forest Floor:</strong> The ground level where decomposition occurs. Fallen leaves, branches, and other organic matter break down, providing nutrients for plant growth.</p>\n <h3>Ecological Relationships</h3>\n <p>Forest ecosystems demonstrate various ecological relationships:</p>\n <ul>\n <li><em>Producers:</em> Trees and plants that make their own food through photosynthesis</li>\n <li><em>Primary Consumers:</em> Herbivores that eat plants, such as deer and rabbits</li>\n <li><em>Secondary Consumers:</em> Carnivores that eat herbivores, such as foxes and hawks</li>\n <li><em>Decomposers:</em> Organisms like fungi and bacteria that break down dead material</li>\n </ul>\n </div>\n ", "metadata": { "subject": "Science", "grade": "7", "standard": "Life Science", "lesson": "Ecosystems and Biodiversity", "difficulty": "medium" } } '
{
  "identifier": "<string>",
  "title": "<string>",
  "catalogInfo": [
    {
      "id": "<string>",
      "support": "<string>",
      "content": "<string>"
    }
  ],
  "rawXml": "<string>",
  "content": {
    "qti-assessment-stimulus": {
      "_attributes": {
        "xmlns": "<string>",
        "xmlns:xsi": "<string>",
        "xsi:schemaLocation": "<string>",
        "identifier": "<string>",
        "xml:lang": "<string>",
        "title": "<string>"
      },
      "qti-stimulus-body": {},
      "qti-stylesheet": {
        "_attributes": {
          "href": "<string>",
          "type": "<string>"
        }
      },
      "qti-catalog-info": {
        "qti-catalog": {
          "_attributes": {
            "id": "<string>"
          },
          "qti-card": {
            "_attributes": {
              "support": "<string>"
            },
            "qti-html-content": {}
          }
        }
      }
    }
  },
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "label": "<string>",
  "language": "en",
  "stylesheet": {
    "href": "<string>",
    "type": "<string>"
  },
  "toolName": "<string>",
  "toolVersion": "<string>",
  "metadata": {},
  "__v": 123
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

application/json

The stimulus content to create.

Create or update a stimulus on the service provider with HTML content and optional configuration

identifier
string
required

Unique identifier for the entity on the service provider.

title
string
required

Human-readable title of the entity on the service provider.

content
string
required

HTML content of the stimulus provided as a string when creating or updating a stimulus. When the rawXml is generated, this content is used to create teh qti-stimulus-body that lives on the xml.

label
string

A human readable label that can be used to describe the Stimulus.

language
string
default:en

The default language for the Stimulus.

stylesheet
object

The set of external style sheets that are associated with the Stimulus. The order of definition is significant.

catalogInfo
object[]

Array of catalog cards.

toolName
string

The tool name characteristic allows the tool creating the stimulus to identify itself. Other processing systems may use this information to interpret the content of application specific data, such as labels on the elements of the stimulus's stimulus body.

toolVersion
string

The tool version characteristic allows the tool creating the item to identify its version. This value must only be interpreted in the context of the tool-name.

metadata
object

Additional custom metadata for extending entity properties beyond standard specification for QTI entities.

Response

Stimulus created successfully

Complete stimulus data structure returned from the database including parsed content and metadata

identifier
string
required

Unique identifier for the entity on the service provider.

title
string
required

Human-readable title of the entity on the service provider.

catalogInfo
object[]
required

Array of catalog cards.

rawXml
string
required

Raw XML representation of the entity, automatically generated from the JSON or XML sent when creating entities on the service provider. The rawxml field will contain all content sent when creating the entity on the service provider. This field is stable and should be used when working within this QTI API.

content
object
required

Parsed XML content generated by the service provider. For production use, rawXml is recommended over this parsed structure.

createdAt
string<date-time>
required

ISO 8601 timestamp when the entity was created

updatedAt
string<date-time>
required

ISO 8601 timestamp when the entity was last updated

label
string

A human readable label that can be used to describe the Stimulus.

language
string
default:en

The default language for the Stimulus.

stylesheet
object

The set of external style sheets that are associated with the Stimulus. The order of definition is significant.

toolName
string

The tool name characteristic allows the tool creating the stimulus to identify itself. Other processing systems may use this information to interpret the content of application specific data, such as labels on the elements of the stimulus's stimulus body.

toolVersion
string

The tool version characteristic allows the tool creating the item to identify its version. This value must only be interpreted in the context of the tool-name.

metadata
object

Additional custom metadata for extending entity properties beyond standard specification for QTI entities.

__v
number

MongoDB version key for optimistic concurrency control