api-design
当用户要求"设计API"、"创建DTO"、"定义数据结构"、"API文档"、"请求响应格式",或者提到"API设计"、"数据传输对象"、"契约"、"接口"时使用此技能。用于 API 设计模式、数据建模、类型安全或后端 API 结构设计。
npx skills add majiayu000/claude-skill-registry --skill api-design-cacr92-wereply-2 --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# API Design Skill Expert guidance for designing robust, type-safe APIs and data structures in Tauri applications. ## Overview This skill provides guidance for: - Designing Tauri command APIs - Creating type-safe DTOs (Data Transfer Objects) - API documentation and contracts - Request/response patterns - Error handling in APIs - API versioning and evolution ## When This Skill Applies This skill activates when: - Creating new Tauri commands - Designing request/response DTOs - Planning API structure - Documenting API contracts - Refactoring existing APIs - Handling API versioning ## API Design Principles ### 1. Type Safety First **✓ Good: Explicit, typed structures** ```rust use serde::{Deserialize, Serialize}; use specta::Type; #[derive(Serialize, Deserialize, Type, Clone)] #[specta(inline)] pub struct CreateFormulaDto { /// Formula name (2-100 characters) #[serde(alias = "formulaName")] pub name: String, /// Species code (e.g., "pig", "chicken") #[serde(alias = "speciesCode")] pub species_code: String, /// Optional description pub description: Option<String>, /// Formula materials pub materials: Vec<FormulaMaterialDto>, } #[derive(Serialize, Deserialize, Type, Clone)] #[specta(inli
- Overview
- When This Skill Applies
- API Design Principles
- 1. Type Safety First
- 2. Consistent Naming Conventions
- 3. Validation at API Boundaries
- Request/Response Patterns
- Standard Response Format
- Paginated Response
- Error Handling Patterns
- Structured Error Types
- API Documentation
- Inline Documentation
- TypeScript Usage Documentation
What does the api-design skill do?
当用户要求"设计API"、"创建DTO"、"定义数据结构"、"API文档"、"请求响应格式",或者提到"API设计"、"数据传输对象"、"契约"、"接口"时使用此技能。用于 API 设计模式、数据建模、类型安全或后端 API 结构设计。
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill api-design-cacr92-wereply-2 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
