LeetCode API access end points :
-
User
- GET
user/ - GET
user/<user-name>/contests - GET
user/<user-name>/solved - GET
user/<user-name>/badges - GET
user/<user-name>/active-years - GET
user/<user-name>/submissions
- GET
-
Leetcode
- GET
leetcode/todays-question- limit: number [QUERY_PARAMS]
- username: string [QUERY_PARAMS]
- GET
leetcode/histogram- limit: number [QUERY_PARAMS]
- username: string [QUERY_PARAMS]
- GET
leetcode/top-100- limit: number [QUERY_PARAMS]
- skip: number [QUERY_PARAMS]
- GET
- Clone the repository
https://github.com/bharathkalyans/leetcode-rest-api.gitusing commandgit clone https://github.com/bharathkalyans/leetcode-rest-api.git - Open the terminal, navigate to the package.json directory and run the command
npm iornpm installto install all the dependencies.
Run the application using the below command
npm start
- Visit
http://localhost:4000for local server access.
/.
/app.js
/routes
/leetcode.js
/userInfo.js
/queries
/leetcodeGraphqlQueries.js
/userGraphqlQueries.js
/utils
/constants.js
/utility.js
- All contributions are welcome 🙌🏼
- Open an issue first, get yourself assigned before working on it and describe changes made properly and attach supporting Snapshots in the PR.