An open API service indexing awesome lists of open source software.

https://github.com/eduardofranca1/nodejs-rest-api-crud-example

Node.js REST API Example: CRUD user with authentication using Node.js, TypeScript, Express, Jest, Mongoose, and Swagger
https://github.com/eduardofranca1/nodejs-rest-api-crud-example

authentication express integration-test jest jwt jwt-authentication mongodb mongoose node nodejs rest rest-api swagger typescript unit-tests

Last synced: 3 months ago
JSON representation

Node.js REST API Example: CRUD user with authentication using Node.js, TypeScript, Express, Jest, Mongoose, and Swagger

Awesome Lists containing this project

README

          

# Node REST API

## Crud API using Node.js, Express, Mongoose, TypeScript and Jest

This is a simple example of **CRUD (Create, Read, Update, and Delete) user operations**.

### Technologies:

- [Express](https://expressjs.com/pt-br/)
- [NodeJS](https://nodejs.org/en/)
- [MongoDB](https://www.mongodb.com/)
- [TypeScript](https://www.typescriptlang.org/)
- [Jest](https://jestjs.io/)

### Features

- Unit Tests using [Jest](https://jestjs.io/pt-BR/)
- API Documentation using [Swagger](https://swagger.io/)
- Authentication using [Json Web Token (JWT)](https://www.npmjs.com/package/jsonwebtoken)
- Data Validation using [Zod](https://zod.dev/)
- Encrypt password using [BcryptJS](https://www.npmjs.com/package/bcryptjs)
- CRUD User
- Soft Delete

- Next steps:
- Add Docker
- Tests for MongoDB
- Middlewares
- Error Handling
- Authorization
- Logger

### How to run the project

- **npm install** (to install node modules)
- **npm run dev** (to start the server)
- **npm run test** (to run the tests)
- **npm run build** (to build the project)