Achievements ~ Internal API - uchicago-cs/chigame GitHub Wiki

Internal API Reference

The internal achievements API uses the Django REST Framework. This API was created for the demo game so that achievements could be added without directly interfacing with the database. See the documentation for the demo game here.

Endpoints

The internal API currently has the following endpoints:

  • achievements/api/

    • GET - Gets all the achievements for all games (note: does not filter by game)
    • POST - Creates a new achievement
  • achievements/api/user-achievements/

    • GET - Gets all the user achievements (note: does not filter by user)
    • POST - Creates a new user achievement
  • achievements/api/award-achievement/

    • POST - Creates an achievement in the demo game for clicking a button
  • achievements/api/award-threshold-achievement

    • POST - Creates a threshold achievement in the demo game for clicking a button 5 times