- Node.js
- Jest
- Express.js
- PostgreSQL
- JWT (JSON Web Tokens)
- Sequelize
- Joi
As per our understanding, the document does not provide a concrete way to define role-based access to Locus data. Therefore, we have implemented a login API with dummy users and JWT authentication.
To access different roles and test role-based access, you can use the following dummy users and passwords:
-
Admin Role:
- Username: 'admin'
- Password: 'test@password'
-
Normal User Role:
- Username: 'normal'
- Password: 'test@password'
-
Limited User Role:
- Username: 'limited'
- Password: 'test@password'
-
To get started with this project, follow the steps below:
Clone the GitHub repository to your local machine using the following command:
git clone https://github.com/TOPSinfo/express-backend-test.git
cd express-backend-test
npm i
npm start
project will be started on http://localhost:3000/
get locus api end-point http://localhost:3000/locus
-
To run the unit testing:
npm run test
-
To view swagger documentation: