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
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