Skip to main content
Glama
RishiSarraff

PersonalLeetcodeMCP

by RishiSarraff

LeetCode MCP Connector for Claude.ai

Claude.ai があなたの LeetCode 提出履歴や弱点分析にアクセスできるようにするリモート MCP サーバー。

提供されるツール

ツール

説明

get_submission_history

ステータス、言語、複数回試行検出を含む最近の提出

analyze_weak_areas

トピック別の弱点・強みの内訳と推奨事項

get_user_stats

全体の承認数・提出数、連続記録、ランキングパーセンタイル

get_daily_challenge

今日のデイリーチャレンジ問題

Related MCP server: LeetCode MCP Server

セットアップ

1. インストールしてローカルで実行

npm install
npm start
# → Listening on http://localhost:3000

2. デプロイ(Claude.ai に必要)

Claude.ai では 公開アクセス可能な HTTPS URL が必要です。以下から選択してください。

オプション A — Railway(最も簡単、無料枠あり)

  1. このフォルダを GitHub リポジトリにプッシュします。

  2. railway.app にアクセス → New Project → Deploy from GitHub

  3. Railway が Node.js を自動検出し、https://leetcode-mcp-xxx.railway.app のような公開 URL が発行されます。

オプション B — Render

  1. GitHub にプッシュします。

  2. render.com → New Web Service → リポジトリを接続

  3. Build: npm install、Start: node server.js

  4. https://leetcode-mcp.onrender.com のような URL が取得できます。

オプション C — Docker(任意の VPS/クラウド)

docker build -t leetcode-mcp .
docker run -p 3000:3000 leetcode-mcp
# Then point a domain + SSL at port 3000

オプション D — Cloudflare Workers(アドバンスド)

Cloudflare には組み込みの MCP サポートがあります。詳細: https://developers.cloudflare.com/mcp/

3. Claude.ai に追加

デプロイが完了したら:

  1. Claude.ai → Settings → Connectors に移動します。

  2. 「Add custom connector」 をクリックします。

  3. サーバー URL を入力します: https://your-deployment-url.com/mcp

  4. Add をクリックします。

これで完了です — Claude が LeetCode ツールにアクセスできるようになります。

プロンプト例

接続後、Claude に次のように試してみてください:

  • 「LeetCode の弱点を分析して。私のユーザー名は @john_doe です」

  • 「最近の 20 件の提出を見せて。どの問題で苦戦したか教えて」

  • 「私の LeetCode 統計は?次に何に集中すべき?」

  • 「今日のデイリーチャレンジは?」

LeetCode の API に関する注意事項

  • 公開データ: get_submission_historyget_user_statsanalyze_weak_areasget_daily_challenge はすべて公開プロファイルデータで動作します。対象プロファイルが公開設定であれば、ログインは不要です。

  • 非公開プロファイル: ユーザーがプロファイルを非公開に設定している場合、LeetCode は空のデータを返します。ユーザーは LeetCode の設定 → プライバシーでプロファイルを公開に設定する必要があります。

  • LeetCode には公式の公開 API はありません。このサーバーは LeetCode のフロントエンドが使用しているものと同じ GraphQL エンドポイントを使用しています。LeetCode が API 構造を変更した場合、動作しなくなる可能性があります。

このサーバーの拡張

ツールを追加するには、server.js のパターンに従ってください:

server.tool("tool_name", "description", { param: z.string() }, async ({ param }) => {
  // call lcQuery() and return results
  return { content: [{ type: "text", text: "..." }] };
});

追加に便利なクエリ:

  • タグ/難易度による問題検索(problemsetQuestionList クエリを使用)

  • 企業タグ付き問題(LeetCode Premium セッション Cookie が必要)

  • コンテスト履歴(クエリはファイル内に CONTEST_HISTORY_QUERY として既にあります)

F
license - not found
-
quality - not tested
B
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

View all related MCP servers

Related MCP Connectors

  • Hosted MCP server connecting claude.ai, ChatGPT and other AI apps to your own computer

  • Search your AI chat history (ChatGPT, Claude, Codex) from any MCP client. Remote, private, read-only

  • Hosted Amazon Seller and Vendor MCP server for Claude, ChatGPT, Cursor, Codex, Gemini, Copilot.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/RishiSarraff/PersonalLeetcodeMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server