Skip to main content
PUT
/
assessment-items
/
{identifier}
curl --request PUT \
  --url https://qti.alpha-1edtech.ai/api/assessment-items/{identifier} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "format": "xml",
  "xml": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<qti-assessment-item\n  xmlns=\"http://www.imsglobal.org/xsd/imsqtiasi_v3p0\"\n  xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n  xsi:schemaLocation=\"http://www.imsglobal.org/xsd/imsqtiasi_v3p0 https://purl.imsglobal.org/spec/qti/v3p0/schema/xsd/imsqti_asiv3p0_v1p0.xsd\"\n  identifier=\"xml-choice-item-1\"\n  title=\"Sample Choice Question\"\n  adaptive=\"false\"\n  time-dependent=\"false\">\n\n  <qti-response-declaration identifier=\"RESPONSE\" cardinality=\"single\" base-type=\"identifier\">\n    <qti-correct-response>\n      <qti-value>B</qti-value>\n    </qti-correct-response>\n  </qti-response-declaration>\n\n  <qti-outcome-declaration identifier=\"FEEDBACK\" cardinality=\"single\" base-type=\"identifier\"/>\n  <qti-outcome-declaration identifier=\"FEEDBACK-INLINE\" cardinality=\"single\" base-type=\"identifier\"/>\n\n  <qti-assessment-stimulus-ref identifier=\"Stimulus1\" href=\"stimuli/Stimulus1\" title=\"Math Context\"/>\n  <qti-assessment-stimulus-ref identifier=\"Stimulus2\" href=\"stimuli/Stimulus2\" title=\"Additional Context\"/>\n\n  <qti-item-body>\n    <qti-choice-interaction response-identifier=\"RESPONSE\" shuffle=\"false\" max-choices=\"1\">\n      <qti-prompt>What is 2 + 2?</qti-prompt>\n      <qti-simple-choice identifier=\"A\">\n        3\n        <qti-feedback-inline outcome-identifier=\"FEEDBACK-INLINE\" identifier=\"A\" show-hide=\"show\">\n          <span style=\"color: #D9534F;\">Incorrect: Try counting again.</span>\n        </qti-feedback-inline>\n      </qti-simple-choice>\n      <qti-simple-choice identifier=\"B\">\n        4\n        <qti-feedback-inline outcome-identifier=\"FEEDBACK-INLINE\" identifier=\"B\" show-hide=\"show\">\n          <span style=\"color: #2E8B57;\">Correct: Well done!</span>\n        </qti-feedback-inline>\n      </qti-simple-choice>\n    </qti-choice-interaction>\n  </qti-item-body>\n\n  <qti-response-processing template=\"match_correct\">\n    <qti-response-condition>\n      <qti-response-if>\n        <qti-match>\n          <qti-variable identifier=\"RESPONSE\"/>\n          <qti-correct identifier=\"RESPONSE\"/>\n        </qti-match>\n        <qti-set-outcome-value identifier=\"FEEDBACK\">\n          <qti-base-value base-type=\"identifier\">CORRECT</qti-base-value>\n        </qti-set-outcome-value>\n      </qti-response-if>\n      <qti-response-else>\n        <qti-set-outcome-value identifier=\"FEEDBACK\">\n          <qti-base-value base-type=\"identifier\">INCORRECT</qti-base-value>\n        </qti-set-outcome-value>\n      </qti-response-else>\n    </qti-response-condition>\n  </qti-response-processing>\n\n  <qti-modal-feedback outcome-identifier=\"FEEDBACK\" identifier=\"CORRECT\" show-hide=\"show\">\n    <qti-content-body>\n      <p><strong>Correct!</strong> Well done.</p>\n    </qti-content-body>\n  </qti-modal-feedback>\n\n  <qti-modal-feedback outcome-identifier=\"FEEDBACK\" identifier=\"INCORRECT\" show-hide=\"show\">\n    <qti-content-body>\n      <p><strong>Incorrect.</strong> Please review and try again.</p>\n    </qti-content-body>\n  </qti-modal-feedback>\n</qti-assessment-item>",
  "metadata": {
    "subject": "Math",
    "grade": "5",
    "standard": "Number Operations",
    "lesson": "Basic Addition",
    "difficulty": "hard"
  }
}
'
{
  "identifier": "<string>",
  "title": "<string>",
  "type": "choice",
  "qtiVersion": "3.0",
  "timeDependent": false,
  "adaptive": false,
  "rawXml": "<string>",
  "content": {
    "qti-assessment-item": {
      "_attributes": {
        "xmlns": "<string>",
        "xmlns:xsi": "<string>",
        "xsi:schemaLocation": "<string>",
        "identifier": "<string>",
        "title": "<string>",
        "adaptive": "<string>",
        "time-dependent": "<string>"
      },
      "qti-response-declaration": [
        {
          "_attributes": {
            "identifier": "<string>",
            "cardinality": "<string>",
            "baseType": "<string>"
          },
          "qti-correct-response": {
            "qti-value": [
              "<string>"
            ]
          }
        }
      ],
      "qti-outcome-declaration": [
        {
          "_attributes": {
            "identifier": "<string>",
            "cardinality": "<string>",
            "baseType": "<string>"
          }
        }
      ],
      "qti-assessment-stimulus-ref": [
        {
          "_attributes": {
            "identifier": "<string>",
            "href": "<string>",
            "title": "<string>"
          }
        }
      ],
      "qti-item-body": "<unknown>",
      "qti-response-processing": "<unknown>"
    }
  },
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "responseDeclarations": [
    {
      "identifier": "<string>",
      "cardinality": "single",
      "correctResponse": {
        "value": [
          "<string>"
        ]
      },
      "baseType": "identifier"
    }
  ],
  "outcomeDeclarations": [
    {
      "identifier": "<string>",
      "cardinality": "single",
      "baseType": "identifier"
    }
  ],
  "responseProcessing": {
    "templateType": "match_correct",
    "responseDeclarationIdentifier": "<string>",
    "outcomeIdentifier": "<string>",
    "correctResponseIdentifier": "<string>",
    "incorrectResponseIdentifier": "<string>",
    "inlineFeedback": {
      "outcomeIdentifier": "<string>",
      "variableIdentifier": "<string>"
    }
  },
  "metadata": {
    "subject": "Math",
    "grade": "10",
    "difficulty": "easy",
    "learningObjectiveSet": [
      {
        "source": "CASE",
        "learningObjectiveIds": [
          "id-123",
          "id-456",
          "id-789"
        ]
      }
    ]
  },
  "modalFeedback": [
    {
      "outcomeIdentifier": "<string>",
      "identifier": "<string>",
      "showHide": "show",
      "content": "<string>",
      "title": "<string>"
    }
  ],
  "feedbackInline": [
    {
      "outcomeIdentifier": "<string>",
      "identifier": "<string>",
      "showHide": "show",
      "content": "<string>",
      "class": [
        "<string>"
      ]
    }
  ],
  "feedbackBlock": [
    {
      "outcomeIdentifier": "<string>",
      "identifier": "<string>",
      "showHide": "show",
      "content": "<string>",
      "class": [
        "<string>"
      ]
    }
  ],
  "__v": 123
}

Authorizations

Authorization
string
header
required

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

Path Parameters

identifier
string
required

Assessment item identifier

Body

application/json

The updated assessment item content, interactions, and configuration. Can be provided in either XML or JSON format.

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.

type
enum<string>
required

Assessment item interaction types that are supported by the service provider.

Available options:
choice,
text-entry,
extended-text,
inline-choice,
match,
order,
associate,
select-point,
graphic-order,
graphic-associate,
graphic-gap-match,
hotspot,
hottext,
slider,
drawing,
media,
upload
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

qtiVersion
string
default:3.0

QTI version of the assessment item

timeDependent
boolean
default:false

Indicates whether the candidate's response time affects the scoring or outcome of this assessment item. When true, timing data is used in response processing calculations.

adaptive
boolean
default:false

Indicates whether this assessment item adapts its presentation or behavior based on the candidate's responses. Adaptive items can modify their content, difficulty, or available options during the assessment session.

responseDeclarations
object[]
outcomeDeclarations
object[]
responseProcessing
object

Response processing is the process by which the Delivery Engine assigns outcomes based on the candidate's responses. The outcomes may be used to provide feedback to the candidate. Response processing must only take place in direct response to a user action or in response to some expected event, such as the end of a test.

metadata
object

Additional custom metadata for assessment items with validation for specific fields used by external applications

modalFeedback
object[]

Modal feedback shown to candidates in popup dialogs immediately following response processing. Cannot contain interaction elements and is displayed based on outcome variable values.

feedbackInline
object[]

Inline feedback embedded within interaction elements, displayed alongside choices or input areas. Provides contextual feedback.

feedbackBlock
object[]

Inline feedback embedded within interaction elements, displayed alongside choices or input areas. Provides contextual feedback.

__v
number

MongoDB version key for optimistic concurrency control

Response

Assessment item updated successfully

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.

type
enum<string>
required

Assessment item interaction types that are supported by the service provider.

Available options:
choice,
text-entry,
extended-text,
inline-choice,
match,
order,
associate,
select-point,
graphic-order,
graphic-associate,
graphic-gap-match,
hotspot,
hottext,
slider,
drawing,
media,
upload
qtiVersion
string
default:3.0
required

QTI version of the assessment item

timeDependent
boolean
default:false
required

Indicates whether the candidate's response time affects the scoring or outcome of this assessment item. When true, timing data is used in response processing calculations.

adaptive
boolean
default:false
required

Indicates whether this assessment item adapts its presentation or behavior based on the candidate's responses. Adaptive items can modify their content, difficulty, or available options during the assessment session.

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

responseDeclarations
object[]
outcomeDeclarations
object[]
responseProcessing
object

Response processing is the process by which the Delivery Engine assigns outcomes based on the candidate's responses. The outcomes may be used to provide feedback to the candidate. Response processing must only take place in direct response to a user action or in response to some expected event, such as the end of a test.

metadata
object

Additional custom metadata for assessment items with validation for specific fields used by external applications

modalFeedback
object[]

Modal feedback shown to candidates in popup dialogs immediately following response processing. Cannot contain interaction elements and is displayed based on outcome variable values.

feedbackInline
object[]

Inline feedback embedded within interaction elements, displayed alongside choices or input areas. Provides contextual feedback.

feedbackBlock
object[]

Inline feedback embedded within interaction elements, displayed alongside choices or input areas. Provides contextual feedback.

__v
number

MongoDB version key for optimistic concurrency control