From bd399607935d265b2403cabb6c8cfedb5ff10019 Mon Sep 17 00:00:00 2001 From: Matt Miller Date: Fri, 22 May 2026 14:24:20 -0700 Subject: [PATCH] openapi: align asset download/export 202 status enum with runtime + sibling schemas MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit CodeRabbit caught a vocabulary mismatch: the two new 202 response schemas declared `[pending, running, completed, failed]` while the rest of the same spec uses `[created, running, completed, failed]` for the identical task lifecycle (download/export progress WebSocket events, /api/tasks, TaskEntry, TaskResponse — 4 sites total). Cloud's runtime emits `created` on initial creation (AssetDownloadResponseStatusCreated; task.Status sourced from the DB enum whose initial value is Created). `pending` would have introduced a fifth, contradictory vocabulary for the same lifecycle and pushed the spec further from the implementation it is meant to align with. Followup tracked separately: extract a shared TaskStatus enum so all five sites move in lockstep instead of needing per-site edits. --- openapi.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openapi.yaml b/openapi.yaml index c6e581bce..8fb769bc8 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -2358,8 +2358,8 @@ paths: description: ID of the download task; use to poll status. status: type: string - enum: [pending, running, completed, failed] - description: Current task status (typically `pending` on initial creation). + enum: [created, running, completed, failed] + description: Current task status (typically `created` on initial creation). message: type: string description: Human-readable task message. @@ -2418,8 +2418,8 @@ paths: description: ID of the export task; use to poll status. status: type: string - enum: [pending, running, completed, failed] - description: Current task status (typically `pending` on initial creation). + enum: [created, running, completed, failed] + description: Current task status (typically `created` on initial creation). message: type: string description: Human-readable task message.