generating-typescript-types-from-apis
Installation
SKILL.md
API Response → TypeScript Types
When to use this skill
- User asks to type an API response
- User has JSON and needs TypeScript interfaces
- User mentions OpenAPI or Swagger schemas
- User wants to generate types from endpoints
- User asks about keeping frontend/backend types in sync
Workflow
- Identify API source (JSON response, OpenAPI, endpoint)
- Parse response structure
- Generate TypeScript interfaces
- Handle nested objects and arrays
- Add JSDoc comments
- Export types to appropriate location