rest2ts

JSON →
library 6.3.5 ·javascript
verified Jun 7, 2026

A CLI tool and library that generates modern TypeScript types and strongly-typed HTTP clients from REST API schemas (Swagger/OpenAPI 2.x/3.x). v6.3.5 is current stable; releases weekly. Key differentiators: supports both Swagger and OpenAPI spec versions, produces zero-dependency TypeScript output with full type safety, configurable client generation for fetch/axios/ky, and includes a watch mode for incremental codegen. Alternatives (e.g., openapi-generator) often produce larger output files with more boilerplate or require heavier runtimes.