Repository navigation
docs(adr): 0017 support openapi-typescript and openapi-typesafe side by side - #73
Merged
Merged
Conversation
NoZiL
force-pushed
the
docs/adr-0015-two-generators
branch
from
November 8, 2026 18:18
70e5546 to
f889193
Compare
…by side openapi-typescript stopped receiving updates (openapi-ts/openapi-typescript#2874). Add openapi-typesafe as a second, opt-in generator stack: no helpers patch, TypeScript 5.4 to 7. openapi-typescript stays the default until openapi-ts links to the fork (#67). Supersedes 0012, amends 0005. Work: #68 codegen, #69 runtime, #70 TS matrix, #71 docs. Co-Authored-By: Claude Opus 5.5 <[email protected]>
NoZiL
force-pushed
the
docs/adr-0015-two-generators
branch
from
November 8, 2026 18:19
f889193 to
90ede32
Compare
3 of 4 tasks
NoZiL
added a commit
that referenced
this pull request
Nov 13, 2026
) ## What and why Records the outcome of the #124 spike as ADR 0027 (status: **accepted** after review). Recommendation: support Hey API (`@hey-api/openapi-ts`) as a **third, opt-in, experimental** stack. Don't replace either existing stack, because Hey API's calling style is different. It amends ADR 0017. ADR 0003 (gating) holds as written: the Hey API path keeps `$api` / `$gated` + `gate()` / `<Feature>`. Evidence: branch [`try/hey-api`](https://github.com/NoZiL/openapi-versions/tree/try/hey-api/spike/hey-api) (`spike/hey-api/`, not for merging), with the generated output committed. - Open enums: `$resolvers` on `@hey-api/typescript`. Every `enum-shapes` fixture matches openapi-typescript, and no helpers patch is needed. - Core/gated split and the op-ID → op-key map are read from Hey API's IR and symbol registry (Hey API's own naming, e.g. `delete` → `delete_`). - `gate()` reads `queryKey[0]._id`. X-Api-Version and Sunset come through a response interceptor. - Copies of `test/types.check.ts` type-check on TS 5.4, 5.5, 6.0 and 7.0.2, and copies of the `test/react.test.tsx` scenarios pass (6 tests). Risks in the ADR: 0.x with no stable release since 2026-06-22; TS 7 breaks generation on 0.99.0 (hey-api/hey-api#4235, fixed in `@next`); two undocumented internals; output must go in `v<n>/sdk/` because of a `client` name collision. Closes #124 ## Checklist - [x] `mise run check` passes (what CI runs). Docs-only: ran `pnpm lint`; CI runs the rest - [ ] `pnpm changeset` added for any change to the published package. Not needed: ADR only, same as #73 for ADR 0017 - [x] Generated output was not edited by hand (`playground/generated`, `test/fixtures/generated`) - [x] ADR added or superseded in `docs/adr/` if this touches a trigger in `AGENTS.md` 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ADR 0017: support openapi-typescript and openapi-typesafe side by side.
openapi-typescript stopped receiving updates on 2026-09-19 (openapi-ts/openapi-typescript#2874). Because of that, our helpers patch (ADR 0005) is now permanent for consumers, and TypeScript 6 and 7 support (#52, #46) will never come through it.
Docs only. This PR has no code changes. The implementation is tracked in #68 (codegen), #69 (runtime), #70 (TS matrix) and #71 (docs).
Evidence
Trial on the local branch
try/openapi-typesafe(not for merge): openapi-typesafe 1.0.0-rc.3 replaced all four packages viaopenapi-typesafe-migrate. With the patch removed, codegen, typecheck, all 41 tests and the oasdiff gate pass, includingtypes.check.tscheck 4 (open enums keep their type).Test plan
pnpm lintsuperseded by 0015🤖 Generated with Claude Code