hashgraph-online/awesome-codex-plugins / plugins/Colin4k1024/tsp/skills/api-contract
api-contract
Verified统一接口协议、请求响应、错误码、兼容性与上下游协作约束。 当架构师、前后端开发或 QA 需要锁定 API 合同时使用。
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 1.0 KB |
| agents/openai.yaml | config | 213 B |
SKILL.md
View on GitHub---
name: api-contract
description: >
统一接口协议、请求响应、错误码、兼容性与上下游协作约束。
当架构师、前后端开发或 QA 需要锁定 API 合同时使用。
---
# API Contract
## 用途
- 定义或审阅接口契约,避免“实现先行、契约滞后”。
- 对齐请求响应、鉴权、兼容性与错误处理。
## 默认做法
1. 使用 [api-contract.md](../../templates/api-contract.md) 固定接口定义。
2. 记录调用方、鉴权要求、错误码和兼容策略。
3. 若契约以 OpenAPI 形式维护,先结合 [api-lint-gates](../../docs/runbooks/api-lint-gates.md) 校验规范与结构,再用 [api-breaking-change-gates](../../docs/runbooks/api-breaking-change-gates.md) 做兼容性比对。
4. 若接口存在明确的 consumer/provider 边界,且需要把行为约定做成可执行验证,再结合 [contract-testing-playbook](../../docs/runbooks/contract-testing-playbook.md) 规划 pact 或 provider verification。
5. 指明需要同步给前端、后端、QA 的关键信息。
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 197k | Updated | Claude CodeCodex | Verified | Install |