An unofficial Discord bot that provides info about contests, user standings, and more.
- User Info: Get details about a Codeforces user.
- Contest Info: Check out upcoming and finished contests.
- User Standings: See how a user did in a specific contest.
- Compare Problem Ratings: Compare the problem-solving stats of one or two users.
- Contest Tournament: Suggest a random contest for users. The bot will announce the winners when the contest is over.
We use Redis to cache API responses. This makes things faster and reduces unnecessary API calls.
-
Invite the Bot:
- Click here to invite the bot to your server.
- Note: The bot is hosted on a free Koyeb instance, so it might not always be available.
-
Commands:
/userinfo username:<username>
: Get info about a Codeforces user./upcoming-contests
: List upcoming Codeforces contests./finished-contests
: List recently finished Codeforces contests./standing username:<username> contest_id:<contestId>
: See a user's standing in a specific contest./random-problem ratingStart:<ratingStart> ratingEnd:<ratingEnd> [tags:<tag1,tag2,...>]
: Get a random problem from Codeforces based on rating and tags./rating-history username:<username>
: Get the rating history graph of a user./problem-ratings username:<username>
: Get the rating stats of solved problems for a user./compare-problem-ratings username1:<username1> username2:<username2>
: Compare the rating stats of solved problems between two users./random-contest usernames:<username1>,<username2>,... contest_type:<contestType> [start_time:<startTime>]
: Suggest a random contest for a virtual tournament. The bot will announce the winners when the contest is over.
-
Random Problem:
1.mp4
-
User Information:
2.mp4
-
Rating History:
3.mp4
-
Upcoming and Finished Contests:
4.mp4
-
User Contest Standings:
5.mp4
-
Problem Rating Statistics:
-
Contest Tournament: After the virtual contest ends, the bot will send the participants' ranks along with details like:
- Number of solved problems
- Number of wrong answers during the contest
The bot can handle multiple time zones. The user can also confirm or cancel the command using buttons.
-
Clone the Repository:
git clone https://github.com/AhmedMohamedAbdelaty/Codeforces-Discord-bot.git
-
Build the Project (requires Maven):
mvn clean install
-
Run the Docker Container: The docker image will run the bot and a Redis server. You need to provide the bot token to run the bot.
docker build -t codeforces-bot . docker run -p 8000:8000 -p 6379:6379 codeforces-bot -t <your_bot_token>
We'd love your help! Feel free to submit a pull request.