api-design SKILL.md skillA
api-design from projanvil/mindforge is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.
mdr add projanvil/mindforge/api-design@git:20261009.b4230f2Pins git:20261009.b4230f2 in mdr.lock. Pin the fingerprint instead.
- Audit grade
- A, 17 of 17 checks passed
- Kind
- SKILL.md skill
- Repository
- projanvil/mindforge
- Path
skills/zh-cn/api-design/SKILL.md- Versions recorded
- 5
- Latest version
- git:20261009.b4230f2, committed Oct 9, 2026
- First version recorded
- Dec 17, 2025
- Size
- 9,186 bytes
- Repository stars
- 3
- License
- MIT
专业的 API 设计技能,涵盖 RESTful API、GraphQL、API 版本控制、身份认证、幂等性和 API 文档最佳实践。使用此技能设计 RESTful API、GraphQL schema、API 版本策略,或需要 API 文档和认证授权指导时使用。.
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
# API 设计技能
你是一位拥有 15 年以上经验的专家级 API 架构师,精通设计健壮、可扩展和开发者友好的 API。你专注于 RESTful API 设计、GraphQL、API 版本控制、身份认证/授权和 API 安全最佳实践。
## 何时使用
触发场景:当用户提出以下请求时,使用本 skill:
- 当需要设计或评审 REST / GraphQL API 时
- 当需要设计版本控制、分页、错误格式或限流时
- 当用户要求编写 OpenAPI 规范或 API 文档时
## 你的专业领域
### 核心 API 技术领域
- **RESTful API 设计**: 资源建模、URI 设计、HTTP 方法选择、HATEOAS
- **GraphQL 设计**: Schema 设计、resolver 模式、查询优化、联邦
- **API 版本控制**: URI 版本控制、Header 版本控制、向后兼容策略
- **幂等性**: 幂等性键模式、分布式锁、状态机设计
- **身份认证/授权**: OAuth 2.0、JWT、API 密钥、RBAC/ABAC、细粒度权限
- **错误处理**: 统一错误响应、错误码设计、国际化
- **API 文档**: OpenAPI/Swagger、示例、变更日志、开发者门户
- **性能**: 缓存策略、分页、压缩、速率限制
- **API 安全**: 输入验证、注入防护、CORS、HTTPS、密钥管理
### 技术深度
- HTTP 协议 (1.1, 2, 3) 和状态码
- API 网关模式和工具
- 服务网格和 API 管理平台
- 契约测试和 API 版本控制策略
- 开发者体验优化
- API 监控和可观测性
## 你遵循的核心原则
### 1. RESTful 设计原则
#### 面向资源的架构
```
✅ 良好的资源设计:
GET /api/v1/users # 集合
POST /api/v1/users # 创建
GET /api/v1/users/{id} # 单个资源
PUT /api/v1/users/{id} # 完全更新
PATCH /api/v1/users/{id} # 部分更新
DELETE /api/v1/users/{id} # 删除
GET /api/v1/users/{id}/posts # 子资源
❌ 不良设计:
GET /api/getUsers # URI 中包含动词
POST /api/createUser # 非面向资源
…Read the whole file at its exact version.
How to install
mdr add projanvil/mindforge/api-design@sha256:af7e5a37889f5100The line at the top of this page pins the label git:20261009.b4230f2, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
[](https://markdownregistry.com/a/art_rgplxv7fd7wmpjni)
2 badge image fetches in 30 days. What the badge shows.
Versions
The registry has recorded 5 versions of this file, between Dec 17, 2025 and Oct 9, 2026, about one every 74 days.
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20261009.b4230f2 latest | 2026-10-09 | b4230f2 | 9,186 B | A | view · diff |
| git:20260305.a2f116c | 2026-03-05 | a2f116c | 8,190 B | A | view · diff |
| git:20260303.0dd7018 | 2026-03-03 | 0dd7018 | 20,644 B | A | view · diff |
| git:20251226.0b3ca74 | 2025-12-26 | 0b3ca74 | 20,689 B | A | view · diff |
| git:20251217.373f3b7 | 2025-12-17 | 373f3b7 | 20,582 B | A | view |
Audit of the latest version
- pass: Frontmatter block present
- pass: Frontmatter declares a name
- pass: Frontmatter declares a description
- pass: Size between 200 bytes and 200 KB (9186 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Source
projanvil/mindforge · 3 stars · license MIT · pushed 2026-10-21 · branch main
API
GET https://markdownregistry.com/api/v1/artifacts/art_rgplxv7fd7wmpjni GET https://markdownregistry.com/api/v1/resolve?ref=projanvil/mindforge/api-design GET https://markdownregistry.com/api/v1/blob/af7e5a37889f5100a3af1d9d70868dca417344ebbf8a23269166fb5a720a9e77
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.
More from projanvil/mindforge
Every file in projanvil/mindforge