Skip to content

Latest commit

 

History

History
87 lines (53 loc) · 1.85 KB

File metadata and controls

87 lines (53 loc) · 1.85 KB

logo

Codewars pretty stats

A free API for retrieving great stats from your CodeWars account to spruce up your GitHub account, website, or anything else.

codewars_stats

Run Locally

Clone the project

  git clone https://github.com/Selector0073/codewars-pretty-stats

Go to the project directory

  cd codewars-pretty-stats

Create a .env file and fill it with the structure .env.example

Start the server

  go run cmd/codewars-api/main.go

Make a request to url with the correct parameters

http://localhost:4322/?size=1&username=Selector0073

Running Tests

To run tests, run the following command

  go test ./...

Usage/Examples

To use the projects, simply make a request with your parameters to https://codewars-pretty-stats.selector0073.com for example:

[![codewars_stats](https://codewars-pretty-stats.selector0073.com/?size=2&username=Selector0073)](https://github.com/Selector0073/codewars-pretty-stats/)

or

<img src="https://codewars-pretty-stats.selector0073.com/?size=1&username=Selector0073">

Parameters

Parameters should be passed as query params

https://codewars-pretty-stats.selector0073.com/?size=1&username=Selector0073

size is the size multiplier. This value must be an float from 0.5 to 5.

username is your codewars username.

Contributing

Contributions are always welcome! You can fork the repository and after finishing work add a pull request describing the changes

Roadmap

  • Add caching
  • Get the font locally, not from the internet
  • Add codewars logo

License

MIT