Skip to content

This project offers an API to fetch and display LeetCode leaderboard data, enabling users to track their ranking, performance, and statistics. It is ideal for developers who want to integrate LeetCode stats into their applications or monitor their progress programmatically.

License

Notifications You must be signed in to change notification settings

mahdiehmortazavi/LeetCode-LeaderBoard-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 

Repository files navigation

LeetCode LeaderBoard

This project demonstrates how to interact with the LeetCode API to fetch user profiles and recent submissions using Python and make an internal LeaderBoard based on LeetCode data. The code is structured to handle authentication, fetch data, and process it into a usable format.

Features

  • Fetch user profile data from LeetCode
  • Retrieve recent accepted submissions for multiple users
  • Handle and process JSON responses from the LeetCode GraphQL API
  • Aggregate and analyze user data

Internal Leaderboard

Together with my supervisor Reza Shokrzad (rezashokrzad), we created an internal leaderboard for our community, DSLanders at Cafetadris(cafetadris). This leaderboard uses LeetCode data to rank users based on their performance in terms of best runtime and memory usage for each LeetCode problems. Additionally, users earn extra points for giving presentations about a LeetCode problems or related concepts such as Algorithms or Data Structures for specific problems (DSLanders LeetCode Leaderboard).

LeetCode GraphQL API

The project utilizes the GraphQL API from (alfaarghya) user on GitHub to fetch user profile and recent submission data from LeetCode.

Prerequisites

Before running the code, ensure you have the following installed:

  • Python 3.x
  • Required Python packages (can be installed via pip)

Installation

First, click the "Fork" button at the top right of the page to create a copy of the repository under your own GitHub account; then:

  1. Clone the repository:
    git clone https://github.com/yourusername/LeetCode-LeaderBoard-API.git
  2. Change to the project directory:
    cd LeetCode-LeaderBoard-API
  3. Install the required packages:
    pip install -r requirements.txt

Connect with me

Feel free to connect with me on:

About

This project offers an API to fetch and display LeetCode leaderboard data, enabling users to track their ranking, performance, and statistics. It is ideal for developers who want to integrate LeetCode stats into their applications or monitor their progress programmatically.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages