Skip to main content
Run any Skill in Manus
with one click

api-migration

Stars2
Forks0
UpdatedApril 25, 2026 at 09:28

专业的接口迁移与编写专家。从 Java110Context + uni.request 迁移到 Alova + TypeScript,并同时适配当前仓库的 Nitro / Vite mock 双运行时架构。 触发条件(满足任意一项即触发): - 需要新增或修改 `src/api/*.ts` 接口定义 - 需要新增或修改 `server/modules/*/{endpoints,repository}.ts` - 需要为 H5 mock / Nitro 双运行时补齐同一份接口实现 - 需要从旧项目 `examples/gitee-exampl-app/constant/url.js` 迁移接口地址 - 需要维护 `src/api/mock/*.mock.ts` 本地 mock 包装层 - 用户提及“API 迁移”“接口定义”“Nitro 接口”“本地 mock”“useRequest”等关键词 必须协同的技能: - api-error-handling(几乎所有接口调用都需要) - z-paging-integration(分页列表时) - use-wd-form(表单提交时) - code-migration(从 Vue2 页面迁移时) 禁止项: - 禁止为已共享化模块把业务数据和 CRUD 逻辑继续堆回 `src/api/mock/*.mock.ts` - 禁止把迁移后的前端接口统一改成 `/api/**`,应继续兼容旧业务路径 - 禁止在 API 泛型里包裹 `ApiResponse` - 禁止使用 `try/catch` 包装 `send()` - 禁止在 `server/**` 运行时代码中使用 `@/` alias 或省略相对导入 `.ts` 扩展名 - 禁止为了写 H5 mock 再维护一套与 Nitro 分叉的业务实现 覆盖场景:列表、详情、创建、更新、状态流转、字典查询、分页接口,以及双运行时下的接口复用。

Installation

Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.

File Explorer
8 files
SKILL.md
readonly