ndelvalle/generator-api

Adding JWT, Swagger and versioning

anilprasad opened this issue · 1 comments

How do we hook swagger, JWT packages on to the platform and what could be the best model for adopting api versioning within the platform?

@anilprasad I'm not that familiar with swagger, but I don't see why it would be different from applying to any other API. To manage JWT I would use express-jwt and attach it to an express middleware, then you should have a route to be able to create and sign a tokens. I think this is a good tutorial. Regarding versioning you can set it up like any other nodejs api, this is out of this repo scope.