list_ucsc_genomes
Retrieve available genome assemblies from the UCSC Genome Browser database to identify species and versions for genomic analysis.
Instructions
List all UCSC Genome Browser database genomes available on the database host.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- ucsc-genome-mcp.py:358-360 (handler)Executes the 'list_ucsc_genomes' tool by constructing the UCSC API URL for '/list/ucscGenomes' with no parameters and fetching the JSON response.elif name == "list_ucsc_genomes": url = build_api_url("/list/ucscGenomes", {}) result = await make_api_request(url)
- ucsc-genome-mcp.py:108-111 (schema)Defines the input schema for the 'list_ucsc_genomes' tool, which requires no parameters (empty properties).inputSchema={ "type": "object", "properties": {} }
- ucsc-genome-mcp.py:105-112 (registration)Registers the 'list_ucsc_genomes' tool in the MCP server's tool list, including name, description, and schema.Tool( name="list_ucsc_genomes", description="List all UCSC Genome Browser database genomes available on the database host.", inputSchema={ "type": "object", "properties": {} } ),
- ucsc-genome-mcp.py:27-36 (helper)Helper function used by the handler to construct the API URL from endpoint and parameters.def build_api_url(endpoint: str, params: dict[str, Any]) -> str: """Build the complete API URL with parameters.""" # Filter out None values filtered_params = {k: v for k, v in params.items() if v is not None} # Convert parameters to URL format (using semicolons as per UCSC API spec) if filtered_params: param_str = ";".join(f"{k}={v}" for k, v in filtered_params.items()) return f"{BASE_URL}{endpoint}?{param_str}" return f"{BASE_URL}{endpoint}"
- ucsc-genome-mcp.py:39-44 (helper)Helper function used by the handler to perform the HTTP GET request and parse JSON response.async def make_api_request(url: str) -> dict[str, Any]: """Make an HTTP request to the UCSC API and return JSON response.""" async with httpx.AsyncClient(timeout=30.0) as client: response = await client.get(url) response.raise_for_status() return response.json()