Skip to content

A nodejs authentication app created using expressjs + passportjs

Notifications You must be signed in to change notification settings

tumbone/ExPassAuth

Repository files navigation

Authentication Service


Boilerplate app built using:

  • NodeJs
  • ExpressJs
  • PassportJs
  • MongoDb

Prerequisites:

Getting Started


The easiest way to get started is to clone the repository and run the server on your local machine:

# Clone the Rpository
git clone <repo-url>

# Navigate into the project folder
cd authentication-service

# Install Dependencies
npm install

# Start the development Server
npm start

Using the Authentication Service


Health Check Endpoint

  • /healthcheck
    Available HTTP Methods: GET

Auth Endpoints

  • /auth/login
    HTTP Method: POST
    Headers: "Content-Type: application/x-www-form-urlencoded" or "Content-Type: application/json"
    Body:
Key           | Value
------------- | -------------
username      | testuser 
password      | testpass

or

{"username":"testuser","password":"testpass"}
  • /auth/verifytoken/:token
    Available HTTP Methods: GET

Users Endpoints

  • /users
    HTTP Method: GET
    Headers: "Authorization: "

  • /users
    HTTP Method: POST
    Headers: "Authorization: "

  • /users/:id
    HTTP Method: GET
    Headers: "Authorization: "

  • /users/:id
    HTTP Method: PUT
    Headers: "Authorization: "

  • /users/:id
    HTTP Method: DELETE
    Headers: "Authorization: "

  • /users/resetpassword/:id
    HTTP Method: PUT
    Headers: "Authorization: "

About

A nodejs authentication app created using expressjs + passportjs

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages