API Design Patterns

0•

Guides architectural decision-making and best practices for modern API design, including REST, GraphQL, and tRPC.

This skill provides comprehensive guidance for designing robust, scalable, and secure APIs by focusing on first principles rather than rigid templates. It helps developers navigate the selection process between REST, GraphQL, and tRPC based on specific project needs while providing standardized patterns for response structures, versioning, and authentication. By integrating security audits and documentation best practices, it ensures that backend services are built with consistent naming conventions, proper error handling, and adherence to modern standards like the OWASP API Top 10.

Key Features

01Standardized response formatting, pagination, and error handling patterns
02Comprehensive authentication guidance for JWT, OAuth, and Passkeys
030 GitHub stars
04API evolution strategies including URI, Header, and Query versioning
05Protocol selection decision tree for REST, GraphQL, and tRPC
06Automated API endpoint validation via built-in script

Use Cases

01Architecting a new backend service and selecting the optimal communication protocol
02Refactoring existing endpoints to implement consistent pagination and error envelopes
03Performing a security audit on API endpoints to identify common vulnerabilities