GAME CURRENCY API DOCUMENTATION
This repository contains source code for Soccer API.
Getting Started
To run the project localy, make sure minimum requirements are fulfilled.
- Go version 1.10 or higher
- PostgreSQL version 12 or Latest
- Docker (optional) -- see here.
How To Run this Project
Since the project already use Go Module, I recommend to put the source code in any folder but GOPATH.
Running Without Docker
-
Make sure Go is installed as global command (first time only)
-
Clone this project and go to the root project to install all dependencies (first time only)
// clone the repository
> git clone https://github.com/usernamesalah/game-currency.git
// change directory to root project folder
> cd game-currency
// install all the dependencies
> make init
-
Running your PostgreSQL
-
While still in root project build and run the app
// build project
> make build
// source env
> source .env.development
// run project
> ./bin/game-currency
// now go to http://localhost:8080/ in your browser to check the app.
Running from Docker Container
Run the testing
make test
for access POST API you need to login with default (admin:admin)
API Documentation
We use swag to generate necearry Swagger files for API documentation. Everytime we run make build
, the Swagger documentation will be updated.
To configure your API documentation, please refer to swag's declarative comments format and examples.
To access the documentation, please visit API DOCUMENTATION.
Repository Content
Tools Used
In this project, I use some tools listed below