diff --git a/frontend/docs/api-contract/openapi.yaml b/frontend/docs/api-contract/openapi.yaml index 77a0d53a..35cfea16 100644 --- a/frontend/docs/api-contract/openapi.yaml +++ b/frontend/docs/api-contract/openapi.yaml @@ -2,7 +2,7 @@ openapi: 3.1.0 info: title: TextMachine API - version: 0.2.0 + version: 0.2.1 summary: Ratified contract between the frontend and the TextMachine platform (D39.99). description: | **RATIFIED contract (D39.99, 04.08.2026).** The canonical copy lives in @@ -344,6 +344,7 @@ paths: '401': { $ref: '#/components/responses/Unauthorized' } '404': { $ref: '#/components/responses/NotFound' } '409': { $ref: '#/components/responses/Conflict' } + '503': { $ref: '#/components/responses/ServiceUnavailable' } /runs/{runId}/events: parameters: @@ -605,6 +606,14 @@ components: content: application/problem+json: schema: { $ref: '#/components/schemas/Problem' } + ServiceUnavailable: + description: | + The deployment cannot perform this action right now (added in 0.2.1, D39.123): starting a + run requires the engine seam to be fully configured, and answering with any other code + would misname the state. Temporary by nature — retry later; no Retry-After is promised. + content: + application/problem+json: + schema: { $ref: '#/components/schemas/Problem' } schemas: Id: diff --git a/frontend/docs/frontend-PROGRESS.md b/frontend/docs/frontend-PROGRESS.md index 17aacb6b..aca14724 100644 --- a/frontend/docs/frontend-PROGRESS.md +++ b/frontend/docs/frontend-PROGRESS.md @@ -1008,3 +1008,16 @@ RAC — строка Ф-18; резать его осмысленно после чужого не задело. Запрет «никакого `checkout` поверх грязного дерева» (`CLAUDE.md`) существует ровно для этого случая и относится к своим файлам тоже. Пробу отката делать копией (`cp` до, `cp` после), а не через git. + +## Пинг оркестратора №15 (09.08): контракт 0.2.1 — `503` на старте прогона; платформа-раннер заленден + +- **Контракт бампнут 0.2.0 → 0.2.1** (D39.123): `POST /books/{bookId}/runs` получил ответ **`503`** + (`ServiceUnavailable`, problem+json) — старт прогона на деплое, где шов движка не сконфигурирован; + временное состояние, ретрай позже, `Retry-After` не обещан. Зеркало `frontend/docs/api-contract/` + синхронизировано байт-в-байт этим же лендингом. При следующей сессии — перегенерировать типы из + спеки; других изменений форм нет, правка аддитивная. +- **Платформа-раннер заленден** (`d29e30c`): пять ручек `/v0` контракта живые — библиотека · + карточка · run-options · старт прогона · usage; прогресс прогона пофазный (draft/edit) в карточке. + Фронт может говорить с живой платформой вместо моков — стык проверен 47 wire-проверками приёмки. +- Известное ограничение до эмиттера (строка 103): стоп по потолку и штатный останов приезжают как + `failed` (PD-113/двойник) — на экране не строить различение этих состояний до строки 165 движка. diff --git a/frontend/src/api/schema.ts b/frontend/src/api/schema.ts index 9a106a1a..57b2ff56 100644 --- a/frontend/src/api/schema.ts +++ b/frontend/src/api/schema.ts @@ -1014,6 +1014,19 @@ export interface components { "application/problem+json": components["schemas"]["Problem"]; }; }; + /** + * @description The deployment cannot perform this action right now (added in 0.2.1, D39.123): starting a + * run requires the engine seam to be fully configured, and answering with any other code + * would misname the state. Temporary by nature — retry later; no Retry-After is promised. + */ + ServiceUnavailable: { + headers: { + [name: string]: unknown; + }; + content: { + "application/problem+json": components["schemas"]["Problem"]; + }; + }; }; parameters: { /** @description Opaque book identifier. */ @@ -1384,6 +1397,7 @@ export interface operations { 401: components["responses"]["Unauthorized"]; 404: components["responses"]["NotFound"]; 409: components["responses"]["Conflict"]; + 503: components["responses"]["ServiceUnavailable"]; }; }; streamRunEvents: {