COMHRAC
Comhrac (Gaelic for "Combat") is a comprehensive training, nutrition, and social platform for martial artists and combat sport athletes.
Development
Initial Setup
These applications are required for development.
Getting Started
- Clone project:
git clone https://github.com/jhegarty14/comhrac.git
secrets.properties
: Create a file calledsecrets.properties
inapi/env
. You will need to request secrets from a member of the Comhrac development team.- Build Images: Go into the comhrac directory and run
docker-compose build
- Start Containers:
docker-compose up
- Local Site Access: The Expo client runs inside the
ui
docker container. Scan the QR code in thedocker-compose up
output in your terminal to see code changes reflected in the UI on your phone. - API Access: Type
localhost:19000
into your browser or Postman, followed by the api endpoint (ex:localhost:19000/api/v1/users/
)
Technologies
REST Response
We are using a custom renderer (Respond) to have our JSON responses in a predefined structure.
{
"data": { }, // Either an object or an array, "data" contains the data returned directly from the handler. Only shown if the "errors" key is empty.
"errors": [ // "errors is an array of error objects, either those generated by the system, or supplied by the handler.
{
"title": "", // Title of the error. Optional string.
"detail: [ ], // Detailed description of the error. Required array of strings.
},
],
"meta": { } // "meta" is an object for system use that does not have a defined structure and can be used for just about anything the system needs.
}