chore: sync vendored Comfy API v2 spec (cloud@04133db) - #40
Conversation
📝 WalkthroughWalkthroughThe OpenAPI specification updates deployment URL examples, documents deployment-specific errors and retry handling, defines host-relative follow-up URLs, and replaces legacy resource identifiers with UUID examples. ChangesOpenAPI contract updates
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@spec/openapi.yaml`:
- Around line 902-913: Add deployment_stopped to the POST /api/v2/jobs
operation-level 422 response contract, alongside invalid_workflow,
workflow_format_ui, missing_asset, and idempotency_key_reuse, or reference a
deployment-specific 422 response. Keep the existing error codes and response
behavior unchanged.
- Line 846: Replace the truncated example under Output.id with a complete, valid
UUID string, preserving its role as the documented asset UUID example.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: aaecf88a-10d1-439a-bd1d-97f9aed56563
📒 Files selected for processing (1)
spec/openapi.yaml
| type: string | ||
| description: Asset UUID. | ||
| example: asset_01JZV9R4N8... | ||
| example: 9f8a1c0d-2b3e-4f56-... |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win
Use a complete UUID for Output.id.example.
The value contains ... and is not a valid UUID, although Output.id is documented as an asset UUID. OpenAPI tooling or generated test data can reject this example.
Proposed correction
- example: 9f8a1c0d-2b3e-4f56-...
+ example: 9f8a1c0d-2b3e-4f56-8a7b-1c2d3e4f5a6b📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| example: 9f8a1c0d-2b3e-4f56-... | |
| example: 9f8a1c0d-2b3e-4f56-8a7b-1c2d3e4f5a6b |
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@spec/openapi.yaml` at line 846, Replace the truncated example under Output.id
with a complete, valid UUID string, preserving its role as the documented asset
UUID example.
| Deployment-scoped surfaces add: `deployment_not_ready` (429 + | ||
|
|
||
| Retry-After — the deployment can still reach ready; retry) and | ||
|
|
||
| `deployment_stopped` (422 — terminal deployment state; a retry | ||
|
|
||
| cannot succeed without operator action). A 429 is disambiguated | ||
|
|
||
| by `error.code` alone; clients should treat any 429 + Retry-After | ||
|
|
||
| as "back off and retry". | ||
|
|
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win
Add deployment_stopped to the operation-level 422 contract.
ErrorEnvelope now documents deployment_stopped as a deployment-scoped 422, but the POST /api/v2/jobs response at Line 391 still lists only invalid_workflow, workflow_format_ui, missing_asset, and idempotency_key_reuse. The operation documentation is incomplete for deployment-scoped servers.
Add deployment_stopped to that 422 response description or define a deployment-specific 422 response.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@spec/openapi.yaml` around lines 902 - 913, Add deployment_stopped to the POST
/api/v2/jobs operation-level 422 response contract, alongside invalid_workflow,
workflow_format_ui, missing_asset, and idempotency_key_reuse, or reference a
deployment-specific 422 response. Keep the existing error codes and response
behavior unchanged.
Automated sync of the public Comfy API v2 spec, projected from the
canonical contract (internal notes stripped, all component schemas
kept). Source:
cloud@04133db.This PR is on its own per-source-commit branch
(
chore/sync-v2-spec-04133db); a laterspec change opens a separate PR and will not touch this branch, so a
regen commit pushed here is safe.
Action required before merge: regenerate the low layer and commit
the result so the spec-drift check passes —
Summary by CodeRabbit