PUT answer/…
Submits the answer to a practice question, and receives the evaluation of the answer.
Resource URL
https://www.drillster.com/api/2.1.1/answer/{reference}
Parameters
Field | Description |
---|---|
reference required |
Unique identifier of the answered question. The reference must be copied from the 2.1.1 Question object received in the 2.1.1 QuestionResponse. |
answer optional, repeatable |
The value of the selected (multiple choice) or entered (open-ended) answer. For multiple choice questions, this value must be copied from the question.tell.terms.value in the question response. For open-ended questions, this value is the text that the user has entered. If multiple answers must be submitted (for SET or SEQUENCE compositions), the answer parameter can be submitted multiple times.It is allowed to omit the answer parameter altogether, which is interpreted as an incorrect answer. This could for instance be used for a "reveal answer" option. |
If a PUT request has no body (i.e. the body is empty), it is still mandatory to include a Content-Length header (i.e.
Content-Length: 0
). Not all HTTP clients do this automatically. For more information, please see RFC 2616.
Response
An 2.1.1 AnswerResponse object.
Error responses
The following error situations are possible:
ID | Response code | Description |
---|---|---|
invalid_request |
400 (Bad request) | The request was invalid or the reference was missing. |
reference_not_found |
404 (Not found) | The given question reference was not found. This could mean that the answer was already processed. |
no_access |
403 (Forbidden) | The caller does not have access to the given question reference. |
internal_error |
500 (Internal error) | Something bad happened. |
Last updated on