This is an example project to give you some hints in order to integrate jwt authentication with Buffalo.
There is a blog post on Medium that explains part of the code you'll find here.
You can run the app with:
$ JWT_KEY_PATH=/{project-path}/jwtRS256.key buffalo dev
Two routes are set:
// Requires email and password. Response contains a JWT token
$ POST http://127.0.0.1:3000/api/v1/auth/login
// Requires JWT token set in Authorization header
$ GET http://127.0.0.1:3000/api/v1/users/me
You can run tests with:
$ JWT_KEY_PATH=/{project-path}/jwtRS256.key buffalo test
PRs are very welcome to improve the project as it may be used by many developers to get started with a JWT base Buffalo app.