Releases: hey-api/openapi-ts
@hey-api/openapi-ts@0.80.1
@hey-api/openapi-ts@0.80.0
Minor Changes
-
#2341
9954bcf
Thanks @mrlubos! - feat(zod): add support for Zod 4 and Zod MiniAdded Zod 4 and Zod Mini
This release adds support for Zod 4 and Zod Mini. By default, the
zod
plugin will generate output for Zod 4. If you want to preserve the previous output for Zod 3 or use Zod Mini, setcompatibilityVersion
to3
ormini
.export default { input: 'https://get.heyapi.dev/hey-api/backend', output: 'src/client', plugins: [ // ...other plugins { name: 'zod', compatibilityVersion: 3, }, ], };
export default { input: 'https://get.heyapi.dev/hey-api/backend', output: 'src/client', plugins: [ // ...other plugins { name: 'zod', compatibilityVersion: 'mini', }, ], };
@hey-api/openapi-ts@0.79.2
Patch Changes
-
#2034
257dd07
Thanks @Le0Developer! - fix(typescript): add support for TypeID types -
#2041
2755be9
Thanks @alexvuka1! - fix(parser): respectoutput.case
when generating operation id
@hey-api/openapi-ts@0.79.1
Patch Changes
-
#2336
6302793
Thanks @mrlubos! - fix: respect NO_INTERACTIVE and NO_INTERACTION environment variables -
#2331
a309fc7
Thanks @mrlubos! - fix(client): update Axios headers types -
#2334
298be27
Thanks @mrlubos! - fix: improve handlebars types for jsr compliance -
#2333
566c8e9
Thanks @mrlubos! - fix(tanstack-query): set query key base url from options if defined
@hey-api/openapi-ts@0.79.0
Minor Changes
-
#2284
236550f
Thanks @mrlubos! - fix(typescript): removedtypescript+namespace
enums modeRemoved
typescript+namespace
enums modeDue to a simpler TypeScript plugin implementation, the
typescript+namespace
enums mode is no longer necessary. This mode was used in the past to group inline enums under the same namespace. With the latest changes, this behavior is no longer supported. You can either choose to ignore inline enums (default), or use theenums
transform (added in v0.78.0) to convert them into reusable components which will get exported as usual.
@hey-api/openapi-ts@0.78.3
@hey-api/openapi-ts@0.78.2
@hey-api/openapi-ts@0.78.1
Patch Changes
-
#2275
1581b5c
Thanks @mrlubos! - fix(valibot): properly handle array minLength and maxLength -
#2279
f0549f6
Thanks @mrlubos! - fix(typescript): handle additionalProperties in propertyNames -
#2277
25fc54c
Thanks @mrlubos! - fix(clients): annotate serializer return types -
#2280
ae9c45a
Thanks @mrlubos! - fix(zod): adddates.offset
option
@hey-api/openapi-ts@0.78.0
Minor Changes
-
#2246
a11a8c5
Thanks @mrlubos! - feat(config): addparser
optionsAdded
parser
optionsPreviously,
@hey-api/typescript
would generate correct types, but the validator plugins would have to re-implement the same logic or generate schemas that didn't match the generated types.Since neither option was ideal, this release adds a dedicated place for
parser
options. Parser is responsible for preparing the input so plugins can generate more accurate output with less effort.You can learn more about configuring parser on the Parser page.
Moved
input
optionsThe following options were moved to the new
parser
group.input.filters
moved toparser.filters
input.pagination
moved toparser.pagination
input.patch
moved toparser.patch
input.validate_EXPERIMENTAL
moved toparser.validate_EXPERIMENTAL
Updated
typescript
optionsThe following options were renamed.
enumsCase
moved toenums.case
enumsConstantsIgnoreNull
moved toenums.constantsIgnoreNull
Moved
typescript
optionsThe following options were moved to the new
parser
group.exportInlineEnums
moved toparser.transforms.enums
readOnlyWriteOnlyBehavior
moved toparser.transforms.readWrite.enabled
readableNameBuilder
moved toparser.transforms.readWrite.responses.name
writableNameBuilder
moved toparser.transforms.readWrite.requests.name
Updated
readWrite.responses
nameAdditionally, the naming pattern for response schemas has changed from
{name}Readable
to{name}
. This is to prevent your code from breaking by default when using a schema that gets updated with a write-only field.
Patch Changes
@hey-api/openapi-ts@0.77.0
Minor Changes
-
#2227
4ea6f24
Thanks @mrlubos! - refactor(plugin): addDefinePlugin
utility typesUpdated Plugin API
Please refer to the custom plugin tutorial for the latest guide.
-
#2227
4ea6f24
Thanks @mrlubos! - feat(sdk): updatevalidator
optionUpdated
sdk.validator
optionClients can now validate both request and response data. As a result, passing a boolean or string to
validator
will control both of these options. To preserve the previous behavior, setvalidator.request
tofalse
andvalidator.response
to your previous configuration.export default { input: 'https://get.heyapi.dev/hey-api/backend', output: 'src/client', plugins: [ // ...other plugins { name: '@hey-api/sdk', validator: { request: false, response: true, }, }, ], };