
A stateless streamable HTTP MCP server for interacting with the official source of government spending data.

A Model Context Protocol server that delivers real-time order flow analysis, connecting to market data brokers via gRPC to provide institutional-grade market microstructure insights.
MCP Order Flow Server is cataloged as an MCP server attributed to fintools-ai. A Model Context Protocol server that delivers real-time order flow analysis, connecting to market data brokers via gRPC to provide institutional-grade market microstructure insights. It is categorized under finance crypto. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.
Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.
Catalog license label: Not specified. Check the source repository's current license and terms before using, modifying or distributing this software.
能力定义尚未审核。未核验的采集内容不会作为可信接口展示。
暂无可展示的已审核记录。这不表示上游不支持此能力。
暂无可展示的已审核记录。这不表示上游不支持此能力。
暂无可展示的已审核记录。这不表示上游不支持此能力。
Email delivery is not connected. This page does not collect email addresses or create subscriptions.
Browse the registry for current listings instead.
Reviews for MCP Order Flow Server are not available yet
Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.
The tool takes a required ticker symbol such as SPY or QQQ and an optional history window defaulting to 5mins, with examples including 30s, 10mins, and 1h.
Yes; include_patterns defaults to true but can be disabled so pattern detection is excluded from the response.
The server supports gRPC for production and Redis as a development or fallback data source, selected through the DATA_SOURCE environment variable.
README.md · 19e5e2454940 · 采集于 2026-11-13 12:37:41 UTC
保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。
当前显示最后一次成功采集的文档快照,请以来源页面为准。
A high-performance Model Context Protocol (MCP) server that provides real-time order flow analysis for algorithmic trading applications. This server connects to market data brokers via gRPC to deliver institutional-grade market microstructure insights.
Clone the repository:
git clone <repository-url>
cd mcp-order-flow-server
Install dependencies:
pip install -r requirements.txt
Generate protobuf files (if using gRPC data source):
./generate_proto.sh
Configure environment (optional):
export DATA_BROKER_GRPC_URL=localhost:9090
export LOG_LEVEL=INFO
Start the server:
python src/mcp_server.py
analyze_order_flow_toolThe server exposes a single MCP tool for order flow analysis:
| Parameter | Type | Default | Description |
|---|---|---|---|
ticker | string | required | Stock/ETF ticker symbol (e.g., "SPY", "QQQ") |
history | string | "5mins" | Analysis time window (e.g., "30s", "10mins", "1h") |
include_patterns | boolean | true | Include pattern detection in response |
{
"method": "tools/call",
"params": {
"name": "analyze_order_flow_tool",
"arguments": {
"ticker": "SPY",
"history": "5mins",
"include_patterns": true
}
}
}
<order_flow_data ticker="SPY" timestamp="2024-01-15T10:30:00" current_price="485.24">
<data_summary>
<quote_count>1847</quote_count>
<history_window>300s</history_window>
<pattern_count>3</pattern_count>
</data_summary>
<current_quote>
<bid_price>485.230</bid_price>
<ask_price>485.250</ask_price>
<bid_size>1800</bid_size>
<ask_size>1200</ask_size>
<spread>0.020</spread>
</current_quote>
<metrics window="10s">
<momentum>
<bid_movement>0.050</bid_movement>
<ask_movement>0.045</ask_movement>
<bid_lifts>3</bid_lifts>
<ask_lifts>2</ask_lifts>
</momentum>
<size_dynamics>
<avg_bid_size>1650</avg_bid_size>
<avg_ask_size>1250</avg_ask_size>
<large_bids>1</large_bids>
<large_asks>0</large_asks>
</size_dynamics>
<behaviors>
<bid_stacking>YES</bid_stacking>
<momentum_building>YES</momentum_building>
</behaviors>
</metrics>
<significant_levels>
<bid_levels>
<level price="485.20" appearances="15" total_size="45000" />
<level price="485.15" appearances="12" total_size="38000" />
</bid_levels>
<ask_levels>
<level price="485.30" appearances="12" total_size="38000" />
<level price="485.35" appearances="9" total_size="28000" />
</ask_levels>
</significant_levels>
<detected_patterns>
<pattern type="absorption">
<subtype>bullish</subtype>
<strength>strong</strength>
<description>Strong bid absorption at 485.20</description>
</pattern>
</detected_patterns>
</order_flow_data>
# Data source configuration
DATA_SOURCE=grpc # Use 'grpc' (recommended) or 'redis'
DATA_BROKER_GRPC_URL=localhost:9090 # gRPC endpoint for market data
# Redis fallback (if DATA_SOURCE=redis)
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_DB=0
# Logging
LOG_LEVEL=INFO # DEBUG, INFO, WARNING, ERROR
| Source | Latency | Throughput | Use Case |
|---|---|---|---|
| gRPC | 0.1-0.5ms | 2000+ req/s | Production (Recommended) |
| Redis | 0.5-2ms | 500+ req/s | Development/Fallback |
┌─────────────────┐ ┌──────────────────┐ ┌───────────────────┐
│ MCP Client │───▶│ MCP Server │───▶│ Market Data │
│ (AI Agent) │ │ (This Repo) │ │ Broker (gRPC) │
└─────────────────┘ └──────────────────┘ └───────────────────┘
│
▼
┌──────────────────┐
│ Order Flow │
│ Analysis Engine │
└──────────────────┘
mcp-order-flow-server/
├── src/
│ ├── mcp_server.py # Main MCP server entry point
│ ├── config.py # Configuration management
│ ├── proto/ # Generated protobuf files
│ ├── storage/
│ │ ├── grpc_client.py # gRPC data client
│ │ └── redis_client.py # Redis fallback client
│ ├── formatters/
│ │ └── state_manager.py # XML response formatting
│ └── tools/
│ └── order_flow_tool.py # MCP tool implementation
├── generate_proto.sh # Protobuf generation script
├── test_tool.py # Development testing
└── requirements.txt # Python dependencies
# Run development tests
python test_tool.py
# Test specific ticker
python -c "
import asyncio
from src.tools.order_flow_tool import analyze_order_flow
result = asyncio.run(analyze_order_flow('SPY', '1min', True))
print(result)
"
If the market data broker's protobuf definitions change:
./generate_proto.sh
include_patterns=false)The server provides detailed error responses for common issues:
<order_flow_data ticker="INVALID" error="true">
<error_message>No data available for ticker</error_message>
<possible_causes>
<cause>Invalid ticker symbol</cause>
<cause>Market data broker not running</cause>
<cause>Network connectivity issues</cause>
</possible_causes>
<suggestions>
<suggestion>Verify ticker symbol is correct</suggestion>
<suggestion>Check market data broker status</suggestion>
<suggestion>Ensure network connectivity</suggestion>
</suggestions>
</order_flow_data>
Claim this server with your GitHub account to request manual ownership verification.
Link to the catalog listing for MCP Order Flow Server from your README. This badge does not certify ownership, compatibility or security.
[](https://awesome-mcp.com/servers/mcp-order-flow-server)Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.
来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。
尚无已审核的包 / 镜像标识,暂不展示下载统计。
Alternative and complementary servers in the same category

A stateless streamable HTTP MCP server for interacting with the official source of government spending data.

A hosted, remote MCP server for Fortnox that lets AI assistants answer questions from a company's bookkeeping and propose changes for approval before writing them.

OptimistFi is a read-only remote MCP server that provides perpetual futures market data, perps prop firm rules and pricing, and US equity investment research.