API Design

Design REST/RPC endpoint contracts with TypeScript types and error handling.

1|1|Updated Feb 21, 2026
One-click install
npx skills add https://github.com/dtsong/claude-code-windows-setup --skill api-design-dtsong
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: API Design
Source: https://github.com/dtsong/claude-code-windows-setup/tree/main/skills/council/architect/api-design
Command: npx skills add https://github.com/dtsong/claude-code-windows-setup --skill api-design-dtsong

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill streamlines the creation of clear, consistent, and well-documented API contracts, ensuring seamless integration between frontend and backend services.

Core Features & Use Cases

  • Endpoint Contract Definition: Specifies request/response types, HTTP methods, and paths.
  • Type Generation: Produces TypeScript definitions for requests, responses, and shared types.
  • Error Handling Standardization: Designs a consistent error contract with application-level error codes.
  • Use Case: Design the API for a new user profile feature, defining endpoints for creating, reading, updating, and deleting user data, complete with TypeScript types and error codes.

Quick Start

Use the API Design skill to define the contract for a new user registration endpoint.

Frequently Asked Questions about API Design

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I define REST API contracts with TypeScript types and error handling?

Designing REST API contracts involves specifying endpoint paths, HTTP methods, and request/response types. This Skill generates TypeScript definitions and standardizes error handling with application-level error codes to ensure consistent inter-service communication.

What is the best way to standardize API error handling and versioning strategies?

Standardizing API error contracts requires defining consistent application-level error codes and versioning strategies. This Skill designs those error contracts and versioning mechanisms to ensure reliable inter-service communication during updates.

Can I design API authentication, pagination, and rate limits in the same contract?

Yes, you can define authentication, authorization, pagination, filtering, rate limits, and caching mechanisms within a single API contract. This Skill supports designing these operational mechanisms alongside standard endpoint request and response types.

Does this approach generate TypeScript definitions for both RPC and REST endpoints?

Yes, this approach generates TypeScript type definitions for both REST and RPC endpoint contracts. It produces shared types for requests and responses to facilitate clear inter-service communication and frontend integration.

How do I document API contracts for frontend and backend service integration?

Documenting API contracts requires generating clear specifications and TypeScript definitions for inter-service communication. This Skill produces the necessary endpoint documentation and shared types to streamline integration between frontend and backend services.