start_problem opens a session per problem and request_hint walks it up one level at a time; list_problem_solutions and get_problem_solution reject with HINT_LEVEL_TOO_LOW until that session has reached the maximum, so the community write-ups are not reachable on the first turn. run_local_tests keeps the inner loop off LeetCode entirely, and with LEETCODE_MCP_STRICT_MODE=1 set, submit_solution refuses until a local run has passed for that problem. The 24 tools only work as designed if the client actually calls get_started first — the flow is carried by convention, not enforced at every step.
An MCP server in front of LeetCode that adds a tutoring session on top of it: per-problem hint levels, a local test runner, and a gate on community solutions.
- Problem access — the daily challenge, a problem by slug, and search across categories, tags, difficulty and keywords with pagination.
- A tutoring session per problem that survives a client restart: open or resume it, read its state, or reset it back to hint level 0.
- A hint ladder that advances one step at a time — clarification, approach, implementation sketch, then the solution unlock at level 4.
- Community solutions behind that ladder — metadata first, then the full text of a chosen solution.
- A local runner that executes your code in an isolated subprocess and reports stdout, stderr and exit code, plus a doctor call that says which language runtimes and OS sandboxes this host has.
- Submission to LeetCode itself, returning acceptance status, runtime and memory stats, or the failing test case.
- Account history — profile, contest ranking, recent and accepted submissions, per-problem progress, and the source of any past submission by ID.
A LeetCode account for anything marked as needing authentication: start_leetcode_auth opens the login and walks the agent through pulling the session and csrftoken values out of browser DevTools, and save_leetcode_credentials validates and stores them. run_local_tests needs a language runtime on the host — runner_doctor reports whether python3, go, java and the sandboxes bwrap, firejail or sandbox-exec were found.
One command plus a key — npx -y @sperekrestova/interactive-leetcode-mcp@latest, then supply credentials
