MCP Market Data Server

by fintools-ai

211 downloads
Not rated
GitHub

About

Standalone server designed to deliver market data insights to AI trading agents. It processes data from external brokers and computes structured information to help LLMs and other AI systems make more informed trading decisions using JSON RPC protocol

Details

Author
fintools-ai
Downloads
211
Categories
Finance

- Volume Profile Analysis with POC and value area
- 15+ technical indicators across multiple timeframes
- Smart Zone Analysis using Fibonacci, ATR, and volume
- Opening Range Breakout (ORB) with multi-period analysis
- Async/await architecture for high performance
- Secure API key management and comprehensive logging

Use an MCP client to call the server’s tools with a stock symbol. The server provides four tools: financial_volume_profile, financial_technical_analysis, financial_technical_zones, and analyze_open_interest.

MCP Market Data Server

<div>

Python Version
License: MIT
FastMCP
Twelve Data

A powerful FastMCP server providing comprehensive financial market data analysis tools for LLM agents and trading applications.

</div>

---

🎯 Overview

The MCP Market Data Server is a production-ready financial analysis server implementing the Model Context Protocol (MCP). It provides four powerful analysis tools that deliver institutional-grade market insights:

- 🎚️ Volume Profile Analysis - Identify key support/resistance levels based on volume distribution
- 📈 Technical Analysis - Access 15+ standard indicators with multi-timeframe analysis
- 🎯 Technical Zones - Calculate high-probability price zones for precise entry/exit decisions
- 📊 ORB Analysis - Opening Range Breakout levels with multi-period analysis for intraday/0DTE trading

Perfect for algorithmic trading, quantitative analysis, and AI-powered trading agents.

✨ Features

📊 Multi-Timeframe Analysis

- ⏱️ 1-minute: Scalping and micro-movements - ⏱️ 5-minute: Intraday swing trading - ⏱️ 1-day: Position trading and trend analysis

📈 Volume Profile Intelligence

- 🎯 Point of Control (POC) identification - 📊 Value Area High/Low (VAH/VAL) calculations - 🔥 High/Low Volume Node detection - 💹 Volume dynamics and momentum analysis - 📈 Upside probability assessment

🔧 Technical Indicators Suite

- Moving Averages: SMA (20, 50, 200), EMA (20), VWAP - Momentum: RSI, MACD, Stochastic Oscillator - Volatility: ATR (Average True Range) - Volume: OBV, CMF, Volume Rate of Change - Advanced: Ichimoku Cloud, Trend Strength Analysis - Patterns: Divergence Detection

🎯 Smart Zone Analysis

- 📐 Fibonacci retracement/extension levels - 📅 Previous day high/low levels - 📊 ATR-based volatility zones - 🎚️ Volume Profile derived zones - 🎨 Zone strength classification

📊 Opening Range Breakout (ORB)

- ⏱️ Multi-period analysis (5, 15, 30 minutes) - 🎯 Breakout confirmation with volume - 📈 Extension targets (0.5x, 1x, 1.5x, 2x) - 🔍 ORB squeeze detection - 📡 Trading bias analysis

🚀 Enterprise Features

- ⚡ Async/await architecture for high performance - 🔒 Secure API key management - 🏗️ Modular, extensible design - 📝 Comprehensive logging and error handling - 🧪 Full test coverage - 📋 Type hints throughout

---

📖 API Reference

🎚️ financial_volume_profile

Analyzes volume distribution across price levels to identify key trading zones.

Request:

{
"tool": "financial_volume_profile",
"symbol": "AAPL"
}

Response:

{
"symbol": "AAPL",
"status": "success",
"timeframe_volume_profile": {
"5m": {
"volume_profile_structure": {
"point_of_control": 150.25,
"value_area_high": 151.80,
"value_area_low": 149.10,
"high_volume_nodes": [...],
"low_volume_nodes": [...]
},
"volume_dynamics": {
"supports_continued_upside": true,
"volume_supports_upside_probability": 75.5,
"volume_trend": "increasing",
"volume_bias": "bullish"
}
}
},
"consolidated_analysis": {
"supports_continued_upside": true,
"confidence": "high"
}
}

📈 financial_technical_analysis

Provides comprehensive technical indicators across multiple timeframes.

Request:

{
"tool": "financial_technical_analysis",
"symbol": "MSFT"
}

Response:

{
"symbol": "MSFT",
"status": "success",
"timeframe_indicators": {
"1d": {
"indicators": {
"current_price": 380.50,
"sma_20": 375.20,
"sma_50": 370.15,
"rsi": 65.2,
"macd": {
"macd": 2.34,
"signal": 1.98,
"histogram": 0.36
},
"atr": 8.45,
"vwap": 379.80
},
"trend_analysis": {
"trend": "uptrend",
"strength": "moderate"
}
}
}
}

🎯 financial_technical_zones

Identifies precise support/resistance zones using multiple methodologies.

Request:

{
"tool": "financial_technical_zones",
"symbol": "GOOGL"
}

Response:

{
"symbol": "GOOGL",
"status": "success",
"timeframe_zones": {
"5m": {
"zones": [
{
"type": "SUPPORT",
"level": 142.50,
"strength": "strong",
"source": "Volume Profile POC",
"confidence": 85
},
{
"type": "RESISTANCE",
"level": 145.80,
"strength": "moderate",
"source": "Previous Day High",
"confidence": 70
}
]
}
}
}

📊 analyze_open_interest

Analyzes Opening Range Breakout patterns for intraday and 0DTE trading strategies.

Request:

{
"tool": "analyze_open_interest",
"symbol": "SPY"
}

Response:

{
"symbol": "SPY",
"status": "success",
"timestamp": "2024-03-15T14:30:00Z",
"market_session": "regular_hours",
"current_price": 425.50,
"orb_analysis": {
"5min": {
"orb_high": 424.75,
"orb_low": 424.25,
"orb_range": 0.50,
"position": "above_range",
"breakout_confirmed": true,
"breakout_type": "bullish",
"volume_analysis": {
"volume_ratio_vs_day_avg": 1.35,
"high_volume": true
},
"targets": {
"bull_1x": 425.25,
"bear_1x": 423.75
},
"targets_hit": ["bull_0.5x", "bull_1x"]
}
},
"trading_bias": {
"bias": "bullish",
"confidence": "high",
"strength_factors": [
"5min bullish breakout confirmed",
"5min high volume above range"
]
},
"orb_squeeze": {
"squeeze_detected": false,
"compression_ratio": 0.95
}
}

---

🎯 Usage Examples

Basic Analysis

```python
No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.