# Macaulay Library MCP

> Macaulay Library MCP Server connects your AI client directly to Cornell Lab of Ornithology's scientific media database. You can search millions of photos, audio recordings, and videos by species, location, or contributor. It retrieves deep metadata for specific assets using ML Catalog Numbers, tracks the latest global wildlife uploads, and filters massive datasets for ornithological research.

## Overview
- **Category:** image-video
- **Price:** Free
- **Tags:** ornithology, wildlife-media, ebird, nature-photography, bioacoustics

## Description

Macaulay Library MCP Server connects your AI client straight into Cornell Lab of Ornithology's massive scientific media archive. You're looking at millions of photos, audio recordings, and videos covering global wildlife—from birds to other creatures. This isn't just a search index; it's deep, structured scientific data that lets you do some serious research work with your agent.

**Searching the Archive: `search_media`**

Need to pull assets based on specific criteria? You tell the server what you need—it handles the filtering. You can search across species names (using taxon codes), pinpoint locations, track a particular contributor, or filter by media type like photo, audio, or video. If your project requires tracking all footage of one bird family from South America over the last decade, this tool is how you pull that massive dataset together.

**Getting Deep Details: `get_asset`**

When you find an asset—a perfect recording or a crucial photo—you don't just want to know it exists; you need all its technical and scientific background. By providing the unique ML Catalog Number, this tool retrieves every piece of metadata attached to that single media file. You get deep details on how it was captured, what taxonomists analyzed it, and any specific technical measurements associated with it. It’s your way to verifying the provenance and context for critical research assets.

**Tracking Global Changes: `get_recent_media`**

Monitoring global wildlife activity is a whole other ballgame. This tool lets you pull the absolute newest content that's been uploaded into the archive. You can track this feed globally, or you can narrow it down to just one country or specific region code if your research is hyper-focused. You get real-time insight into what scientists are submitting right now, letting you monitor global or regional activity feeds as they happen.

***

**How These Tools Work Together**

Your AI client uses these tools to make sense of the sheer volume of data. If you're working on a project comparing migratory patterns, your agent might first use `search_media` to find all relevant videos from a specific region and species over a ten-year span. Then, for each promising video found that meets those criteria, it uses `get_asset` to pull the detailed scientific metadata—checking out everything from recording equipment specs to associated research notes. If you suspect there's new data coming in on a particular coast, your agent can use `get_recent_media`, filtering by the appropriate country code, pulling the latest uploads for immediate review.

This setup lets you build complex query chains. You don't just get a list of files; you get structured, actionable intelligence about wildlife media. It’s built for serious ornithological research, giving your agent access to one of the most comprehensive scientific archives in the world. Don't settle for simple keyword searches—you're getting full-stack metadata retrieval across millions of assets.

## Tools

### get_asset
Retrieves all scientific and technical metadata for one specific media asset using its ML Catalog Number.

### get_recent_media
Fetches the most recently uploaded wildlife content, optionally filtered by a country or region code.

### search_media
Searches the library for assets based on criteria like species name, location, contributor, or media type.

## Prompt Examples

**Prompt:** 
```
Search for photos of the House Sparrow (houhou) in the Macaulay Library.
```

**Response:** 
```
I've found several photos of the House Sparrow (Passer domesticus). Here are the most recent assets, including ML Catalog Numbers 614523011 and 614522981, both captured recently in North America.
```

**Prompt:** 
```
Show me the most recent wildlife media uploaded from Brazil (BR).
```

**Response:** 
```
Fetching recent media from Brazil... I found 20 new assets, including a variety of bird vocalizations and photos of endemic species like the Saffron Toucanet and various Tanagers.
```

**Prompt:** 
```
Get the detailed metadata for the asset with ML Catalog Number 456789.
```

**Response:** 
```
Inspecting asset 456789... This is an audio recording of a Wood Thrush (Hylocichla mustelina) recorded by Peter Paul Kellogg. It was captured in New York, USA, and includes high-quality song phrases.
```

## Capabilities

### Search for specific assets
You specify criteria—like a species name or region—and the server returns relevant photo, audio, or video assets.

### Retrieve detailed asset information
By providing a unique ML Catalog Number, you get all the scientific and technical data associated with that single piece of media.

### Track new submissions
The server fetches the most recently uploaded wildlife content, allowing you to monitor global or regional activity feeds.

## Use Cases

### Cross-referencing species vocalizations
A student needs to compare a new recording of the Saffron Toucanet. They use `search_media` with the species code, then run `get_asset` on several returned IDs to pull metadata, verifying capture location and date for comparison.

### Tracking migratory patterns
A researcher suspects a bird's range expanded. They use `get_recent_media`, filtering by the suspected region code over the last six months. This gives them an immediate feed of new assets to analyze for shifts in biodiversity.

### Building educational content
An educator needs high-quality photos and videos of local birds. They run `search_media` using the species name and limit results by a specific state code, gathering all vetted assets into one structured list.

### Auditing media usage rights
A content creator has an asset ID (ML Catalog Number). They run `get_asset` to pull the full metadata sheet immediately. This confirms technical details, contributor info, and scientific context before publication.

## Benefits

- Find specific assets fast. Instead of browsing folders, you use `search_media` to filter by taxon code, location, or media type (photo/audio).
- Verify data quality with deep metadata. The `get_asset` tool pulls scientific details for any given ML Catalog Number—you know exactly what you're using.
- Stay current on field discoveries. Run `get_recent_media` to pull the latest uploads from specific countries, tracking global biodiversity changes in real-time.
- Saves hours of manual data collection. The server handles complex filtering (species + location + type) that used to require multiple database queries.
- Supports scientific rigor. You can build pipelines that feed structured bioacoustics and image metadata directly into your analysis models.

## How It Works

The bottom line is you get direct, programmatic access to scientific wildlife datasets without leaving your coding environment.

1. Subscribe to the Macaulay Library MCP Server and input your eBird API Token.
2. Your AI client constructs a specific query (e.g., 'Show recent videos from Brazil').
3. The server executes the tool, querying millions of records and returning structured media data directly to your agent.

## Frequently Asked Questions

**How do I find media for a specific bird species using search_media?**
You use `search_media` and provide the species' taxon code as one of the required parameters. This is much more accurate than searching by common name alone.

**What does get_asset need to run?**
It requires a single input: the ML Catalog Number. Once you have this unique ID, it pulls all available metadata for that specific piece of media.

**Can I check new uploads from Brazil using get_recent_media?**
Yes. You pass 'BR' (or the region code) to `get_recent_media`. This filters the latest global feed down to just what was recently uploaded in that country.

**Is search_media better than get_asset?**
`search_media` is for discovery—when you don't know the ID yet. `get_asset` is for verification and detail—when you already have the specific ML Catalog Number.

**Before I run `search_media`, what kind of API token do I need to connect?**
You must use an eBird API Token. This token authenticates your request and grants your agent read access to the live Macaulay data feed, ensuring you can query all three tools successfully.

**If I run `get_asset` with a Catalog Number that doesn't exist, what error should I expect?**
You will receive an HTTP 404 or similar 'Asset Not Found' status. This specific error means the ID is incorrect or the data was removed; it confirms your connection to the server works fine.

**Can I use `search_media` to filter results by both species and a specific date range?**
Yes, you pass multiple filters into the search query. You specify the taxon code *and* provide start/end dates in the parameters, narrowing down the assets significantly for targeted research.

**When I use `get_recent_media`, how do I get all results if there are thousands of uploads?**
The function supports pagination using a cursor or offset parameter. You must pass this identifier with subsequent calls to fetch the next chunk of media until the API returns an empty set.

**Can I filter my media search to only show audio recordings for a specific species?**
Yes! Use the `search_media` tool and set the `mediaType` parameter to 'a' (audio) along with the `taxonCode` for the species you are interested in.

**How do I find the most recent media uploads from a specific country like Canada?**
You can use the `get_recent_media` tool and provide the `regionCode` (e.g., 'CA' for Canada) to fetch the latest submissions from that area.

**What information can I get if I have a specific ML Catalog Number?**
By using the `get_asset` tool with the `mlCatalogNumber`, you will receive detailed metadata including species identification, location, date, contributor details, and technical specifications of the media.