Skip to main content
Glama

mcp-server-leetcode

MCP サーバー LeetCode

AI アシスタントが LeetCode の問題、ユーザー情報、コンテスト データにアクセスできるようにする、LeetCode 用のモデル コンテキスト プロトコル (MCP) サーバー。

特徴

  • 🚀 LeetCode APIへの高速アクセス
  • 🔍 問題を検索し、毎日の課題を取得し、ユーザープロフィールを確認します
  • 🏆 クエリコンテストデータとランキング
  • 🧩 MCPツールとリソースの完全サポート
  • 📦 CLIとプログラム可能なAPIの両方を提供

インストール

グローバルインストール

npm install -g @mcpfun/mcp-server-leetcode

インストールしたら、コマンドラインから直接実行できます。

mcp-server-leetcode

ローカルインストール

npm install @mcpfun/mcp-server-leetcode

使用法

Claude for Desktopとの統合

Claude for Desktop のclaude_desktop_config.jsonファイルに以下を追加します。

{ "mcpServers": { "leetcode": { "command": "mcp-server-leetcode" } } }

地域開発の場合:

{ "mcpServers": { "leetcode": { "command": "node", "args": ["/path/to/dist/index.js"] } } }

図書館として利用

import { LeetCodeService } from '@mcpfun/mcp-server-leetcode'; // Initialize the service const leetcodeService = new LeetCodeService(); // Get daily challenge const dailyChallenge = await leetcodeService.getDailyChallenge(); // Search problems const problems = await leetcodeService.searchProblems({ difficulty: 'MEDIUM', tags: 'array+dynamic-programming' });

利用可能なツール

問題関連ツール

ツール名説明パラメータ
get-daily-challenge毎日のチャレンジに挑戦なし
get-problem特定の問題の詳細を取得するtitleSlug (文字列)
search-problems基準に基づいて問題を検索するtags (オプション)、 difficulty (オプション)、 limit (デフォルト20)、 skip (デフォルト0)

ユーザー関連ツール

ツール名説明パラメータ
get-user-profileユーザー情報を取得するusername (文字列)
get-user-submissionsユーザーの投稿履歴を取得するusername (文字列)、 limit (オプション、デフォルトは20)
get-user-contest-rankingユーザーコンテストランキングを取得するusername (文字列)

コンテスト関連ツール

ツール名説明パラメータ
get-contest-detailsコンテストの詳細を見るcontestSlug (文字列)

利用可能なリソース

問題リソース

  • leetcode://daily-challenge : デイリーチャレンジ
  • leetcode://problem/{titleSlug} : 問題の詳細
  • leetcode://problems{?tags,difficulty,limit,skip} : 問題リスト

ユーザーリソース

  • leetcode://user/{username}/profile : ユーザープロフィール
  • leetcode://user/{username}/submissions{?limit} : ユーザーの投稿
  • leetcode://user/{username}/contest-ranking : ユーザーコンテストランキング

地域開発

リポジトリをクローンし、依存関係をインストールします。

git clone https://github.com/doggybee/mcp-server-leetcode.git cd mcp-server-leetcode npm install

開発モードで実行:

npm run dev

プロジェクトをビルドします。

npm run build

ライセンス

マサチューセッツ工科大学

関連プロジェクト

謝辞

Install Server
A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

AI アシスタントが LeetCode の問題、ユーザー情報、コンテスト データにアクセスできるようにする、LeetCode 用のモデル コンテキスト プロトコル (MCP) サーバー。

  1. 特徴
    1. インストール
      1. グローバルインストール
      2. ローカルインストール
    2. 使用法
      1. Claude for Desktopとの統合
      2. 図書館として利用
    3. 利用可能なツール
      1. 問題関連ツール
      2. ユーザー関連ツール
      3. コンテスト関連ツール
    4. 利用可能なリソース
      1. 問題リソース
      2. ユーザーリソース
    5. 地域開発
      1. ライセンス
        1. 関連プロジェクト
          1. 謝辞

            Related MCP Servers

            • -
              security
              A
              license
              -
              quality
              A Model Context Protocol (MCP) server that allows AI assistants like Claude to interact with Go's Language Server Protocol (LSP) and benefit from advanced Go code analysis features.
              Last updated -
              35
              Go
              Apache 2.0
            • A
              security
              A
              license
              A
              quality
              A Model Context Protocol server that provides integration with LeetCode APIs, enabling automated interaction with programming problems, contests, solutions, and user data across both leetcode.com and leetcode.cn platforms.
              Last updated -
              13
              129
              39
              TypeScript
              MIT License
            • -
              security
              A
              license
              -
              quality
              A Model Context Protocol (MCP) server that implements AI-First Development framework principles, allowing LLMs to interact with context-first documentation tools and workflows for preserving knowledge and intent alongside code.
              Last updated -
              332
              Python
              AGPL 3.0
            • A
              security
              F
              license
              A
              quality
              An all-in-one Model Context Protocol (MCP) server that connects your coding AI to numerous databases, data warehouses, data pipelines, and cloud services, streamlining development workflow through seamless integrations.
              Last updated -
              2
              Python
              • Apple
              • Linux

            View all related MCP servers

            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/doggybee/mcp-server-leetcode'

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