A Node.Js boilerplate built using Express.Js framework to provide a skeleton of User Authentication using JSON Web Token (JWT) library.
The easiest way to get started is to clone the repository:
# Get the latest snapshot
git clone https://github.com/jimcute/jwt-auth-boilerplate.git
# Change directory
cd jwt-auth-boilerplate
# Install NPM dependencies
npm install
# Then simply start your app
node app.js
- Local Authentication using Email and Password
- MVC Project Structure
- JWT Authentication
Type: POST
Parameters: email, password, firstname, lastname
# Call the API using Postman with the required parameters
http://localhost:3000/api/auth/register
Type: POST
Parameters: email, password
# Call the API using Postman with the required parameters
http://localhost:3000/api/auth/login
Type: GET
Headers: x-access-token
# Call the API using Postman with the required parameters
http://localhost:3000/api/v1/me