Проверка репорта
POST /v1/reports/{report_id}/review
POST /v1/reports/{report_id}/review
Только подтверждённая сессия сотрудника, чей ID явно указан в FEEDBACK_REVIEWERS. Владельцы и администраторы пространства, API-ключи и внешние OAuth-клиенты не могут утверждать исправления. При принятии заново проверяются идентичность и хеш доверенной записи; требуются типизированные изменения условий, которые добавляются в неизменяемую историю. Изменившаяся запись возвращает 409 и needs_revalidation. Отклонение и запрос уточнения не меняют источник. Запросы проверки идемпотентны.
Доступ
Требуется bearer-авторизация. Описание операции задаёт дополнительные права, роли и ограничения для сессий кабинета. Сам по себе API-ключ их не предоставляет.
Параметры
| Поле | Тип | Обязательно | Описание |
|---|---|---|---|
report_id (path) | string | да |
Тело запроса
| Поле | Тип | Обязательно | Описание |
|---|---|---|---|
decision | "accepted" ∣ "rejected" ∣ "needs_information" | да | |
rationale | string | да | |
idempotency_key | string | да | |
patch | CorrectionPatch ∣ null | нет |
Полная схема: ReportReview
{
"properties": {
"decision": {
"type": "string",
"enum": [
"accepted",
"rejected",
"needs_information"
],
"title": "Decision"
},
"rationale": {
"type": "string",
"maxLength": 2000,
"minLength": 10,
"title": "Rationale"
},
"idempotency_key": {
"type": "string",
"maxLength": 128,
"minLength": 8,
"pattern": "^[A-Za-z0-9_.:-]+$",
"title": "Idempotency Key"
},
"patch": {
"anyOf": [
{
"$ref": "#/components/schemas/CorrectionPatch"
},
{
"type": "null"
}
]
}
},
"additionalProperties": false,
"type": "object",
"required": [
"decision",
"rationale",
"idempotency_key"
],
"title": "ReportReview"
}Ответы
| HTTP | Описание | Тип |
|---|---|---|
| 200 | Успешный ответ | application/json: ObservationReport |
| 401 | Требуется авторизация | application/problem+json: ProblemDetails |
| 403 | Доступ запрещён | application/problem+json: ProblemDetails |
| 404 | Не найдено | application/problem+json: ProblemDetails |
| 409 | Конфликт | application/problem+json: ProblemDetails |
| 413 | Превышен размер запроса | application/problem+json: ProblemDetails |
| 422 | Ошибка входных данных | application/problem+json: ProblemDetails |
| 429 | Превышен лимит | application/problem+json: ProblemDetails |
| 502 | Ошибка шлюза | application/problem+json: ProblemDetails |
| 503 | Сервис недоступен | application/problem+json: ProblemDetails |
Ответ: ObservationReport
| Поле | Тип | Обязательно | Описание |
|---|---|---|---|
id | string | да | |
observation_id | string | да | |
category | "field_conflict" ∣ "stage_misattribution" ∣ "missing_source" ∣ "structure_mismatch" ∣ "other" | да | |
summary | string | да | |
evidence_quote | string ∣ null | нет | |
proposed_patch | CorrectionPatch ∣ null | нет | |
state | "pending" ∣ "accepted" ∣ "rejected" ∣ "needs_information" ∣ "needs_revalidation" | да | |
created_at | string | да | |
updated_at | string | да | |
reference | ReportReference | да | |
review | ReviewedDecision ∣ null | нет | |
correction | CorrectionVersion ∣ null | нет |
Полная схема
{
"properties": {
"id": {
"type": "string",
"title": "Id"
},
"observation_id": {
"type": "string",
"title": "Observation Id"
},
"category": {
"type": "string",
"enum": [
"field_conflict",
"stage_misattribution",
"missing_source",
"structure_mismatch",
"other"
],
"title": "Category"
},
"summary": {
"type": "string",
"title": "Summary"
},
"evidence_quote": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Evidence Quote"
},
"proposed_patch": {
"anyOf": [
{
"$ref": "#/components/schemas/CorrectionPatch"
},
{
"type": "null"
}
]
},
"state": {
"type": "string",
"enum": [
"pending",
"accepted",
"rejected",
"needs_information",
"needs_revalidation"
],
"title": "State"
},
"created_at": {
"type": "string",
"title": "Created At"
},
"updated_at": {
"type": "string",
"title": "Updated At"
},
"reference": {
"$ref": "#/components/schemas/ReportReference"
},
"review": {
"anyOf": [
{
"$ref": "#/components/schemas/ReviewedDecision"
},
{
"type": "null"
}
]
},
"correction": {
"anyOf": [
{
"$ref": "#/components/schemas/CorrectionVersion"
},
{
"type": "null"
}
]
}
},
"additionalProperties": true,
"type": "object",
"required": [
"id",
"observation_id",
"category",
"summary",
"state",
"created_at",
"updated_at",
"reference"
],
"title": "ObservationReport"
}Эта страница генерируется из OpenAPI. Примеры показывают схемы, а не вымышленные успешные ответы.