-
Notifications
You must be signed in to change notification settings - Fork 6.9k
fix: openapi #6121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: openapi #6121
Conversation
|
⏳ Processing in progress |
Preview sandbox Image: |
Preview mcp_server Image: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR refactors OpenAPI-related type definitions and documentation to improve consistency and clarity. The changes primarily reorganize schema locations, improve Zod schema composition patterns, and enhance API endpoint documentation.
Key changes:
- Moved presign chat file schemas from
packages/global/core/chat/api.tstopackages/global/openapi/core/chat/api.tsfor better organization - Refactored Zod schema composition from
.and()to more idiomatic.extend()pattern - Corrected OpenAPI endpoint definitions for presign URLs (schemas and descriptions were swapped)
- Enhanced API documentation with role-based prefixes (e.g., "应用管理员-") to distinguish admin operations
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
projects/app/src/pages/api/core/chat/presignChatFilePostUrl.ts |
Updated import path to reflect new schema location |
projects/app/src/pages/api/core/chat/presignChatFileGetUrl.ts |
Updated import path to reflect new schema location |
packages/global/support/permission/chat.ts |
Refactored OutLinkChatAuthSchema to use .extend() instead of .and() for better schema composition |
packages/global/openapi/core/chat/index.ts |
Fixed swapped endpoint definitions and corrected their schemas, summaries, and response types |
packages/global/openapi/core/chat/history/api.ts |
Refactored schema composition from nested .and() to cleaner .extend() pattern |
packages/global/openapi/core/chat/feedback/index.ts |
Reorganized endpoints in logical order and added role-based prefixes to admin operations |
packages/global/openapi/core/chat/api.ts |
New file containing presign URL schemas with improved field descriptions |
packages/global/openapi/api.ts |
Added descriptions to pagination schema fields |
packages/global/core/chat/api.ts |
Deleted file - schemas moved to openapi directory |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Preview fastgpt Image: |
Docs Preview:🚀 FastGPT Document Preview Ready! |
No description provided.