What problem does it solve?
Poorly designed APIs create significant maintenance burden, break consumer trust with unexpected breaking changes, and lead to inconsistent error handling, naming, and pagination that frustrate developers and cause integration failures. This Skill eliminates those issues by providing language-agnostic, industry-vetted principles for building APIs that are intuitive, stable, and easy to consume.
Core Features & Use Cases
- Contract-First Design: Define OpenAPI, protobuf, or GraphQL schemas before writing implementation to avoid leaking internal details and ensure the API matches consumer needs.
- Backward Compatibility & Versioning: Safely evolve APIs without breaking existing consumers, with clear deprecation policies and automated compatibility checks.
- Standardized Error Handling & Pagination: Implement RFC 7807 Problem Details for consistent, actionable errors, and cursor-based pagination for stable performance with large or changing datasets.
- Language-Specific Idioms: Reference implementations for C++, Java, Python, and Rust that align with each ecosystem's best practices for routing, validation, and error handling.
- Use Case: When building a new public REST API for user management, use this Skill to define the contract first, enforce consistent
/users resource naming, implement RFC 7807 error responses, and add idempotency keys for order creation endpoints to prevent duplicate charges.
Quick Start
Use the api-design skill to review your existing /products API endpoint for backward compatibility issues, incorrect HTTP status code usage, and missing pagination support for large product catalogs.