🇧🇷 Português
Projeto desenvolvido durante o terceiro módulo (desenvolvimento back-end) do curso da Trybe.
Construir uma API para gerenciar o banco de dados de estoque e vendas no formato dropshipping em que é possível criar, visualizar, deletar e atualizar produtos e vendas. A API segue uma arquitetura RESTful, em camadas MSC e conta com testes de integração para cobrir o código.
- Arquitetura: RESTful, MSC
- Back-end: Express, JavaScript, MySQL, Node.js
- Plataforma: Docker
- Testes: Chai, Jest, Mocha, Sinon
- Instale os containers docker:
npm run compose:up
- Execute o terminal do container:
docker attach store_manager
- Instale as dependências, crie e popule o banco de dados:
npm install && npm run migration && npm run seed
- Inicialize a aplicação:
npm start
- Execute os testes unitários:
npm run test:mocha
Sales
Requisição | URL |
---|---|
GET |
http://localhost:3000/sales |
GET |
http://localhost:3000/sales/:id |
POST |
http://localhost:3000/sales |
PUT |
http://localhost:3000/sales/:id |
DELETE |
http://localhost:3000/sales/:id |
Products
🇺🇸 English
Project developed during the third module (back-end development) of the Trybe course.
Build an API to manage the stock and sales database in dropshipping format where you can create, view, delete and update products and sales. The API follows a RESTful layered MSC architecture and relies on integration tests to cover the code.
- Architecture: RESTful, MSC
- Back-end: Express, JavaScript, MySQL, Node.js
- Platform: Docker
- Tests: Chai, Jest, Mocha, Sinon
- Install the docker containers:
npm run compose:up
- Run the container terminal:
docker attach store_manager
- Install dependencies, create and populate the database:
npm install && npm run migration && npm run seed
- Start the application:
npm start
- Run unit tests:
npm run test:mocha
Sales
Method | URL |
---|---|
GET |
http://localhost:3000/sales |
GET |
http://localhost:3000/sales/:id |
POST |
http://localhost:3000/sales |
PUT |
http://localhost:3000/sales/:id |
DELETE |
http://localhost:3000/sales/:id |
Products