https://github.com/samuel-ricardo/nestjs_hexagonal-architeture
A NestJS API to integrate with a CRM build using Hexagonal Architeture
https://github.com/samuel-ricardo/nestjs_hexagonal-architeture
Last synced: 3 months ago
JSON representation
A NestJS API to integrate with a CRM build using Hexagonal Architeture
- Host: GitHub
- URL: https://github.com/samuel-ricardo/nestjs_hexagonal-architeture
- Owner: Samuel-Ricardo
- License: mit
- Created: 2023-07-11T14:48:19.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-07-25T21:31:14.000Z (almost 2 years ago)
- Last Synced: 2025-01-14T12:43:38.995Z (5 months ago)
- Language: TypeScript
- Size: 156 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# nestjs_hexagonal-architeture
🚀 🟥 Discovery 🟥 🚀
Application developed with the purpose of studying the NestJS Ecosystem and Hexagonal Architeture#
|
Overview |
Technologies |
Project |
Routes |
Run |
Author |#
| :artificial_satellite: About:
This API target is to explore an Hexagonal Architeture implementation With NestJS Framework, furthuermore, this application simulate a relation with a marketing CRM that consume data from this API.
:building_construction: | Technologies and Concepts Studied:- NestJS - [Express]
- Docker
- Sequelize
- SQLite
- Redis
- Bull - [Queues]
- Event-Emmiter
- Swagger | [Documentation]
- JS | Typescript
- Test | Jest
- Axios
- json-server
- eslint
- prettier
- husky
- lint-sataged
- @swc | [Rust Compiler]> Among Others...
#
💻 | Application:
The hexagonal architecture consists of the philosophy of ports and adapters, such as the usb-c port on your phone that accepts all types of usb-c compatible chargers.
This concept was applied to create an API that handles and sends the list data to a simulated CRM, for that, I used the event system to create event-listeners and emiters that on trigger send the data to a Queue with Bull & Redis and from the queue the API sends the data to the CRM.
This project have a dev friendly ambient that provides a automatic code formarter and linting, tests, Documentation with Swagger and Docker containers
```bash
$ hexagonal_architeture > api.http
###
GET http://localhost:3000/lists###
GET http://localhost:3000/lists/3###
POST http://localhost:3000/lists
Content-Type: application/json{
"name": "My List2"
}###
GET http://localhost:8000/lists```
#
👨💻 | How to use
### Open your Git Terminal and clone this repository
```git
$ git clone "[email protected]:Samuel-Ricardo/nestjs_hexagonal-architeture.git"
```### Make Pull
```git
$ git pull "[email protected]:Samuel-Ricardo/nestjs_hexagonal-architeture.git"
```
This application use `Docker` so you dont need to install and cofigurate anything other than docker on your machine.
Navigate to project folder `$ cd ./hexagonal_architeture/` and run it using `docker-compose`
```bash
# After setup docker environment just run this commmand on root project folder:
$ docker-compose up --build # For First Time run this command
$ docker-compose up # to run project
```
You can also run NestJS Directly without Docker [[HERE](https://github.com/Samuel-Ricardo/nestjs_hexagonal-architeture/blob/main/hexagonal_architeture/README.md)]
```bash
#Apps Running on:
$ API: http://localhost:3000
$ CRM: http://localhost:8000
$ REDIS: redis://localhost:6379
See more: ./hexagonal_architeture/docker-compose.yaml
```
#
:octocat: | Author:
![]()
![]()
![]()
![]()