Repository navigation
Releases: oxc/tsapi
Release list
v0.2.0-rc.1
The packages now work on zod's core (zod/v4/core) rather than its classic API, so APIs can be defined with zod/mini schemas as well as classic ones — and a bundle built from mini schemas no longer pulls in all of classic zod through tsapi's own import.
Breaking change
Validation errors are now zod core's $ZodRealError rather than classic ZodError, so err instanceof ZodError no longer matches them — an express error handler that turns those into a 400 will start answering 500. Check against $ZodError instead, which matches classic, core and mini errors alike:
import { $ZodError } from "zod/v4/core";
if (err instanceof $ZodError) {
// err.issues as before
}Everything else is unchanged
- Classic schemas keep working as they are: they are core schemas too.
- Route params merged into an endpoint's params keep the class they were written in, so a classic schema stays classic and a mini one stays mini (mixing them works, too).
- The peer range stays
zod@^4.0.0.
Full Changelog: v0.1.1...v0.2.0-rc.1
v0.1.1
Maintenance release. No API changes since 0.1.0.
@oxc/tsapi-client: dropped the stray@jest/typesruntime dependency (it was unused; jest typing comes from devDependencies).- Build tooling migrated from yarn 4 to pnpm 11.
Full Changelog: v0.1.0...v0.1.1
v0.1.1-rc.1
Prerelease to verify the pnpm 11 publish path (trusted publishing via OIDC, --tag next) after migrating off yarn. No source changes since v0.1.0.
v0.1.0
Dependency modernization. Breaking: peer dependencies now require zod 4 and express 5.
Breaking changes
-
zod 4 — peer range is now
^4.0.0(was^3.21.4). zod 3 is no longer supported. -
express 5 —
@oxc/tsapi-expresspeer range is now^5.0.0(was^4.0.0). Note that express 5 also tightened path-pattern syntax: unnamed*wildcards and optional:param?segments are no longer valid in paths passed toget/post/route. -
req.queryis no longer replaced with the parsed query. express 5 exposesreq.queryas a getter by design, so tsapi now leaves it alone and it keeps the raw, unvalidated values. The parsed and coerced query is still handed to your handler asqueryinEndpointArgs, which is unchanged — but a handler readingreq.querydirectly now sees raw strings.EndpointRequestno longer typesreq.queryas the schema output, so the compiler flags the affected call sites for you.req.paramsandreq.bodyare still replaced with their parsed values, as before.
Internal
- Ported to the zod 4 type API:
z.AnyZodObject→z.ZodObject<$ZodShape, $ZodObjectConfig>,objectUtil.extendShape→z.core.util.Extendwith the two-parameterZodObject<Shape, Config>,.merge()→.extend(),_def.typeName→_zod.def.type. - Parsed
params/bodyare now only written back to the request when the endpoint actually defines a schema for them. - TypeScript 5.9 (latest 5.x — ts-jest does not support TypeScript 7 yet),
module: NodeNext,baseUrl→rootDir, and a pinned@types/node. - Publishing to npm now uses trusted publishing (OIDC) instead of a long-lived token.
Full Changelog: v0.0.3...v0.1.0
v0.0.3
v0.0.2
Full Changelog: https://github.com/oxc/tsapi/commits/v0.0.2