get_wca_continents
Retrieve the complete list of continents recognized by the World Cube Association for regional filtering in speedcubing data analysis.
Instructions
Get all WCA continents.
Returns a list of all continents recognized by the World Cube Association including continent names and identifiers used for regional filtering.
Returns: List of WCA continents with names and identifiers
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Input Schema (JSON Schema)
{
"properties": {},
"type": "object"
}
Implementation Reference
- src/wca_mcp_server/main.py:68-85 (handler)The handler function for the 'get_wca_continents' tool. It is registered via the @mcp.tool() decorator and fetches continents using WCAAPIClient.get_continents().@mcp.tool() async def get_wca_continents() -> List[Dict[str, Any]]: """Get all WCA continents. Returns a list of all continents recognized by the World Cube Association including continent names and identifiers used for regional filtering. Returns: List of WCA continents with names and identifiers """ try: async with WCAAPIClient() as client: continents = await client.get_continents() return continents except APIError as e: raise Exception(f"Failed to fetch WCA continents: {e}") except Exception as e: raise Exception(f"Unexpected error fetching WCA continents: {e}")
- src/wca_mcp_server/client.py:327-337 (helper)The supporting method in WCAAPIClient that implements the core logic by requesting 'continents.json' from the WCA API and processing the response.async def get_continents(self) -> List[Dict[str, Any]]: """Get all continents. Returns: List of continent data """ data = await self._make_request("continents.json") # The API returns paginated data with items array if isinstance(data, dict) and "items" in data: return data["items"] return data.get("continents", [])