typescript-rest
typescript-rest copied to clipboard
This is a lightweight annotation-based expressjs extension for typescript.
Question... Is there a way to build an endpoint that responds with 400 Bad Request and the following inside of the request response body? ```json { "errors": [ {"field": "customParam",...
Can I use @Get('hello') instead of @GET and @Path('hello'). That's simple and consistency with other framework.
I love using typescript-rest, but wanted to easily be able to secure my routes with JWT tokens so I whipped this up and finally got around to rolling it into...
Dev version (non-webpacked) works great but when I build a Prod version w/ webpack I keep getting `Error: Duplicated declaration for path [/users/cleaners/all], method [1].`. There is only 1 path...
Like: @Path("status") @Tags("status") @Response(200 "Okay") @Response(500, "An internal error occurs.") @X("custom-ext", "{ test: "test }") @GET -> x-customext: { test: "test"}) See: https://swagger.io/docs/specification/openapi-extensions/
I wanna use this api for all kind of request & response types and I want to render the 'index.hbs' template for the request made to path '/' like this...
How can I do the following, I have a base class template ``` class BaseService { model=any; constructor(model){ this.model=model; } async findAll(body){ return await this.model.find(body); } async create(body){ return await...
Little example ```Typescript @Path('/hello') class HelloService { @Path(':name') @GET sayHello(@PathParam('name') name: number): string { return `Hello ${name}`; } } ``` How could I check the parameters if the type is...
This PR was automatically created by Snyk using the credentials of a real user.Snyk has created this PR to fix one or more vulnerable packages in the `npm` dependencies of...