list_tables
Discover available FishBase tables to access marine biology data including species information, ecological data, and distribution records.
Instructions
List all available FishBase tables
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "list_tables"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/fishbase-api.ts:151-167 (handler)Core implementation of the list_tables tool, returning a hardcoded array of available FishBase table names.
async listTables(): Promise<string[]> { return [ 'species', 'ecology', 'occurrence', 'morphdat', 'comnames', 'spawning', 'diet', 'popgrowth', 'stocks', 'synonyms', 'taxa', 'estimate', 'ecosystem', ]; } - src/index.ts:257-269 (handler)MCP tool dispatch handler for list_tables, which invokes fishbaseAPI.listTables() and formats the response as JSON text.
case "list_tables": return { content: [ { type: "text", text: JSON.stringify( await fishbaseAPI.listTables(), null, 2 ), }, ], }; - src/index.ts:138-145 (schema)Tool schema definition including name, description, and empty input schema for list_tables.
{ name: "list_tables", description: "List all available FishBase tables", inputSchema: { type: "object", properties: {}, }, }, - src/index.ts:27-148 (registration)Registration of all tools including list_tables in the MCP server's listTools request handler.
server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools: [ { name: "get_species", description: "Get species information from FishBase", inputSchema: { type: "object", properties: { species_name: { type: "string", description: "Scientific name of the species (e.g., 'Salmo trutta')", }, fields: { type: "array", items: { type: "string" }, description: "Optional list of specific fields to return", }, }, required: ["species_name"], }, }, { name: "search_species", description: "Search for species by common name or partial scientific name", inputSchema: { type: "object", properties: { query: { type: "string", description: "Search term (common name or partial scientific name)", }, limit: { type: "number", description: "Maximum number of results to return (default: 20)", default: 20, }, }, required: ["query"], }, }, { name: "get_ecology", description: "Get ecological information for a species", inputSchema: { type: "object", properties: { species_name: { type: "string", description: "Scientific name of the species", }, }, required: ["species_name"], }, }, { name: "get_distribution", description: "Get distribution/occurrence information for a species", inputSchema: { type: "object", properties: { species_name: { type: "string", description: "Scientific name of the species", }, }, required: ["species_name"], }, }, { name: "get_morphology", description: "Get morphological and physiological data for a species", inputSchema: { type: "object", properties: { species_name: { type: "string", description: "Scientific name of the species", }, }, required: ["species_name"], }, }, { name: "validate_species_name", description: "Validate and correct species scientific names", inputSchema: { type: "object", properties: { species_name: { type: "string", description: "Scientific name to validate", }, }, required: ["species_name"], }, }, { name: "common_to_scientific", description: "Convert common name to scientific name", inputSchema: { type: "object", properties: { common_name: { type: "string", description: "Common name of the fish", }, }, required: ["common_name"], }, }, { name: "list_tables", description: "List all available FishBase tables", inputSchema: { type: "object", properties: {}, }, }, ], }; });