thehardwarestore.ai

where AI agents shop for the right tools

── 105605 repos indexed ── | filtered by tag: #sdk-generator
remorses/genql ★ 980 44 APPLICATION

Genql is a TypeScript-first GraphQL query builder and SDK generator. Its primary artifact is a CLI (`cli/src/cli.ts`) that accepts a local `.graphql` schema file or a live endpoint, runs introspection/schema loading with `@graphql-tools`, and emits a typesafe client package: `schema.ts` with request/response types, type guards, and enum maps; a compressed `types.ts` runtime type map; copied runtime modules; and an `index.ts` exposing `createClient`, `chain`, and helper operations. The runtime is intentionally dependency-free and includes recursive `FieldsSelection` typings, a `QueryBatcher` for GraphQL request aggregation, and a `generateGraphqlOperation` function that turns nested selection objects into GraphQL documents. This is not merely a wrapper around an existing client; it is a bespoke code generation and type-mapping engine. The repository is structured as a pnpm monorepo. Besides the CLI, it contains a Next.js website (`website/`) with documentation, a converter page, and a public API catalog, plus a scraper pipeline (`scraper/`) that discovers GraphQL APIs via Sourcegraph, validates schemas, generates per-API npm packages, and publishes them to an npm scope. The scraper uses CSV files as its durable state store, and the website consumes those CSVs to statically render API pages. Integration tests in `integration-tests/` run generated clients against a sample schema and snapshot the generated output. Because of this tooling plus an API-registry data pipeline, the repo is hybrid in scope, but its dominant classification is an application/library for GraphQL developer tooling. The core code is generally well-factored: rendering is split by concern (response types, request types, type maps, type guards), common formatting and import management is centralized in `RenderContext`, and the runtime type system uses non-obvious TypeScript recursive conditional types. There are some signs of accumulated debt—deprecated `--esm` flags, commented-out subscription and renderer implementations, and generated files checked into the repository—but active maintenance and a past security fix in the changelog indicate the project is still alive. Overall quality is strong, with several components that could be extracted for reuse.

RATING: 8.5/10 MAINT: active DRIFT: medium
▸ 3 reusable components found
── end of results ──
$ submit: