express-zod-api
Advanced tools
Changelog
v1.3.1
cors: true
the OPTIONS requests have not been handled properly.
This was leading to the 404 error with a message "Can not OPTIONS <route>".
The issue has been fixed and covered by multiple tests.Changelog
v1.2.1
Routing
objects.createServer
, attachRouting
and new OpenAPI()
may throw an Error in case of using slashes in Routing
keys.Changelog
v1.2.0
// example
const endpoint = endpointsFactory.build({
description: "Here is an example description of the endpoint",
// ...,
});
methods
or method
property to .build()
. This is just a more convenient way for a single method case.// example
const endpoint = endpointsFactory.build({
method: "get", // same as methods:['get'] before
// ...,
});
// example of different I/O schemas for /v1/user
const routing: Routing = {
v1: {
user: new DependsOnMethod({
get: myEndpointForGetAndDelete,
delete: myEndpointForGetAndDelete,
post: myEndpointForPostAndPatch,
patch: myEndpointForPostAndPatch,
}),
},
};
Changelog
v1.0.0