Closed chinesedfan closed 4 months ago
Now clist invokes https://leetcode.com/contest/api/info/{contestSlug}/ to get question_id, which is different with the id that we see in browsers.
question_id
For example, "1791. Find Center of Star Graph", question_id is 1916, but questionFrontendId is 1791.
questionFrontendId
FYI, I find it can be queried by GraphQL. Not sure whether it can be implemented by clist. You can also search in Github and find more examples.
// https://leetcode.com/graphql/, the request payload is, {"query":"\n query questionTitle($titleSlug: String!) {\n question(titleSlug: $titleSlug) {\n questionId\n questionFrontendId\n title\n titleSlug\n isPaidOnly\n difficulty\n likes\n dislikes\n categoryTitle\n }\n}\n ","variables":{"titleSlug":"find-center-of-star-graph"},"operationName":"questionTitle"}
Added id field by default for leetcode.com resource.
id
@aropan Did you refresh all leetcode's problems, or just recent contests?
Now clist invokes https://leetcode.com/contest/api/info/{contestSlug}/ to get
question_id
, which is different with the id that we see in browsers.For example, "1791. Find Center of Star Graph",
question_id
is 1916, butquestionFrontendId
is 1791.FYI, I find it can be queried by GraphQL. Not sure whether it can be implemented by clist. You can also search in Github and find more examples.