a-stock-data-mcp
MCP server adapter that exposes A-share stock data tools, prompts, and resources via FastMCP, enabling querying of stocks, K-lines, financials, sectors, and market hot spots through natural language.
README
a-stock-data-mcp
MCP Server adapter for simonlin1212/a-stock-data.
The upstream project is kept as a pinned Git submodule under vendor/a-stock-data.
This project does not rewrite upstream A-share data-fetching logic; it exposes that logic through
FastMCP tools, prompts, and resources.
Install
git submodule update --init --recursive
uv sync
cp .env.example .env
Run
uv run python -m mcp_server.server
The server uses stdio. SSE and Streamable HTTP are intentionally left as future entrypoints.
Claude Desktop
{
"mcpServers": {
"a-stock-data": {
"command": "uv",
"args": [
"--directory",
"/path/to/a-stock-data-mcp",
"run",
"python",
"-m",
"mcp_server.server"
]
}
}
}
Cursor
Add the same command to Cursor MCP settings:
{
"mcpServers": {
"a-stock-data": {
"command": "uv",
"args": ["--directory", "/path/to/a-stock-data-mcp", "run", "python", "-m", "mcp_server.server"]
}
}
}
VS Code
{
"servers": {
"a-stock-data": {
"type": "stdio",
"command": "uv",
"args": ["--directory", "/path/to/a-stock-data-mcp", "run", "python", "-m", "mcp_server.server"]
}
}
}
Cherry Studio
Use a stdio MCP server:
- Command:
uv - Args:
--directory /path/to/a-stock-data-mcp run python -m mcp_server.server
Tools
- Stock:
search_stock,get_stock_quote,get_stock_basic,get_stock_news,get_stock_notice,get_stock_report - K-line:
get_daily_kline,get_weekly_kline,get_monthly_kline,get_minute_kline - Finance:
get_finance,get_income_statement,get_balance_sheet,get_cashflow,get_eps,get_roe,get_pe,get_pb - Sector:
get_industry,get_concept,get_industry_members,get_concept_members - Hot:
get_hot_rank,get_limit_up_pool,get_limit_down_pool,get_broken_limit,get_hot_concepts - Dragon tiger:
get_dragon_tiger - Money:
get_money_flow,get_main_force,get_north_money - ETF:
get_etf,get_etf_components - Index:
get_index_quote,get_index_kline - Notice and research:
get_notice,get_research_report - Analysis:
analyze_stock,analyze_market
All tools return:
{"success": true, "data": {}}
or:
{"success": false, "error": "...", "message": "..."}
Prompts
analyze_stockdaily_market_summaryanalyze_sectortoday_hot_stock
Resources
market://calendarmarket://industrymarket://conceptmarket://indexmarket://exchangemarket://etf
Configuration
.env supports:
LOG_LEVELREQUEST_TIMEOUTENABLE_CACHECACHE_TTL_QUOTECACHE_TTL_NEWSCACHE_TTL_FINANCECACHE_TTL_SECTORUSER_AGENT
Development
uv run pytest
uv run ruff check .
uv run black --check .
uv run mypy .
Notes
a-stock-data currently publishes a Markdown Skill rather than a Python package. The adapter extracts
allowlisted Python definitions from SKILL.md and ignores examples/top-level calls.
mootdx is not installed by default because current mcp and mootdx releases have incompatible
httpx dependency pins. Quote/news/finance/sector tools run without it; K-line tools are registered
and fail with a clear dependency message until upstream publishes a compatible dependency set.
Some requested MCP tools, such as ETF components or board member lists, have no exact upstream helper today. They are registered and return structured status instead of adding new scrapers outside the adapter boundary.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。