feat(api): add candidate assessment attempt contract
This commit is contained in:
1 parent
6c86c4e559
commit
565ef8d4f5
100 files changed
+30314
-74
No files matched your search
@@ -261,3 +261,116 @@ QuestionnaireVersionConflict:
|
||||
examples:
|
||||
version_conflict:
|
||||
$ref: ./examples.yml#/VersionConflict
|
||||
AssessmentAttemptCreateValidationFailed:
|
||||
description: >-
|
||||
The body does not match the contract or violates an assessment rule: an
|
||||
unknown specialization, grade, or task language, an unknown field such
|
||||
as mode or seed, a specialization that is not in the questionnaire, or
|
||||
a task language that the published bank does not offer; code
|
||||
validation_failed with body pointers. Nothing was created, and the
|
||||
outcome is not stored under the Idempotency-Key.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
specialization_not_in_questionnaire:
|
||||
$ref: ./examples.yml#/AssessmentSpecializationNotInQuestionnaire
|
||||
AssessmentAnswerValidationFailed:
|
||||
description: >-
|
||||
The body does not match the contract or the answer does not fit the
|
||||
item: a format other than the item format, an option, element, or line
|
||||
that the item does not have, an order that is not a permutation of every
|
||||
element, more selections than the item allows, a text longer than the
|
||||
item allows, a language that the practice does not offer, or an unknown
|
||||
field such as score or duration; code validation_failed with body
|
||||
pointers. When the decoder does not record the path of a nested field,
|
||||
the pointer is the whole body. Nothing was stored, and the outcome is
|
||||
not stored under the Idempotency-Key.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
unknown_option:
|
||||
$ref: ./examples.yml#/AssessmentAnswerUnknownOption
|
||||
score_sent_by_client:
|
||||
$ref: ./examples.yml#/AssessmentAnswerUnknownField
|
||||
AssessmentCommandConflict:
|
||||
description: >-
|
||||
The attempt state does not allow the answer at the current version, code
|
||||
state_conflict: the attempt is terminal or past its limits, the item is
|
||||
not the current item, the item already has a different answer, or the
|
||||
practice has a pending or finished verdict and the submission differs.
|
||||
Or a request with the same Idempotency-Key is still running, code
|
||||
idempotency_in_progress. Nothing was changed in either case; read the
|
||||
attempt to see its state.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
state_conflict:
|
||||
$ref: ./examples.yml#/AssessmentItemNotCurrent
|
||||
idempotency_in_progress:
|
||||
$ref: ./examples.yml#/IdempotencyInProgress
|
||||
AssessmentFinalizeConflict:
|
||||
description: >-
|
||||
The attempt state does not allow finalize at the current version, code
|
||||
state_conflict: items or the main practice are unfinished, a practice
|
||||
verdict is pending, or the attempt ended as expired or insufficient_bank.
|
||||
The problem does not list the unfinished parts, because Problem allows
|
||||
no extension fields; the attempt shows them in `state`, `progress`,
|
||||
`current_item`, and `practices`. Or a request with the same
|
||||
Idempotency-Key is still running, code idempotency_in_progress. Nothing
|
||||
was changed in either case.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
state_conflict:
|
||||
$ref: ./examples.yml#/AssessmentFinalizeNotReady
|
||||
idempotency_in_progress:
|
||||
$ref: ./examples.yml#/IdempotencyInProgress
|
||||
AssessmentCreateConflict:
|
||||
description: >-
|
||||
No attempt can start for the category now, code state_conflict: the
|
||||
specialization already has an active attempt, a retry or promotion
|
||||
interval or the attempt limit blocks the grade, or the bank is
|
||||
insufficient. GetMyAssessmentAvailability tells which, with the date
|
||||
when a blocked attempt opens. Or a request with the same Idempotency-Key
|
||||
is still running, code idempotency_in_progress. Nothing was created in
|
||||
either case.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
state_conflict:
|
||||
$ref: ./examples.yml#/AssessmentAttemptNotAvailable
|
||||
idempotency_in_progress:
|
||||
$ref: ./examples.yml#/IdempotencyInProgress
|
||||
AssessmentResultNotReady:
|
||||
description: >-
|
||||
The attempt is still active, so it has no result yet; code
|
||||
state_conflict. The attempt state tells what remains to be done.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
state_conflict:
|
||||
$ref: ./examples.yml#/AssessmentResultNotReady
|
||||
AssessmentVersionConflict:
|
||||
description: >-
|
||||
`expected_version` is not the current attempt version; code
|
||||
version_conflict. Nothing was changed, and the outcome is not stored
|
||||
under the Idempotency-Key; read the attempt again before retrying.
|
||||
content:
|
||||
application/problem+json:
|
||||
schema:
|
||||
$ref: ./schemas.yml#/Problem
|
||||
examples:
|
||||
version_conflict:
|
||||
$ref: ./examples.yml#/AssessmentStaleVersion
|
||||
Reference in new issue
Block a user