OpenAPI Specification
openapi: 3.0.1
info:
title: VCV chatbot test API
description: open api
version: v3
servers:
- url: https://my.vcv.ai
- url: https://my.vcv.ru
- url: '{hostname}'
variables:
hostname:
default: http://localhost:8080
security:
- bearerAuth: []
tags:
- name: test
paths:
/api/v3/tests/vacancy:
get:
description: Get vacancy tests list
tags:
- test
parameters:
- $ref: '#/components/parameters/pagination_page'
- $ref: '#/components/parameters/pagination_page_size'
- name: with[]
in: query
description: Relations to retrieve
required: false
schema:
type: array
items:
type: string
enum:
- questions
- questions.answers
- questions.media
- questions.variables
- $ref: '#/components/parameters/filter_id'
- $ref: '#/components/parameters/filter_vacancy_id'
- $ref: '#/components/parameters/filter_created_at_from'
- $ref: '#/components/parameters/filter_created_at_to'
responses:
'200':
description: list of vacancy tests
content:
application/json:
schema:
properties:
_total_items:
type: integer
_page:
type: integer
_page_count:
type: integer
_links:
properties:
self:
type: object
properties:
href:
type: string
format: uri
next:
type: object
properties:
href:
type: string
format: uri
last:
type: object
properties:
href:
type: string
format: uri
type: object
_embedded:
type: object
properties:
vacancy_tests:
type: array
items:
allOf:
- $ref: '#/components/schemas/VacancyTest'
- type: object
properties:
_embedded:
type: object
properties:
questions:
type: array
items:
allOf:
- $ref: '#/components/schemas/VacancyTestQuestion'
- type: object
properties:
_embedded:
type: object
properties:
answers:
type: array
items:
$ref: '#/components/schemas/VacancyTestAnswer'
variables:
type: array
items:
$ref: '#/components/schemas/VacancyTestQuestionVariable'
media:
$ref: '#/components/schemas/VacancyTestQuestionMedia'
type: object
/api/v3/tests/vacancy/{id}:
get:
description: Get vacancy test detail
tags:
- test
parameters:
- name: id
in: path
description: Id
required: true
schema:
type: integer
- name: with[]
in: query
description: Relations to retrieve
required: false
schema:
type: array
items:
type: string
enum:
- questions
- questions.answers
- questions.media
- questions.variables
responses:
'200':
description: vacancy test
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/VacancyTest'
- type: object
properties:
_embedded:
type: object
properties:
questions:
type: array
items:
allOf:
- $ref: '#/components/schemas/VacancyTestQuestion'
- type: object
properties:
_embedded:
type: object
properties:
answers:
type: array
items:
$ref: '#/components/schemas/VacancyTestAnswer'
variables:
type: array
items:
$ref: '#/components/schemas/VacancyTestQuestionVariable'
media:
$ref: '#/components/schemas/VacancyTestQuestionMedia'
patch:
description: Update vacancy test
tags:
- test
parameters:
- name: id
in: path
description: Id
required: true
schema:
type: integer
requestBody:
required: true
content:
application/json:
schema:
properties:
time_limit:
type: integer
nullable: true
time_limit_enabled:
type: boolean
nullable: true
question_shuffle:
type: boolean
nullable: true
answer_shuffle:
type: boolean
nullable: true
calculate_test_status:
type: boolean
nullable: true
is_dropout_enabled:
type: boolean
is_camera_required:
type: boolean
required_score:
type: integer
nullable: true
question_limit:
type: integer
question_page_limit:
type: integer
rounding_precision:
type: integer
questions:
type: array
items:
properties:
id:
type: integer
nullable: true
type:
type: string
name:
type: string
nullable: true
body:
type: string
time_limit:
type: integer
time_limit_enabled:
type: boolean
nullable: true
has_valid_answer:
type: boolean
nullable: true
is_graph_enabled:
type: boolean
is_variables_enabled:
type: boolean
sort_order:
type: integer
chart_config:
type: object
variables:
type: array
items:
properties:
id:
type: integer
nullable: true
name:
type: string
formula:
type: string
nullable: true
min:
type: number
nullable: true
max:
type: number
nullable: true
step:
type: number
nullable: true
type:
type: integer
enum:
- 1
- 2
description: '1 - Integer
2 - Float
'
type: object
answers:
type: array
items:
properties:
valid:
type: boolean
is_formula:
type: boolean
id:
type: integer
nullable: true
body:
type: string
nullable: true
sort_order:
type: integer
nullable: true
type: object
media:
type: object
nullable: true
properties:
title:
type: string
type:
type: string
url:
type: string
is_separate_page:
type: boolean
type: object
responses:
'200':
description: vacancy test
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/VacancyTest'
- type: object
properties:
_embedded:
type: object
properties:
questions:
type: array
items:
allOf:
- $ref: '#/components/schemas/VacancyTestQuestion'
- type: object
properties:
_embedded:
type: object
properties:
answers:
type: array
items:
$ref: '#/components/schemas/VacancyTestAnswer'
variables:
type: array
items:
$ref: '#/components/schemas/VacancyTestQuestionVariable'
media:
$ref: '#/components/schemas/VacancyTestQuestionMedia'
/api/v3/tests/response:
get:
description: Get response tests list
tags:
- test
parameters:
- $ref: '#/components/parameters/pagination_page'
- $ref: '#/components/parameters/pagination_page_size'
- $ref: '#/components/parameters/filter_vacancy_id'
- name: with[]
in: query
description: Relations to retrieve
required: false
schema:
type: array
items:
type: string
enum:
- questions
- questions.answers
- questions.media
- screenshots
- result
- questions.answers.candidateAnswers
- name: fields[]
in: query
description: Fields to retrieve
required: false
style: deepObject
explode: true
schema:
type: array
items:
type: string
enum:
- time_limit
- date_start
- date_end
- question_page_limit
- is_print_screen
- $ref: '#/components/parameters/filter_id'
- $ref: '#/components/parameters/filter_response_id'
- $ref: '#/components/parameters/filter_created_at_from'
- $ref: '#/components/parameters/filter_created_at_to'
responses:
'200':
description: list of response tests
content:
application/json:
schema:
properties:
_total_items:
type: integer
_page:
type: integer
_page_count:
type: integer
_links:
properties:
self:
type: object
properties:
href:
type: string
format: uri
next:
type: object
properties:
href:
type: string
format: uri
last:
type: object
properties:
href:
type: string
format: uri
type: object
_embedded:
type: object
properties:
vacancy_videointerviews:
type: array
items:
allOf:
- $ref: '#/components/schemas/Test'
- type: object
properties:
_embedded:
type: object
properties:
questions:
type: array
items:
allOf:
- $ref: '#/components/schemas/TestQuestion'
- type: object
properties:
_embedded:
type: object
properties:
answers:
type: array
items:
allOf:
- $ref: '#/components/schemas/TestAnswer'
- type: object
properties:
_embedded:
type: object
properties:
candidate_answers:
type: array
items:
$ref: '#/components/schemas/TestCandidateAnswer'
media:
$ref: '#/components/schemas/TestQuestionMedia'
type: object
/api/v3/tests/response/{id}:
get:
description: Get response tests list
tags:
- test
parameters:
- name: id
in: path
description: Id
required: true
schema:
type: integer
- name: with[]
in: query
description: Relations to retrieve
required: false
schema:
type: array
items:
type: string
enum:
- questions
- questions.answers
- questions.media
- screenshots
- result
- questions.answers.candidateAnswers
- name: fields[]
in: query
description: Fields to retrieve
required: false
style: deepObject
explode: true
schema:
type: array
items:
type: string
enum:
- time_limit
- date_start
- date_end
- question_page_limit
- is_print_screen
responses:
'200':
description: Response test
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/Test'
- type: object
properties:
_embedded:
type: object
properties:
questions:
type: array
items:
allOf:
- $ref: '#/components/schemas/TestQuestion'
- type: object
properties:
_embedded:
type: object
properties:
answers:
type: array
items:
allOf:
- $ref: '#/components/schemas/TestAnswer'
- type: object
properties:
_embedded:
type: object
properties:
candidate_answers:
type: array
items:
$ref: '#/components/schemas/TestCandidateAnswer'
media:
$ref: '#/components/schemas/TestQuestionMedia'
components:
parameters:
filter_id:
name: filter[id]
in: query
required: false
schema:
oneOf:
- type: integer
- type: array
items:
type: integer
filter_created_at_to:
name: filter[created_at][to]
in: query
required: false
schema:
type: string
format: date-time
pagination_page:
name: page
in: query
description: page number
required: false
schema:
type: integer
default: 1
filter_created_at_from:
name: filter[created_at][from]
in: query
required: false
schema:
type: string
format: date-time
filter_response_id:
name: filter[response_id]
in: query
required: false
schema:
oneOf:
- type: integer
- type: array
items:
type: integer
filter_vacancy_id:
name: filter[vacancy_id]
in: query
required: false
schema:
oneOf:
- type: integer
- type: array
items:
type: integer
pagination_page_size:
name: limit
in: query
description: page size
required: false
schema:
type: integer
default: 20
schemas:
VacancyTestQuestionMedia:
properties:
id:
type: integer
vacancy_module_test_question_id:
type: integer
url:
type: string
format: uri
type:
type: string
title:
type: string
is_separate_page:
type: boolean
type: object
TestQuestion:
properties:
id:
type: integer
date_start:
type: string
format: date-time
nullable: true
date_end:
type: string
format: date-time
nullable: true
response_test_id:
type: integer
title:
type: string
body:
type: string
type:
type: string
time_limit:
type: integer
has_valid_answer:
type: boolean
is_graph_enabled:
type: boolean
is_variables_enabled:
type: boolean
sort_order:
type: integer
original_sort_order:
type: integer
type: object
VacancyTestQuestionVariable:
properties:
id:
type: integer
vacancy_module_test_question_id:
type: integer
name:
type: string
formula:
type: string
min:
type: number
max:
type: number
step:
type: number
chart_config:
type: object
type:
type: integer
enum:
- 1
- 2
description: '1 - Integer
2 - Float
'
type: object
TestQuestionMedia:
properties:
id:
type: integer
response_test_question_id:
type: integer
url:
type: string
format: uri
type:
type: string
title:
type: string
is_separate_page:
type: boolean
is_seen:
type: boolean
is_played:
type: boolean
is_blocked:
type: boolean
date_seen:
type: string
format: date-time
nullable: true
date_played:
type: string
format: date-time
nullable: true
type: object
TestCandidateAnswer:
properties:
id:
type: integer
response_test_answer_id:
type: integer
body:
type: string
date_created:
type: string
format: date-time
nullable: true
type: object
Test:
properties:
id:
type: integer
response_id:
type: integer
active:
type: boolean
name:
type: string
description:
type: string
nullable: true
created_at:
type: string
format: date-time
type: object
TestAnswer:
properties:
id:
type: integer
response_test_question_id:
type: integer
body:
type: string
sort_order:
type: integer
valid:
type: boolean
type: object
VacancyTestQuestion:
properties:
id:
type: integer
date_created:
type: string
format: date-time
vacancy_module_test_id:
type: integer
rounding_precision:
type: integer
title:
type: string
body:
type: string
type:
type: string
time_limit:
type: integer
time_limit_enabled:
type: boolean
has_valid_answer:
type: boolean
is_graph_enabled:
type: boolean
is_variables_enabled:
type: boolean
sort_order:
type: integer
type: object
VacancyTest:
properties:
id:
type: integer
vacancy_id:
type: integer
date_created:
type: string
format: date-time
time_limit:
type: integer
question_shuffle:
type: integer
answer_shuffle:
type: boolean
question_limit:
type: integer
question_page_limit:
type: integer
time_limit_enabled:
type: integer
required_score:
type: integer
calculate_test_status:
type: boolean
is_dropout_enabled:
type: boolean
is_camera_required:
type: boolean
type: object
VacancyTestAnswer:
properties:
id:
type: integer
date_created:
type: string
format: date-time
vacancy_module_test_question_id:
type: integer
body:
type: string
sort_order:
type: integer
valid:
type: boolean
is_formula:
type: boolean
type: object
securitySchemes:
bearerAuth:
type: http
scheme: bearer
bearerFormat: token