Skip to content

Angrycreative/AngryLadder

Repository files navigation

Angryladder

Built with Lumen.

Use together with our Slack bot.

API endpoints

/v1/games/ (get)
/v1/games/{id} (get)
/v1/games/ (post)
/v1/games/{id} (put)

/v1/players/ (get)
/v1/players/{id} (get)
/v1/players/top (get)
/v1/players/top/mostgames (get)
/v1/players/ (post)
/v1/players/{id} (put)

Postman collection

Download Postman collection. Save it, import it into your Postman client and set up url as an environment variable to test all the endpoints.

Setup

  1. git clone
  2. Run composer install
  3. Copy .env.sample to .env
    1. Edit APP_ENV(local, stage or production) and APP_DEBUG according to what environment you are seting up
    2. Set APP_KEY. Should be a random string of at exactly 32 characters
    3. Set the database options in .env
    4. Add SLACK_CLIENT_ID and SLACK_CLIENT_SECRET if you want to be able to sync players from Slack.
  4. Run migrations: php artisan migrate
    1. (optional) If you want test data, seed the database: php artisan db:seed
  5. Start work server php artisan queue:listen. More options for more stable work server can be found here (supervisor is recomended).

TODO

  • Some kind of web UI (separate project using the API. React?)
  • Update to latest versions of Lumen and libs (Maybe wait for the 5.5 LTS in August)
  • Implement new Glicko2 ranking calculator (in progress)
  • Implement support for dynamic ladder periods (in progress)
  • Fix bugs related to all time vs weekly rankings (in progress)
  • Unit tests
  • Setup CI tools (TravisCI?)
  • Setup code check tools (Scrutinizer?)