Releases: mnahkies/openapi-code-generator
v0.22.0
What's Changed
This is a pretty significant release, with two larger features:
- Support for Zod V4, whilst retaining support for Zod V3
- Support for projects using ESM, and use
import typewhere possible
Aside from this, we've made efforts to improve supply chain security 🔒
- Adopted trusted publishers / Github Actions to publish releases
- Added a minimum release age of 7 days for dependencies
- Removed unmaintained dependency
As well as improving the CI setup to run integration and e2e tests across more variants to reduce risk of regressions 🧪
⚠️ Breaking Changes
--schema-builderdefaults tozod-v4--schema-builderno longer acceptszod, you must specify eitherzod-v3orzod-v4as required for your project
Full changes
- feat: set minimumReleaseAge of 7 days by @mnahkies in #363
- chore: update biome by @mnahkies in #364
- chore: upgrade documentation related dependencies by @mnahkies in #365
- refactor: avoid dependency on concrete schema builders by @mnahkies in #367
- fix: integration tests pass with joi schema builder by @mnahkies in #368
- test: run integration for all schema builders by @mnahkies in #369
- fix: use nodejs built-in sourcemap support by @mnahkies in #370
- chore: update deps by @mnahkies in #371
- refactor: rename zod.ts -> zod-v3.ts by @mnahkies in #372
- feat!: support both zod v3 and zod v4 by @mnahkies in #366
- docs: fix example commands by @mnahkies in #373
- fix: use import type when possible by @mnahkies in #374
- fix: consistently use json5 by @mnahkies in #376
- fix: replace markdown-toc with remark-toc by @mnahkies in #377
- feat: support esm projects by @mnahkies in #375
- feat: adopt trusted publishers by @mnahkies in #378
- fix: avoid lerna reformatting lockfile by @mnahkies in #379
Full Changelog: v0.21.1...v0.22.0
v0.22.0-alpha.0
What's Changed
This is a pretty significant release, with two larger features:
- Support for Zod V4, whilst retaining support for Zod V3
- Support for projects using ESM, and use
import typewhere possible
As such it's being made available as an alpha release for further regression testing: https://www.npmjs.com/package/@nahkies/openapi-code-generator/v/0.22.0-alpha.0
Aside from this, we've made efforts to improve supply chain security 🔒
- Adopted trusted publishers / Github Actions to publish releases
- Added a minimum release age of 7 days for dependencies
- Removed unmaintained dependency
As well as improving the CI setup to run integration and e2e tests across more variants to reduce risk of regressions.
⚠️ Breaking Changes
--schema-builderdefaults tozod-v4--schema-builderno longer acceptszod, you must specify eitherzod-v3orzod-v4as required for your project
Full details:
- feat: set minimumReleaseAge of 7 days by @mnahkies in #363
- chore: update biome by @mnahkies in #364
- chore: upgrade documentation related dependencies by @mnahkies in #365
- refactor: avoid dependency on concrete schema builders by @mnahkies in #367
- fix: integration tests pass with joi schema builder by @mnahkies in #368
- test: run integration for all schema builders by @mnahkies in #369
- fix: use nodejs built-in sourcemap support by @mnahkies in #370
- chore: update deps by @mnahkies in #371
- refactor: rename zod.ts -> zod-v3.ts by @mnahkies in #372
- feat!: support both zod v3 and zod v4 by @mnahkies in #366
- docs: fix example commands by @mnahkies in #373
- fix: use import type when possible by @mnahkies in #374
- fix: consistently use json5 by @mnahkies in #376
- fix: replace markdown-toc with remark-toc by @mnahkies in #377
- feat: support esm projects by @mnahkies in #375
- feat: adopt trusted publishers by @mnahkies in #378
- fix: avoid lerna reformatting lockfile by @mnahkies in #379
Full Changelog: v0.21.1...v0.22.0-alpha.0
v0.21.1
What's Changed
Bug fix release for #360 / #361 - previously nullable string schemas with a default of null would instead default to the string "null" - thanks @geuben!
Bug Fixes
- fix: coercion of null default values by @geuben in #360
- fix: joi supports string values with null default by @mnahkies in #361
Misc
New Contributors
Full Changelog: v0.21.0...v0.21.1
v0.21.0
What's Changed
This is a bigger than normal release, and contains a number of potentially breaking changes - however in general, these are making it clearer when the code generator doesn't support something properly (eg: it was probably already broken).
The primary changes are:
- Unsupported
Content-Typewill now generateneveras their typescript type - HTML form data submissions (
application/x-www-form-urlencoded) are now supported text/plainrequest bodies are also now supported- The CLI will auto-detect your formatter (biome/prettier) config and then use that config / formatter during code generation
- Boolean schemas can now include an
enumto restrict them to literaltrueorfalse - Server urls now allow "required" variables/placeholders
As well as several minor bug fixes, and maintenance chores. Most notably switching to pnpm which will hopefully help prevent issues with missing dependencies or misaligned peer dependencies in future.
Features
- feat: allow mandatory server variables by @mnahkies in #341
- feat: read formatter config by @mnahkies in #343
- feat: support text/plain request bodies by @mnahkies in #350
- feat: boolean schemas support enum by @mnahkies in #351
- feat: support application/x-www-form-urlencoded request bodies by @mnahkies in #352
Bug Fixes
- fix: adjust typing to reflect that boolean request headers are supported by @mnahkies in #339
- fix: partial koa-body middlware options by @mnahkies in #346
- fix: filter invalid request bodies by @mnahkies in #348
- chore: switch to pnpm and fix peer dependencies by @mnahkies in #345
- fix: improve request body / content-type handling by @mnahkies in #349
- fix: serialize scim json bodies by @mnahkies in #355
Misc
- chore(deps): update all dependencies by @renovate[bot] in #338
- fix(ci): adjust workflow permissions by @mnahkies in #340
- chore: upgrade deps / refresh data by @mnahkies in #342
- chore: adjust webpack config to allow node: protocol imports by @mnahkies in #344
- chore: upgrade biome to v2 by @mnahkies in #347
- chore: generate.mjs supports filtering by template/spec by @mnahkies in #353
- fix: check validator works by @mnahkies in #354
- chore: refresh deps / data by @mnahkies in #356
- docs: update compatibility by @mnahkies in #357
Full Changelog: v0.20.1...v0.21.0
v0.20.1
What's Changed
This is a bug fix release that fixes some edge cases and adds compatibility with NodeJS v24.
Bug fixes
- fix: array schema output order by @mnahkies in #329
- fix: error if route placeholder present without matching path parameter by @mnahkies in #331
- fix: fetch proxy compatible with node 24 by @mnahkies in #333
Misc
- refactor: tidy up dependency-graph by @mnahkies in #335
- docs: per page descriptions by @mnahkies in #328
- chore: node v24 / update deps by @mnahkies in #332
- chore: refresh data by @mnahkies in #334
- ci: publish docs on tag push by @mnahkies in #336
- fix: bump engines by @mnahkies in #337
Full Changelog: v0.20.0...v0.20.1
v0.20.0
What's Changed
The main feature in this release is a new typescript-express server generation template. Its very similar in function to the typescript-koa template, but allows use of the express middleware ecosystem.
See the documentation here: https://openapi-code-generator.nahkies.co.nz/guides/server-templates/typescript-express
There was also some improvements of the availability of "escape hatches", namely you can now return a SkipResponse symbol to bypass the normal response validation and sending, allowing your handler full control over this.
Features
- feat: typescript-express server template by @mnahkies in #324
- feat: improve escape hatches by @mnahkies in #326
Bug Fixes
- fix: don't export aliases if name is ApiClient by @mnahkies in #319
- fix: wrap response validation errors when using joi by @mnahkies in #323
Misc
- refactor: decompose koa server generator by @mnahkies in #316
- chore(deps): update all dependencies by @renovate in #317
- ci: cache .next/cache by @mnahkies in #318
- chore: mark specification validation as generated by @mnahkies in #321
- chore: adopt typescript project references by @mnahkies in #322
- fix: parametrize responder generation by @mnahkies in #325
- fix: clean tsconfig.tsbuildinfo by @mnahkies in #327
Full Changelog: v0.19.2...v0.20.0
v0.19.2
v0.19.1
v0.19.0
What's Changed
The headline feature, and potentially breaking change, is safer enum evolution. You can read more about it on the documentation site here: https://openapi-code-generator.nahkies.co.nz/guides/concepts/enums
Otherwise included some minor bug fixes to joi schema generation, and misc testing improvements.
Features
Bug fixes
- fix: typescript is a production dependency by @mnahkies in #299
- fix: joi array query params by @mnahkies in #309
Docs
- feat: add an interactive playground to the documentation site by @mnahkies in #216
- feat(docs): upgrade to nextra 4 by @mnahkies in #301
Misc
- chore: refresh deps / data by @mnahkies in #294
- chore(deps): update all dependencies by @renovate in #293
- chore(deps): update dependency koa to v2.15.4 [security] by @renovate in #296
- chore(deps): update dependency axios to v1.8.2 [security] by @renovate in #300
- chore: deps / refresh data by @mnahkies in #302
- chore(deps): update all dependencies by @renovate in #295
- chore(deps): update dependency next to v15.2.3 [security] by @renovate in #303
- chore(deps): update dependency next to v15.2.4 [security] by @renovate in #305
- chore(deps): update all dependencies by @renovate in #304
- refactor: normalizeSchemaObject is a instance method of input by @mnahkies in #306
- fix: paths to openapi specifications by @mnahkies in #307
- chore(deps): update dependency koa to v2.16.1 [security] by @renovate in #308
- chore: upgrade dependencies and roadmap by @mnahkies in #312
Full Changelog: v0.18.0...v0.19.0
v0.18.0
What's Changed
Primarily a bug-fix release focusing on improving client SDK runtime validation.
POTENTIALLY BREAKING CHANGES
- Users of
joivalidation must change the dependency from@hapi/joitojoi - Unused
ResandStatusCodetypes removed fromtypescript-axios-runtimepackage TypedFetchResponseremoved fromtypescript-fetch-runtimepackage, use exported typeResinstead if needed
Bug fixes
- feat(typescript-fetch)!: simplify response types by @mnahkies in #280
- fix(typescript-axios)!: remove unused exports by @mnahkies in #281
- fix(joi)!: switch from @hapi/joi to joi by @mnahkies in #284
- fix: intersected union schemas by @mnahkies in #283
- fix(typescript-fetch): runtime validation works by @mnahkies in #287
- fix(client-sdks): handle 204 empty responses with runtime validation by @mnahkies in #288
Misc
- chore: refresh / update deps by @mnahkies in #289
- test: add missing unit tests to utils by @mnahkies in #292
- docs: regenerate release-notes by @mnahkies in #279
Full Changelog: v0.17.0...v0.18.0