Skip to main content
Glama
kshayk

AviBase MCP Server

by kshayk

get_birds_by_taxonomy

Retrieve bird species filtered by taxonomic classification such as Order, Family, or specific rank to identify and study related avian groups.

Instructions

Get birds filtered by taxonomic classification (Order, Family, or taxonomic rank).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
levelYesTaxonomic level to filter by
valueYesValue to filter by (e.g., "Strigiformes" for owls, "Accipitridae" for hawks)
limitNoMaximum number of results to return (default: 50)

Implementation Reference

  • The handler function that implements the tool logic: destructures args for level, value, limit; constructs API endpoint `/taxonomy/${level}/${value}`; fetches data using makeAPIRequest; computes species count; returns formatted markdown text with summary and sample records.
    async handleGetBirdsByTaxonomy(args) { const { level, value, limit = 50 } = args; const endpoint = `/taxonomy/${level}/${encodeURIComponent(value)}?limit=${limit}`; const response = await this.makeAPIRequest(endpoint); const speciesCount = response.data.filter(bird => bird.Taxon_rank === 'species').length; return { content: [ { type: 'text', text: `# ${level}: ${value} šŸ“Š **Summary:** - **Total records:** ${response.pagination.totalItems} - **Species in results:** ${speciesCount} **Sample records:** ${response.data.slice(0, 10).map((bird, i) => `${i + 1}. **${bird.Scientific_name}** (${bird.Taxon_rank}) - Common name: ${bird.English_name_AviList || 'No common name'} - Family: ${bird.Family} - Conservation: ${bird.IUCN_Red_List_Category || 'Not assessed'}`).join('\n\n')} ${response.pagination.hasNext ? `\n*Note: Showing first ${response.data.length} of ${response.pagination.totalItems} total records.*` : ''}`, }, ], }; }
  • mcp-server.js:104-127 (registration)
    Tool registration in ListToolsRequestSchema handler: defines name, description, and inputSchema specifying parameters level (enum: Order, Family, Taxon_rank), value (string), limit (number, default 50), required: level, value.
    { name: 'get_birds_by_taxonomy', description: 'Get birds filtered by taxonomic classification (Order, Family, or taxonomic rank).', inputSchema: { type: 'object', properties: { level: { type: 'string', description: 'Taxonomic level to filter by', enum: ['Order', 'Family', 'Taxon_rank'], }, value: { type: 'string', description: 'Value to filter by (e.g., "Strigiformes" for owls, "Accipitridae" for hawks)', }, limit: { type: 'number', description: 'Maximum number of results to return (default: 50)', default: 50, }, }, required: ['level', 'value'], }, },
  • mcp-server.js:294-295 (registration)
    Dispatch case in CallToolRequestSchema switch statement that routes calls to the handleGetBirdsByTaxonomy handler.
    case 'get_birds_by_taxonomy': return await this.handleGetBirdsByTaxonomy(args);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/kshayk/avibase-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server