Response and errors
Response processing
Analyze the response's HTTP code first.
If the response code is 200
, check the status
field.
If the status is ok
, the request was a success. See more in data
.
HTTP response codes
200
: Correct request, check status
.
422
: Request error. See more in error.description
:
request_body_validation_error
– Error in the request bodyrequest_header_validation_error
–x-partner-project
header is missing
500
– Error on Bank 131's side. Please send the request again later.
Status
Response statuses are passed in the status
field.
ok
: Request processed successfully. See more in data
.
pending
: Request is being processed. To find out the result, send the same request later.
error
: Request processing error. See more in error
.
Error codes
Errors are passed in error
:
code
– an error codedescription
– an error description
Code | Description | What you can do |
---|---|---|
invalid_sign | Запрос с указанным идентификатором подписан некорректно | Verify the check request signature is properly generated |
passport_validation_failure | По данным МДВ предоставленный паспорт признан недействительным | The passport is invalid. Check the passport data |
passport_validation_failure | В базе данных МВД отсутствуют сведения о предоставленном паспорте | No information about the passport was found. Check the passport data |
inn_validation_failure | По данным ФНС предоставленный паспорт не соответствует предоставленному ИНН | The INN value is not linked to the passport specified. Check the INN |
already_exists | Запрос на проверку с теми же данными был направлен ранее | You have already submitted these data for identification. To see the result, send a check{id} request with the previous verification's ID that you received in the data.id field |
request_not_found | Не найден запрос с указанным идентификатором | The request with the given ID was not found. Check the ID |
partner_project_not_found | Не найден проект с указанным в заголовке идентификатором | The project ID sent in the X-PARTNER-PROJECT header does not exist. Check the ID |
birthday_validation_failure | Возраст проверяемого лица ниже допустимого порога | The verified subject must be an adult. If you receive this error when working with a nominal account, contact your manager |
validation_error | Request validation error. Example: 1 validation error for Request.body → payload → documents → 2 → expire_date. Document MIGRATION_CARD is expired (type=value_error) | Invalid formats and/or controls in values. For detailed information see the description field |
Response examples
- Invalid passport
- No passport data
- INN and passport failed verification
{
"status": "error",
"error": {
"code": "passport_validation_failure",
"description": "По данным МДВ предоставленный паспорт признан недействительным"
}
}
{
"status": "error",
"error": {
"code": "passport_validation_failure",
"description": "В базе данных МВД отсутствуют сведения о предоставленном паспорте"
}
}
{
"status": "error",
"error": {
"code": "inn_validation_failure",
"description": "По данным ФНС предоставленный паспорт не соответствует предоставленному ИНН"
}
}