GraphQL Schema TypeScript Generator

JSON →
library 1.6.1 ·javascript
verified May 27, 2026

graphql-schema-typescript is a utility library for generating TypeScript type definitions directly from GraphQL schema definitions. Unlike client-side code generators such as Apollo-codegen, which focus on types for client queries, this library's primary purpose is to produce type-safe interfaces for GraphQL server-side development, specifically for writing resolvers. The current stable version is 1.6.1. While there isn't a strict release cadence, the project is actively maintained with recent updates to support newer GraphQL versions. Key differentiators include a 1-to-1 mapping from GraphQL types to TypeScript interfaces, conversion of GraphQL descriptions to JSDoc comments, and specialized types for resolver arguments, parent objects, and return values (e.g., `GQLResolver`, `RootQueryToUsersArgs`, `RootQueryToUsersResolver`). It offers both a programmatic API and a command-line interface (CLI) for integration into build workflows, supporting `.gql` and `.graphqls` schema file extensions.

total hits 19
actors 9 distinct systems
last hit 20h ago Bingbot
MetaBot
4
GPTBot
2
Script
2
ByteDance
2
Amazonbot
1
Search engines
2

top countries 🇺🇸 United States · 🇫🇷 France · 🇳🇴 Norway · 🇸🇬 Singapore · 🇨🇦 Canada