198 lines
7.2 KiB
YAML
198 lines
7.2 KiB
YAML
schemas:
|
|
QuestionnaireVersion:
|
|
type: integer
|
|
format: int64
|
|
minimum: 0
|
|
description: >-
|
|
Version of the candidate questionnaire. A candidate without a saved
|
|
questionnaire has version 0; every save that changes the questionnaire
|
|
advances it by one.
|
|
examples:
|
|
- 3
|
|
StackTag:
|
|
type: string
|
|
minLength: 1
|
|
maxLength: 50
|
|
pattern: '^\S(?:.*\S)?$'
|
|
description: >-
|
|
Free technology tag of the candidate's stack, for example PostgreSQL,
|
|
Kubernetes, or Django. A tag is a descriptive attribute: it never
|
|
forms a category, never selects the task language, and never changes
|
|
a grade, so a tag such as "Senior" has no effect on any category. It
|
|
has no leading or trailing whitespace and no line breaks. The server
|
|
compares tags without regard to letter case. Clients show tags as
|
|
text, never as HTML.
|
|
WorkFormat:
|
|
type: string
|
|
description: "Acceptable work format: `remote`, `office`, or `hybrid`."
|
|
enum:
|
|
- remote
|
|
- office
|
|
- hybrid
|
|
WorkContext:
|
|
type: object
|
|
description: >-
|
|
Working context of the candidate's search. It holds no personal data
|
|
such as an address or a city; location, relocation, and salary
|
|
expectations belong to the candidate profile (`ProfileTerms`). The
|
|
acceptable work formats live only here: the profile does not repeat
|
|
them.
|
|
additionalProperties: false
|
|
required:
|
|
- work_formats
|
|
properties:
|
|
work_formats:
|
|
type: array
|
|
minItems: 1
|
|
maxItems: 3
|
|
uniqueItems: true
|
|
description: Acceptable work formats.
|
|
items:
|
|
$ref: "#/schemas/WorkFormat"
|
|
CandidateExperience:
|
|
type: object
|
|
description: >-
|
|
Experience that the candidate states for one specialization, in whole
|
|
months. It is self-reported context: it never adds assessment points
|
|
and never confirms a grade. The work history entries of the candidate
|
|
profile (`ProfileExperienceItem`) are a different, detailed claim: the
|
|
two are saved separately and the server neither adds the entries up
|
|
nor fills them from these totals.
|
|
additionalProperties: false
|
|
required:
|
|
- commercial_months
|
|
- academic_months
|
|
properties:
|
|
commercial_months:
|
|
type: integer
|
|
format: int32
|
|
minimum: 0
|
|
maximum: 600
|
|
description: Months of commercial work in the specialization.
|
|
academic_months:
|
|
type: integer
|
|
format: int32
|
|
minimum: 0
|
|
maximum: 600
|
|
description: >-
|
|
Months of study, internships, or academic projects in the
|
|
specialization.
|
|
QuestionnaireSpecialization:
|
|
type: object
|
|
description: >-
|
|
One specialization chosen by the candidate with the candidate's
|
|
self-assessment. `self_assessed_grade` is a claim: it influences where
|
|
the assessment starts and which grade the assessment step offers
|
|
first, but it adds no points and never becomes a confirmed grade. A
|
|
confirmed grade, and with it a category, comes only from an assessment
|
|
result and is never part of the questionnaire; unknown fields such as
|
|
`confirmed_grade` or `category` are rejected. Task languages and the
|
|
stack are attributes of the chosen specialization, not categories. The
|
|
candidate profile states the same kind of claim in the `roles` of
|
|
`CandidateProfile` (`ProfileRoleItem.self_assessed_grade`): the
|
|
questionnaire value starts the assessment and the profile value is what
|
|
the profile shows, the two are saved separately, and neither is ever a
|
|
confirmed grade.
|
|
additionalProperties: false
|
|
required:
|
|
- specialization
|
|
- self_assessed_grade
|
|
- task_languages
|
|
- stack
|
|
- experience
|
|
properties:
|
|
specialization:
|
|
$ref: "./catalog_schemas.yml#/schemas/SpecializationCode"
|
|
self_assessed_grade:
|
|
$ref: "./catalog_schemas.yml#/schemas/GradeCode"
|
|
task_languages:
|
|
type: array
|
|
maxItems: 2
|
|
uniqueItems: true
|
|
description: >-
|
|
Task languages in which the candidate wants to solve assessment
|
|
tasks of this specialization. Each value must be one of
|
|
`test_availability.task_languages` of the specialization in the
|
|
current catalog; any other value answers 400 validation_failed
|
|
with a pointer to it. Empty when the bank offers no choice of
|
|
language.
|
|
items:
|
|
$ref: "./catalog_schemas.yml#/schemas/TaskLanguage"
|
|
stack:
|
|
type: array
|
|
maxItems: 20
|
|
uniqueItems: true
|
|
description: Technology tags of the candidate in this specialization.
|
|
items:
|
|
$ref: "#/schemas/StackTag"
|
|
experience:
|
|
description: >-
|
|
Stated experience, or null when the candidate did not state it.
|
|
oneOf:
|
|
- $ref: "#/schemas/CandidateExperience"
|
|
- type: "null"
|
|
CandidateQuestionnaire:
|
|
type: object
|
|
description: >-
|
|
Questionnaire of the current candidate: the chosen specializations with
|
|
self-assessed grades and the working context. It never contains a
|
|
confirmed grade or a category; those come only from assessment
|
|
results. A candidate who has not saved the questionnaire yet gets
|
|
version 0, no specializations, and null `work_context` and
|
|
`updated_at`.
|
|
additionalProperties: false
|
|
required:
|
|
- version
|
|
- specializations
|
|
- work_context
|
|
- updated_at
|
|
properties:
|
|
version:
|
|
$ref: "#/schemas/QuestionnaireVersion"
|
|
specializations:
|
|
type: array
|
|
maxItems: 2
|
|
description: >-
|
|
Chosen specializations in the order the candidate gave them, each
|
|
specialization at most once. Each one is assessed independently.
|
|
items:
|
|
$ref: "#/schemas/QuestionnaireSpecialization"
|
|
work_context:
|
|
description: Working context, or null before the first save.
|
|
oneOf:
|
|
- $ref: "#/schemas/WorkContext"
|
|
- type: "null"
|
|
updated_at:
|
|
description: Time of the last change, or null before the first save.
|
|
oneOf:
|
|
- $ref: "./common_schemas.yml#/schemas/Timestamp"
|
|
- type: "null"
|
|
CandidateQuestionnaireUpdate:
|
|
type: object
|
|
description: >-
|
|
Complete new state of the questionnaire. It replaces the stored
|
|
specializations and working context as a whole. Unknown fields are
|
|
rejected, so a request cannot set a confirmed grade or a category.
|
|
additionalProperties: false
|
|
required:
|
|
- expected_version
|
|
- specializations
|
|
- work_context
|
|
properties:
|
|
expected_version:
|
|
$ref: "#/schemas/QuestionnaireVersion"
|
|
specializations:
|
|
type: array
|
|
minItems: 1
|
|
maxItems: 2
|
|
description: >-
|
|
One or two chosen specializations. The schema limits the count; the
|
|
server also requires each specialization to appear at most once and
|
|
answers a repeated one with 400 validation_failed and the pointer
|
|
of the repeated item's `specialization`, for example
|
|
`/specializations/1/specialization`.
|
|
items:
|
|
$ref: "#/schemas/QuestionnaireSpecialization"
|
|
work_context:
|
|
$ref: "#/schemas/WorkContext"
|