Chess.com MCP Server for Mastra AI 15 tools — connect in under 2 minutes
Mastra AI is a TypeScript-native agent framework built for modern web stacks. Connect Chess.com through the Vinkius and Mastra agents discover all tools automatically — type-safe, streaming-ready, and deployable anywhere Node.js runs.
ASK AI ABOUT THIS MCP SERVER
Vinkius supports streamable HTTP and SSE.
import { Agent } from "@mastra/core/agent";
import { createMCPClient } from "@mastra/mcp";
import { openai } from "@ai-sdk/openai";
async function main() {
// Your Vinkius token — get it at cloud.vinkius.com
const mcpClient = await createMCPClient({
servers: {
"chesscom": {
url: "https://edge.vinkius.com/[YOUR_TOKEN_HERE]/mcp",
},
},
});
const tools = await mcpClient.getTools();
const agent = new Agent({
name: "Chess.com Agent",
instructions:
"You help users interact with Chess.com " +
"using 15 tools.",
model: openai("gpt-4o"),
tools,
});
const result = await agent.generate(
"What can I do with Chess.com?"
);
console.log(result.text);
}
main();
* Every MCP server runs on Vinkius-managed infrastructure inside AWS - a purpose-built runtime with per-request V8 isolates, Ed25519 signed audit chains, and sub-40ms cold starts optimized for native MCP execution. See our infrastructure
About Chess.com MCP Server
Connect to the Chess.com public API and explore the entire chess ecosystem through natural conversation. No authentication required — just install and start querying immediately.
Mastra's agent abstraction provides a clean separation between LLM logic and Chess.com tool infrastructure. Connect 15 tools through the Vinkius and use Mastra's built-in workflow engine to chain tool calls with conditional logic, retries, and parallel execution — deployable to any Node.js host in one command.
What you can do
- Player Profiles & Stats — Fetch any player display name, avatar, join date, follower count, plus detailed ratings across all time controls (bullet, blitz, rapid, daily) and puzzle rush scores
- Online Status — Check if a player is currently connected to Chess.com in real-time
- Game History — Retrieve all finished games for any month with full PGN data, opponent info, opening names, accuracy ratings, and game results
- Daily & Current Games — See which correspondence games a player currently has in progress
- Puzzles — Get the official daily puzzle or fetch unlimited random puzzles for tactical training
- Clubs — Explore Chess.com clubs, view member rosters, and discover community affiliations
- Leaderboards — See the highest-rated players across all game types on Chess.com
- Titled Players — Lists of GMs, IMs, FMs, WGMs, NMs, and other officially titled players
- Streamers — Find verified Chess.com content creators across Twitch, YouTube, and other platforms
- Country Players — Discover players from any nation using ISO country codes
The Chess.com MCP Server exposes 15 tools through the Vinkius. Connect it to Mastra AI in under two minutes — no API keys to rotate, no infrastructure to provision, no vendor lock-in. Your configuration, your data, your control.
How to Connect Chess.com to Mastra AI via MCP
Follow these steps to integrate the Chess.com MCP Server with Mastra AI.
Install dependencies
Run npm install @mastra/core @mastra/mcp @ai-sdk/openai
Replace the token
Replace [YOUR_TOKEN_HERE] with your Vinkius token
Run the agent
Save to agent.ts and run with npx tsx agent.ts
Explore tools
Mastra discovers 15 tools from Chess.com via MCP
Why Use Mastra AI with the Chess.com MCP Server
Mastra AI provides unique advantages when paired with Chess.com through the Model Context Protocol.
Mastra's agent abstraction provides a clean separation between LLM logic and tool infrastructure — add Chess.com without touching business code
Built-in workflow engine chains MCP tool calls with conditional logic, retries, and parallel execution for complex automation
TypeScript-native: full type inference for every Chess.com tool response with IDE autocomplete and compile-time checks
One-command deployment to any Node.js host — Vercel, Railway, Fly.io, or your own infrastructure
Chess.com + Mastra AI Use Cases
Practical scenarios where Mastra AI combined with the Chess.com MCP Server delivers measurable value.
Automated workflows: build multi-step agents that query Chess.com, process results, and trigger downstream actions in a typed pipeline
SaaS integrations: embed Chess.com as a first-class tool in your product's AI features with Mastra's clean agent API
Background jobs: schedule Mastra agents to query Chess.com on a cron and store results in your database automatically
Multi-agent systems: create specialist agents that collaborate using Chess.com tools alongside other MCP servers
Chess.com MCP Tools for Mastra AI (15)
These 15 tools become available when you connect Chess.com to Mastra AI via MCP:
get_club_info
com club by its URL identifier. Returns the club name, description, creation date, last activity date, visibility status, admin information, and total member count. Use this tool to learn about a club before joining, verify club existence, or gather metadata about chess communities. Get information about a Chess.com club
get_club_members
com club. Each entry includes the member username and their profile URL. Use this tool to discover active players within a specific club community, find potential opponents who share your chess interests, or identify titled players within a club roster. Get weekly active members of a Chess.com club
get_country_players
com players who have registered with a specific country. Takes an ISO 3166-1 country code (e.g., "US" for United States, "BR" for Brazil, "IN" for India, "RU" for Russia, "NO" for Norway). Returns an array of player usernames affiliated with that country. Use this tool to discover players from a specific nation, find local opponents, or research the chess scene in different countries. Get Chess.com players from a specific country
get_daily_puzzle
com daily puzzle including the puzzle position (FEN), the sequence of moves for the solution, the puzzle rating, and the associated game metadata (players, result, opening). Use this tool to get a tactical puzzle to solve, practice chess tactics, or study interesting positions from real games. The puzzle changes once per day. Get the Chess.com daily puzzle
get_leaderboards
com leaderboards showing the highest-rated players across different game categories. Returns top players for daily chess (correspondence), blitz, bullet, and rapid time controls, plus puzzle rush leaders. Each entry includes username, current rating, and profile URL. Use this tool to identify the strongest active players on Chess.com, track rating leaders, or find grandmaster accounts to study. Get Chess.com leaderboards for top players
get_player_clubs
com clubs that a specific player belongs to. Returns club names, URLs, creation dates, and membership counts. Use this tool to discover a player community affiliations, find clubs with similar interests, or identify potential clubs to join based on where strong players are members. Get clubs that a Chess.com player is a member of
get_player_current_games
com player. Returns game details including opponent username, current position (FEN), time control, last activity date, and game URL. Use this tool to check what ongoing games a player has, see who they are playing against in daily chess, or monitor active correspondence matches. Does not include live (real-time) games that are currently being played. Get a player's currently active daily (correspondence) games
get_player_game_archives
com player. Each URL corresponds to a specific year/month combination where the player has recorded games. Use this tool to discover which months have available game data before fetching actual games with get_player_monthly_games. The returned URLs can be parsed to extract year and month parameters. Get list of available game archive URLs for a player
get_player_monthly_games
com player during a specific year and month. Returns detailed PGN data, game results, opponent usernames, opening names, time controls, accuracy ratings (if available), and game end reasons. Use this tool to analyze a player game history, study their openings, review losses against specific opponents, or collect training data. Month is 1-indexed (January = 1, December = 12). Get all finished games for a player in a specific month
get_player_profile
com player by username. Returns the player display name, avatar URL, join date, last online timestamp, follower count, country, and title if applicable (GM, IM, FM, etc.). Use this tool to verify a username exists and gather basic identity information about a Chess.com player before querying their stats or games. Get Chess.com player profile information
get_player_stats
com player. Returns current and best ratings across all game types (chess_rapid, chess_blitz, chess_bullet, chess_daily, puzzle_rush, lessons), plus win/loss/draw records for each time control. Use this tool to evaluate a player skill level, check their peak ratings, or compare performance across different time controls. Get Chess.com player statistics including ratings and records
get_random_puzzle
com puzzle database. Returns the puzzle position (FEN), the complete solution moves, puzzle rating, and the source game information (white player, black player, result, opening name). Use this tool for unlimited tactical practice sessions, training sessions, or when you want a fresh puzzle that is not the daily puzzle. Get a random chess puzzle from Chess.com
get_streamers
com verified streamers. Each entry includes the streamer username, streaming platform (Twitch, YouTube, etc.), stream URL, language, and follower count. Use this tool to find chess content creators to watch, discover educational streams in your preferred language, or locate titled players who regularly broadcast their games. Get the list of official Chess.com streamers
get_titled_players
com players who hold a specific chess title. Supported titles include: GM (Grandmaster), IM (International Master), FM (FIDE Master), CM (Candidate Master), WGM (Woman Grandmaster), WIM (Woman International Master), WFM (Woman FIDE Master), WCM (Woman Candidate Master), NM (National Master), and LM (Legends Master). Returns an array of usernames. Use this tool to find all grandmasters on Chess.com, locate titled players for study, or verify if a player holds an official title. Get list of titled players by title type
is_player_online
com player. Returns a simple status object indicating whether the player is currently connected to Chess.com servers. Useful for determining if a daily chess opponent or streamer is actively playing right now before attempting to challenge them. Check if a Chess.com player is currently online
Example Prompts for Chess.com in Mastra AI
Ready-to-use prompts you can give your Mastra AI agent to start working with Chess.com immediately.
"Show me the current ratings and stats for chess player 'hikaru' on Chess.com."
"Get me today's daily puzzle from Chess.com."
"Show me the top 5 players on the Chess.com blitz leaderboard."
Troubleshooting Chess.com MCP Server with Mastra AI
Common issues when connecting Chess.com to Mastra AI through the Vinkius, and how to resolve them.
createMCPClient not exported
npm install @mastra/mcpChess.com + Mastra AI FAQ
Common questions about integrating Chess.com MCP Server with Mastra AI.
How does Mastra AI connect to MCP servers?
MCPClient with the server URL and pass it to your agent. Mastra discovers all tools and makes them available with full TypeScript types.Can Mastra agents use tools from multiple servers?
Does Mastra support workflow orchestration?
Connect Chess.com with your favorite client
Step-by-step setup guides for every MCP-compatible client and framework:
Anthropic's native desktop app for Claude with built-in MCP support.
AI-first code editor with integrated LLM-powered coding assistance.
GitHub Copilot in VS Code with Agent mode and MCP support.
Purpose-built IDE for agentic AI coding workflows.
Autonomous AI coding agent that runs inside VS Code.
Anthropic's agentic CLI for terminal-first development.
Python SDK for building production-grade OpenAI agent workflows.
Google's framework for building production AI agents.
Type-safe agent development for Python with first-class MCP support.
TypeScript toolkit for building AI-powered web applications.
TypeScript-native agent framework for modern web stacks.
Python framework for orchestrating collaborative AI agent crews.
Leading Python framework for composable LLM applications.
Data-aware AI agent framework for structured and unstructured sources.
Microsoft's framework for multi-agent collaborative conversations.
Connect Chess.com to Mastra AI
Get your token, paste the configuration, and start using 15 tools in under 2 minutes. No API key management needed.
