@lumenalta-ct/leaderboard-mcp
v1.3.1
Published
Claude Code MCP server — automatic leaderboard sync (replaces CLASP Go CLI)
Downloads
116
Readme
@lumenalta-ct/leaderboard-mcp
Claude Code MCP server that automatically syncs Claude Code session history to the AI-Native Leaderboard. Replaces the CLASP Go CLI for engineers who prefer the MCP integration path.
How it works
The server runs as a background stdio MCP process managed by Claude Code. On startup it performs an initial sync (deferred 30 s to let Claude Code settle), then re-syncs every 12 hours. Failed uploads are queued locally and flushed on the next successful connection.
Installation
The recommended way is via the org-config sync (clasp sync), which writes org.json into ~/.claude/org/settings.json automatically. For manual setup:
Option A — npx (no install required)
Add to ~/.claude/settings.json (or ~/.claude/org/settings.json):
{
"mcpServers": {
"leaderboard": {
"command": "npx",
"args": ["-y", "@lumenalta-ct/leaderboard-mcp"],
"env": {
"LEADERBOARD_API_URL": "https://claude-leaderboard.lumenalta.com",
"SUPABASE_URL": "https://<ref>.supabase.co",
"SUPABASE_ANON_KEY": "eyJ..."
}
}
}
}Option B — global install
npm install -g @lumenalta-ct/leaderboard-mcpThen reference the binary in your MCP config:
{
"mcpServers": {
"leaderboard": {
"command": "leaderboard-mcp",
"env": {
"LEADERBOARD_API_URL": "https://claude-leaderboard.lumenalta.com",
"SUPABASE_URL": "https://<ref>.supabase.co",
"SUPABASE_ANON_KEY": "eyJ..."
}
}
}
}Environment variables
| Variable | Required | Description |
|---|---|---|
| LEADERBOARD_API_URL | recommended | Base URL of the leaderboard app. Defaults to https://ai-native-leaderboard.vercel.app |
| SUPABASE_URL | yes | Supabase project URL — obtain from the leaderboard admin |
| SUPABASE_ANON_KEY | yes | Supabase anon/public key — obtain from the leaderboard admin |
| GITHUB_USERNAME | optional | Enriches git-signal attribution in the payload |
MCP tools
After the server starts, four tools are available inside any Claude Code session:
| Tool | Description |
|---|---|
| leaderboard_sync | Reads ~/.claude/projects/ and uploads new sessions to the leaderboard now |
| leaderboard_status | Shows last sync time, queue depth, and auth state |
| leaderboard_login | Stores Supabase session credentials (access token, refresh token, user ID, email) |
| leaderboard_flush | Force-flushes the offline queue — use after reconnecting from offline |
Authentication
After configuring the MCP server, ask Claude to run leaderboard_login and provide your Supabase session tokens from the leaderboard app profile page.
Requirements
- Node.js 20+
- Claude Code desktop with MCP support
Publishing
This package is published to npm as @lumenalta-ct/leaderboard-mcp. To publish a new version:
cd packages/leaderboard-mcp
npm run build # compiles src/ → dist/index.js
npm publish --access public