- Clone project
- Run
docker compose up -d
- Access
localhost:8000
Program flow goes through layers as below:
request
> router > controller > service > repository > service > controller > router > response
Response api functions are arranged in ApiResponse
file containing:
- sendData -> success with data return
- sendOk -> success without data return
- sendError -> error
Success
{
data: [] or {},
message: string
}
Error
{
errors: {
field1: [
"errorMessage1",
"errorMessage2"
],
...
},
message: string
}