Skip to main content
Glama

copilot-usage-mcp

GitHub Copilot の利用状況メトリクスを取得する MCP (Model Context Protocol) サーバーです。

Enterprise、Organization、Team レベルでの Copilot 使用状況データを MCP ツールとして提供します。

提供ツール

ツール名

説明

get_copilot_metrics_for_enterprise

Enterprise 全体の日次 Copilot 利用メトリクス

get_copilot_metrics_for_org

Organization の日次 Copilot 利用メトリクス

get_copilot_metrics_for_team

Team の日次 Copilot 利用メトリクス

get_copilot_seat_assignments

Organization の Copilot シート割り当て情報

get_copilot_usage_summary

Enterprise / Org / Seats の統合サマリー

各ツールは、コード補完数・Chat 利用状況・アクティブユーザー数・言語 / エディタ別の内訳などを取得できます。

Related MCP server: copilot-status-mcp

セットアップ

前提条件

  • Node.js 18+

  • GitHub Personal Access Token(Copilot メトリクス API へのアクセス権限が必要)

インストール

npm install
npm run build

環境変数

コマンドライン引数または環境変数で以下を設定してください(.env ファイルは読み込まれません)。

変数名

必須

説明

GITHUB_PERSONAL_ACCESS_TOKEN

Yes

GitHub Personal Access Token

GITHUB_ENTERPRISE

No

Enterprise slug

GITHUB_ORG

No

Organization 名

CACHE_DIR

No

キャッシュディレクトリ(デフォルト: ./cache)

MCP クライアントへの設定

Claude Desktop の場合、claude_desktop_config.json に以下を追加します。

{
  "mcpServers": {
    "copilot-usage": {
      "command": "node",
      "args": ["path/to/copilot-usage-mcp/dist/index.js"],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_xxxxxxxxxxxx",
        "GITHUB_ENTERPRISE": "your-enterprise",
        "GITHUB_ORG": "your-org"
      }
    }
  }
}

開発

# TypeScript のウォッチモードで開発
npm run dev

# テスト実行
npm test

# テストのウォッチモード
npm run test:watch

ライセンス

MIT

Available Tools

5 tools
get_copilot_metrics_for_enterpriseA

Get daily Copilot usage metrics for the entire GitHub Enterprise (code completions, chat usage, active users, language/editor breakdown)

Inputs: enterprise, since, until, force_refresh.

get_copilot_metrics_for_orgA

Get daily Copilot usage metrics for a GitHub Organization (code completions, chat usage, active users, language/editor breakdown)

Inputs: org, since, until, force_refresh.

get_copilot_metrics_for_teamC

Get daily Copilot usage metrics for a specific team within an Organization

Inputs: team_slug (required), org, since, until, +1 more.

get_copilot_seat_assignmentsC

Get Copilot seat assignments for an Organization (user list with last activity date, editor info, plan type)

Inputs: org, force_refresh.

get_copilot_usage_summaryA

Get a combined summary of Copilot usage across Enterprise, Organization, and seat assignments. Optionally include team-level metrics.

Inputs: since, until, team_slug, force_refresh.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 5 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose targeting different aspects of Copilot usage data. The enterprise, organization, team, seat assignments, and summary tools all operate at different scopes with no functional overlap, making tool selection unambiguous.

    Naming Consistency5/5

    All tools follow a perfect 'get_copilot_[noun]_[preposition]_[target]' pattern with consistent snake_case throughout. The naming convention is highly predictable and readable across all five tools.

    Tool Count5/5

    Five tools is an ideal number for this focused domain of Copilot usage analytics. Each tool serves a distinct reporting function without redundancy, providing comprehensive coverage while maintaining a manageable interface.

    Completeness5/5

    The toolset provides complete coverage for Copilot usage reporting across all relevant scopes (enterprise, organization, team, seat assignments) with a convenient summary tool. There are no obvious gaps in the analytics surface for this specific domain.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers