search_by_scientific_name
Find organisms in the ITIS database using scientific names like 'Homo sapiens' or 'Quercus' to retrieve taxonomic information and search results.
Instructions
Search for organisms by their scientific name in ITIS database.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Scientific name to search for (e.g., "Homo sapiens", "Quercus") | |
| rows | No | Number of results to return (default: 10) | |
| start | No | Starting index for pagination (default: 0) |
Implementation Reference
- src/tools.ts:289-305 (handler)MCP tool handler that executes 'search_by_scientific_name' by extracting input parameters, calling the ITISClient method, and returning a formatted JSON response with search results.case 'search_by_scientific_name': { const { name, rows, start } = args as any; const result = await itisClient.searchByScientificName(name, { rows, start }); return { content: [ { type: 'text', text: JSON.stringify({ searchTerm: name, totalResults: result.response.numFound, start: result.response.start, results: result.response.docs, }, null, 2), }, ], }; }
- src/tools.ts:47-68 (schema)Tool definition including name, description, and input schema for validation.{ name: 'search_by_scientific_name', description: 'Search for organisms by their scientific name in ITIS database.', inputSchema: { type: 'object', properties: { name: { type: 'string', description: 'Scientific name to search for (e.g., "Homo sapiens", "Quercus")', }, rows: { type: 'number', description: 'Number of results to return (default: 10)', }, start: { type: 'number', description: 'Starting index for pagination (default: 0)', }, }, required: ['name'], }, },
- src/index.ts:22-22 (registration)Registers the tool handlers on the MCP server by calling setupToolHandlers.setupToolHandlers(server, itisClient);
- src/itis-client.ts:153-158 (helper)Core helper method in ITISClient that translates the scientific name search into a SOLR query executed against the ITIS API.async searchByScientificName(name: string, options: Partial<ITISSearchOptions> = {}): Promise<ITISResponse> { return this.search({ ...options, query: `nameWInd:"${name}"`, }); }