# BEA MCP MCP

> The BEA MCP lets you pull raw, verified US economic statistics like GDP and personal income directly from the Bureau of Economic Analysis. Instead of fighting complex government APIs or downloading messy CSVs, your agent can browse all available datasets and retrieve precise historical data points right into your workflow.

## Overview
- **Category:** data-analytics
- **Price:** Free
- **Tags:** economic-data, gdp, macroeconomics, us-economy, financial-statistics

## Description

You need to track how the U.S. economy performs—from quarterly growth rates to industrial output figures. This MCP connects you straight to the Bureau of Economic Analysis’s core data sources. You just tell your agent what period, what industry, and what metric you care about. It handles finding the right dataset, figuring out which variables are needed, and pulling the raw numbers. The whole process happens conversationally. If you're using Vinkius to manage your MCP catalog, this connection gives you one reliable place for all major US macro data. You stop writing boilerplate code just to validate a table ID or figure out if 'Annual' is coded as 'A' or something else. It’s pure data access, without the headache.

## Tools

### get_dataset_list
Shows you a list of every major type of economic data set available (like NIPA or Regional).

### get_data
Pulls specific raw economic figures from a BEA dataset after you define all the needed parameters.

### get_parameter_list
Lists all possible filters and variables you can apply to a specific dataset.

### get_parameter_values
Provides the exact, valid codes for parameters (like Annual or Quarterly) so your query won't fail.

## Prompt Examples

**Prompt:** 
```
Show me all the available datasets from the Bureau of Economic Analysis.
```

**Response:** 
```
I've retrieved the list of available BEA datasets. You can access data from NIPA (National Income and Product Accounts), NIUnderlyingDetail, FixedAssets, ITA (International Transactions), and several others. Which one would you like to explore?
```

**Prompt:** 
```
What parameters do I need to query the NIPA dataset?
```

**Response:** 
```
For the NIPA dataset, you typically need the following parameters: 'TableName' or 'TableID', 'Frequency' (e.g., A for Annual, Q for Quarterly), and 'Year'. I can help you find valid values for these using the parameter values tool.
```

**Prompt:** 
```
Get the GDP data for 2023 from the NIPA dataset using Table T10101.
```

**Response:** 
```
I am fetching the data for NIPA Table T10101 for the year 2023... The data shows Real Gross Domestic Product increased at an annual rate of 2.5 percent in 2023. Would you like a breakdown by quarter?
```

## Capabilities

### List Available Data Sets
It shows you every major economic dataset available, like National Income and Product Accounts (NIPA) or Regional data.

### Find Dataset Variables
You can ask it what specific filters or variables are needed for any given dataset before attempting a query.

### Validate Data Codes
It returns lists of valid codes for parameters, so you never submit an API request with an incorrect value.

### Retrieve Raw Figures
Your agent fetches the specific economic data points—like real GDP growth—and feeds them back to your chat or script.

## Use Cases

### Comparing 2019 vs. 2023 GDP
A financial analyst needs to see how real gross domestic product changed between two years. They use `get_dataset_list` to confirm the right table, then run `get_parameter_values` to ensure they use 'Year' and 'Frequency' correctly before calling `get_data` for a direct comparison.

### Investigating Regional Income Shifts
A researcher wants all available datasets related to regional income. They ask the agent, which uses `get_dataset_list`, and then use `get_parameter_list` on the National Income data to find specific variables needed for their report.

### Validating Quarterly Data Structure
A data scientist is building a pipeline that needs quarterly (Q) figures. They call `get_parameter_values` to confirm 'Q' is the right code, ensuring their entire ML project uses consistent and validated input parameters.

### Finding all available metrics
A student just wants a broad view of what BEA has. They start with `get_dataset_list` to see every category—NIPA, Fixed Assets, etc.—giving them a starting point for research.

## Benefits

- Skip the manual CSV download. You can ask for historical GDP or income figures and get them right in your conversation using `get_data`.
- Never guess a parameter value again. The `get_parameter_values` tool confirms valid codes (like frequency: 'A' or 'Q') before you run the query, eliminating API errors.
- Quickly scope out data options by calling `get_dataset_list`. You get an overview of NIPA, Regional, and other datasets without browsing multiple websites.
- Build better models because you can automate the ingestion of government-verified economic signals. Use these figures in your analysis tool instead of relying on estimates.
- The tools let you walk through a structured process: first find available parameters with `get_parameter_list`, then check valid values, and finally pull the data.

## How It Works

The bottom line is that it takes a messy, multi-step API process and reduces it to simple, guided chat commands.

1. First, subscribe to this MCP and provide your BEA API Key. This gets your agent authenticated with the necessary access credentials.
2. Next, ask your agent to use `get_dataset_list` or `get_parameter_list`. The tool talks back, giving you a structured list of options for you to narrow down the search scope.
3. Finally, once the scope is clear, call `get_data`, providing all the validated parameters. You get clean, raw economic figures returned directly into your conversation.

## Frequently Asked Questions

**How do I start using get_dataset_list with BEA MCP?**
You simply ask your agent to list all available datasets. It will return a structured list of major categories, like NIPA or Regional data, giving you an immediate roadmap of what's possible.

**Does get_parameter_values help me avoid API errors?**
Yes, it does. Instead of guessing if 'Quarterly' is coded as Q or something else, this tool provides the exact valid code for any parameter you need to use in your query.

**What should I call when I want actual GDP data?**
You must first use `get_dataset_list` to narrow down the correct dataset, then follow up with `get_parameter_list` and finally pass all validated inputs to `get_data`.

**Is BEA MCP only for NIPA data?**
No. While NIPA is a core offering, the MCP can access multiple dataset types, including Regional and International Transaction data, so it covers most US economic areas.

**How do I get started using my API key with any BEA function?**
You must first subscribe and provide your unique BEA API Key. Your AI client needs this credential to authenticate every request, whether you're calling `get_dataset_list` or running a complex query.

**What if I don't know the required filters for get_data?**
Run `get_parameter_list` first. This tool shows all valid parameters and variables for a dataset, letting you build your full data query safely before hitting the main `get_data` function.

**When I use get_data, what format does the economic data come in?**
The output is raw, structured statistical data. Your agent receives clean key-value pairs and tables that you then analyze or pass to another system for interpretation.

**Are there limits on how often I can use get_data?**
Yes, the API enforces usage quotas; hitting these limits will cause errors. You need to manage your calls and wait for rate limit resets if you process a lot of data.

**How can I see which economic datasets are available?**
You can use the `get_dataset_list` tool. It will return a comprehensive list of all datasets currently supported by the BEA API, such as NIPA, NIUnderlyingDetail, and FixedAssets.

**How do I know what filters or parameters to use for a specific dataset?**
First, use `get_parameter_list` with the dataset name to see required fields. Then, use `get_parameter_values` to find valid inputs (like specific Year or TableID) for those parameters.

**Can I fetch actual GDP or income figures directly?**
Yes. Use the `get_data` tool. You will need to provide the dataset name and a JSON string of parameters (e.g., TableName, Frequency, Year) to retrieve the specific economic observations.