Skip to content

Latest commit

 

History

History
48 lines (31 loc) · 1.18 KB

README.md

File metadata and controls

48 lines (31 loc) · 1.18 KB

Number_reservation

This project is a test project for show some programing concepts

This project was build keeping in mind the most important things about Clean Architecture

Run

remember set your env variables to connect to repository, migration/mongo-init-js contains init script for your repository

DB_COLLECTION="collection name"
DB_NAME="db name";
MONGO_URL="mongodb://<yourUser>:<yourPassword>@<yourHost>:"yourPort""

go run cmd/numbers_reservation.go

docker-compose

Run project
    
    docker-compose build
    docker-compose up

Basic Request

Get reservations

curl --location 'http://localhost:8080/v1/reservation'

Create new reservations

curl --location 'http://localhost:8080/v1/reservation' \
--header 'Content-Type: application/json' \
--data '{
    "client_id": "cheems",
    "number": 35
}'

Technologies