Comfy-Org / Comfy-Org/ComfyUI_frontend

Evaluate OpenAPI generation for excluded Python backend endpoints

Open
#10,672 0 comments 0 reactions 1 assignee Claimed by @dante01yoon View on GitHub
Public API
Dominant language
TypeScript
Stars
2k
Forks
699
Avg merge
1d 7h
Merged PRs (30d)
490

Description

Follow-up from #10668.

`packages/ingest-types/openapi-ts.config.ts` excludes endpoints that overlap with the ComfyUI Python backend:

- `/api/prompt`, `/api/queue`, `/api/history`, `/api/object_info`
- `/api/features`, `/api/settings`, `/api/system_stats`
- `/api/jobs`, `/api/upload/*`, `/api/view`

These are currently typed via manual Zod schemas in `src/schemas/apiSchema.ts`. The manual schemas work but can drift from the OpenAPI spec without warning.

- [ ] Audit whether the OpenAPI definitions for these endpoints match the manual Zod schemas
- [ ] If they match, evaluate generating types for these endpoints into a separate package (e.g. `@comfyorg/backend-types`) while keeping the runtime Zod validation in `apiSchema.ts`
- [ ] If they don't match, document the discrepancies and decide which is authoritative

Parent: #10656

┆Issue is synchronized with this [Notion page](https://www.notion.so/Issue-10672-Evaluate-OpenAPI-generation-for-excluded-Python-backend-endpoints-3316d73d365081828eb2ddb01d9bf131) by [Unito](https://www.unito.io)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.