Skip to content

Quaver/api-v2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ed41999 Â· Jan 17, 2025
Oct 8, 2024
Jul 26, 2024
Aug 24, 2024
Dec 21, 2024
Nov 26, 2024
Jan 17, 2025
Nov 24, 2024
Aug 1, 2024
Dec 6, 2024
Jul 30, 2024
Sep 7, 2024
Sep 14, 2024
Aug 1, 2024
Oct 26, 2024
Jul 2, 2024
Aug 1, 2024
Aug 18, 2024
Nov 26, 2024
Jul 8, 2024
Jul 15, 2024
Jul 8, 2024
Nov 26, 2024
Oct 18, 2024
Oct 18, 2024
Sep 14, 2024

Repository files navigation

api-v2

🌎 The new API server for Quaver.

api-v2 is the most up-to-date (v2) and open source version of the Quaver web API.

As endpoints are made available in v2, it is recommended to use them instead of its v1 counterpart, as v1 will be deprecated, as we begin to update usage in-game and on our website.

This application is being developed for internal network use. As such, no support will be provided for the usage of this software.

Requirements

  • Go 1.22
  • MariaDB / MySQL
  • Redis
  • ElasticSearch 8.14.1
  • Steam Publisher API Key
  • OpenAI API Key
  • FFmpeg
  • Compiled Quaver.Tools Executable
  • Stripe CLI (for donations/store item development/testing)
  • Postman (for testing)

Setup

  • Install Go 1.22 or later.
  • Clone the repository.
  • Copy config.example.json and make a file named config.json
  • Fill out the config file with the appropriate details.
    • Note: quaver_tools_path is the path to the Quaver.Tools executable, not the directory.
  • Navigate to the /cmd/api/ directory.
  • Start the server with go run . or your method of choice.
  • The server is now available at http://localhost:8080 (or your desired port).

Testing

Request handlers can be tested through Postman.

Some endpoints require authentication. To access them, you must generate a JWT, and set it in the variables section of the Postman collection.

Example JWT Payload

{
  "user_id": 2,
  "username": "QuaverBot",
  "iat": 1516239022
}

LICENSE

This software is licensed under the GNU Affero General Public License v3.0. Please see the LICENSE file for more information.