get_player_current_games
Retrieve a chess player's current ongoing games on Chess.com by providing their username.
Instructions
Get a player's ongoing games on Chess.com
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"username": "<username>"
},
"name": "get_player_current_games"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| username | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- tests/test_server.py:73-79 (helper)Unit test for get_player_current_games, testing that the function correctly calls make_api_request and returns the expected game data.
@pytest.mark.asyncio async def test_get_player_current_games(): mock_data = {"games": [{"url": "game_url"}]} with patch("chess_mcp.server.make_api_request", new=AsyncMock(return_value=mock_data)): result = await get_player_current_games("testuser") assert result == mock_data