How to Use the FRED GeoFRED — Regional Economic Data MCP in LangChain
Build multi-step economic research chains in LangChain using live county, state, and MSA data straight from the Fed.
Works with every AI agent you already use
…and any MCP-compatible client
Connect FRED GeoFRED — Regional Economic Data MCP to LangChain
Create your Vinkius account to connect FRED GeoFRED — Regional Economic Data to LangChain and route execution through our secure gateway. The platform manages server hosting, runtime updates, and security layers. Configuration requires no manual server provisioning.
Discover regional series groups inside LangChain chains
`get_series_group` is the entry point for mapping national economic indicators down to local jurisdictions. Your ReAct agent calls this tool first to resolve a standard FRED series ID, like UNRATE, into its corresponding regional group ID and discover which geographic divisions are available. LangChain manages this lookup as the first step in a multi-step sequence. The output feeds directly into subsequent regional queries, ensuring your agent never wastes API tokens trying to fetch unavailable regional resolutions.
Pull raw local data for comparative analysis
`get_regional_data` pulls the actual economic metrics for states, counties, or metro areas once you have the series group ID. Your agent feeds these raw numbers directly into a database or uses them to run statistical comparisons across different regions. By combining this tool with other LangChain integrations, write the output directly to a PostgreSQL database or trigger alerts when county-level unemployment diverges from the state average. Every step of this data pipeline is visible in LangSmith, so you can trace exactly how the agent resolved the geographic parameters.
Fetch geographic boundaries for spatial mapping
`get_geo_shapes` retrieves the exact boundary coordinates for states, MSAs, and Federal Reserve districts. This tool lets your agent pair raw economic data with actual spatial boundaries for mapping. This MCP server makes it easy to assemble clean geo-data payloads. Your LangChain agent fetches the shape files, combines them with the regional values, and outputs a complete GeoJSON structure ready for your frontend mapping library.
Set up FRED GeoFRED — Regional Economic Data MCP in LangChain
Prerequisites
- Python 3.10+ installed
-
langchain-mcp-adapters+langgraphpackages - Active Vinkius subscription with a valid endpoint token
- 1
Install dependencies
Run
pip install langchain-mcp-adapters langgraph langchain-openai. The MCP adapters package converts MCP tools into native LangChainBaseToolobjects. - 2
Connect via HTTP transport
Use
MultiServerMCPClientwith"transport": "http"pointing to your Vinkius endpoint. Replace[YOUR_TOKEN_HERE]with your token from cloud.vinkius.com. - 3
Create a ReAct agent
Pass the discovered tools to
create_react_agent()from LangGraph. The agent automatically routes FRED GeoFRED — Regional Economic Data tool calls through the MCP protocol. - 4
Run with any LLM
Swap
ChatOpenAIforChatAnthropic,ChatGoogleGenerativeAI, or any LangChain-compatible model. The MCP tools work identically across all providers.
from langchain_mcp_adapters.client import MultiServerMCPClient
from langgraph.prebuilt import create_react_agent
from langchain_openai import ChatOpenAI
async with MultiServerMCPClient({
"fred-geofred-regional-economic-data-mcp": {
"transport": "http",
"url": "https://edge.vinkius.com/[YOUR_TOKEN_HERE]/mcp",
}
}) as client:
tools = client.get_tools()
agent = create_react_agent(
ChatOpenAI(model="gpt-4o"),
tools,
)
result = await agent.ainvoke({
"messages": "List recent FRED GeoFRED — Regional Economic Data transactions"
})
print(result["messages"][-1].content) Independent Platform Disclaimer: Vinkius is an independent platform and is not affiliated with, endorsed by, sponsored by, verified by, or otherwise authorized by FRED. All third-party trademarks, logos, and brand names are the property of their respective owners. Their use on this website is strictly for informational purposes to identify service compatibility and interoperability.
Why Choose Vinkius
Vinkius connects your tools to AI with real-time monitoring and automatic cost savings — all from one dashboard.
Real-time monitoring
Live
visibility into every interaction
Connect your favorite tools to your AI and see exactly what's happening — every request, every response, in real time.
Built-in savings
60%
lower AI costs
Vinkius compresses data between your apps and your AI automatically. Lower bills every month — no configuration required.
Single dashboard
One
place for every integration
Every tool your AI connects to, managed from a single screen. One account, complete control.
Common questions about FRED GeoFRED — Regional Economic Data MCP in LangChain
Use it with your favorite AI tools
Connect this server to Cursor, Claude, VS Code, and more.
Start using the FRED GeoFRED — Regional Economic Data MCP today
We host it, we monitor it, we maintain it. You just paste one token.