Financial AI Agent
An AI agent providing unified access to financial market data and news articles.
š Model Context Protocol(MCP) Agent App
A TypeScript-based Ai agent with MCP integration. This project provides a unified interface to access financial market information and relevant news articles through MCP servers with tool calling.
DEMO
Terminal
https://github.com/user-attachments/assets/47150b98-0663-43f6-927e-f09abb796fe6
Cursor
https://github.com/user-attachments/assets/72210b49-dc23-4bef-b7ee-6d289ede59e1
⨠Features
- š Stock Market Data:
- Company Information
- Quarterly Financials
- Annual Financial Reports
- š° News Integration:
- Real-time News Articles
- Query-based News Search
- š ļø Architecture Components:
- Client-Server Architecture
- TypeScript Implementation
- Modular Design Pattern
- LangChain agent
š§ Prerequisites
- Node.js 16.x or higher
- TypeScript 4.x or higher
- API keys for stock services and OpenAi
š Quick Start
1. Installation
Clone and set up the project:
git clone https://github.com/extrawest/financial-ai-agent-mcp-servers
cd financial-ai-agent-mcp-servers
# Install dependencies
npm install
2. Environment Configuration
Create a .env file in the project root:
# API Configuration
STOCK_API_KEY=your_stock_api_key
OPENAI_API_KEY=your_open_ai_key
3. Build and Run
# Build the project
npm run build
# Start the server
npm start
šļø Project Structure
src/
āāā agent/
ā āāā agent.ts # Agent implementation
āāā client/
ā āāā client.ts # API client implementation
āāā config/
ā āāā configs.ts # Configuration management
āāā logger/
ā āāā logger.ts # Logging functionality
āāā server/
ā āāā news-server.ts # News API server
ā āāā stocks-server.ts # Stock market API server
āāā types/
ā āāā newsapi.d.ts # Type definitions
āāā index.ts # Application entry point
š¦ Core Components
Stock Server
Handles all stock market related operations:
- Company information retrieval
- Financial reports access
- Market data processing
News Server
Manages news-related functionality:
- Article search and retrieval
- Query processing
- News data formatting
Client
Provides a unified interface to interact with both servers:
- API request handling
- Response processing
- Error management
Start an app
In separate terminal tabs run
# Start Stocks server
npm run stocks:built
# Start News server
npm npm run news:built
# Run agent
npm run agent:built
Add mcp to Cursor IDE
- Open Cursor IDE, go to Settings -> Cursor Settings
- Go to Tools & Integrations section
- Find MCP tools, click New MCP Server
- Add this to mcp.json file
{
"mcpServers": {
"stocks-mcp-server": {
"url": "http://127.0.0.1:3000/sse"
},
"news-mcp-server": {
"url": "http://127.0.0.1:3001/sse"
}
}
}
- Run commands in separte terminal tabs
# Start Stocks server
npm run stocks:built
# Start News server
npm npm run news:built
š License
This project is licensed under the MIT License - see the LICENSE file for details.
Created by Oleksandr Samoilenko
Extrawest.com, 2025
Related Servers
ReActMCP Web Search
A web search server that integrates with the Exa API to perform basic and advanced searches.
Baidu Map
A Location-Based Service (LBS) providing geospatial APIs for geocoding, POI search, route planning, and more.
Hermes Search
Provides full-text and semantic search over structured and unstructured data using Azure Cognitive Search.
Azure AI Agent & Search
Search content using Azure AI Agent Service and Azure AI Search.
Weather MCP Server
Provides real-time weather forecasts and alerts using the National Weather Service API.
Nexus
Web search server that integrates Perplexity Sonar models via OpenRouter API for real-time, context-aware search with citations
Perigon MCP Server
Official MCP server for the Perigon API, providing access to real-time news and media data.
Yandex Search
A web search server that uses the Yandex Search API.
MCP Servers Search
Search and discover available MCP servers from the official repository.
ęęę 大ę°ę®ęå”
Provides comprehensive information queries for enterprise qualification certificates, including honors, administrative licenses, and profiles.