基于雪球API的MCP服务,让您通过Claude或其他AI助手轻松获取股票数据
Project description
Snowball MCP (雪球 MCP)
基于雪球API的MCP服务,让您通过Claude或其他AI助手轻松获取股票数据。
项目简介
本项目基于pysnowball封装了雪球API,并通过MCP协议提供服务,使您能够在Claude等AI助手中直接查询股票数据。
安装方法
方式一:在线安装(推荐)✨
无需克隆仓库,直接使用 uvx 运行:
# 设置环境变量
export XUEQIU_TOKEN="xq_a_token=xxxxx;u=xxxx"
# 直接运行
uvx snowball-mcp
方式二:Claude Desktop / Cursor / MCPHub 配置
在 MCP 客户端配置文件中添加:
{
"mcpServers": {
"snowball-mcp": {
"command": "uvx",
"args": ["snowball-mcp"],
"env": {
"XUEQIU_TOKEN": "xq_a_token=xxxxx;u=xxxx"
}
}
}
}
方式三:本地开发安装
# 克隆仓库
git clone https://github.com/xunzhimeng/xueqiu_mcp.git
cd xueqiu_mcp
# 使用uv安装依赖
uv pip install -e .
# 创建 .env 文件配置 token
echo 'XUEQIU_TOKEN="xq_a_token=xxxxx;u=xxxx"' > .env
# 运行
snowball-mcp
配置雪球Token
关于如何获取雪球token,请参考pysnowball文档。
功能特性
- 获取股票实时行情
- 获取K线数据(支持日/周/月/季/年线和分钟级数据)
- 查询指数收益
- 获取深港通/沪港通北向数据
- 基金相关数据查询
- 关键词搜索股票代码
- 财务报表数据(利润表、资产负债表、现金流量表等)
- 资金流向数据
- 融资融券数据
- 大宗交易数据
- 机构评级和持仓数据
展示图
致谢
本项目 fork 自 liqiongyu/xueqiu_mcp,在此基础上进行了改进和优化。
- liqiongyu/xueqiu_mcp - 原始项目
- pysnowball - 雪球股票数据接口的Python版本
- fastmcp - MCP服务框架
许可证
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file snowball_mcp-0.2.2.tar.gz.
File metadata
- Download URL: snowball_mcp-0.2.2.tar.gz
- Upload date:
- Size: 486.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
939e1c61bae661b85c6aef12aeef29810626a8cdd1752de55524672a1487897f
|
|
| MD5 |
53bb4e8eb7f395e5ece658df9ed086c4
|
|
| BLAKE2b-256 |
e42a067b181c25dbbc508374d3f7e76219dac7baa172eb02b9aeaa651ac6bede
|
Provenance
The following attestation bundles were made for snowball_mcp-0.2.2.tar.gz:
Publisher:
publish.yml on xunzhimeng/xueqiu_mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
snowball_mcp-0.2.2.tar.gz -
Subject digest:
939e1c61bae661b85c6aef12aeef29810626a8cdd1752de55524672a1487897f - Sigstore transparency entry: 747174168
- Sigstore integration time:
-
Permalink:
xunzhimeng/xueqiu_mcp@81538991ec699b345cceca9865e91dfe1083fe56 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/xunzhimeng
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@81538991ec699b345cceca9865e91dfe1083fe56 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file snowball_mcp-0.2.2-py3-none-any.whl.
File metadata
- Download URL: snowball_mcp-0.2.2-py3-none-any.whl
- Upload date:
- Size: 7.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c6c415e17269bbe9834c1812ddbac0ff74efa66788e259a75aeb6e9574176d9b
|
|
| MD5 |
5f3d37deb68b6a8b3627e42374cca62e
|
|
| BLAKE2b-256 |
50fabefe05e3505b228e0eb46ee7021210ad9b88791e7f3ab5446646a89b6425
|
Provenance
The following attestation bundles were made for snowball_mcp-0.2.2-py3-none-any.whl:
Publisher:
publish.yml on xunzhimeng/xueqiu_mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
snowball_mcp-0.2.2-py3-none-any.whl -
Subject digest:
c6c415e17269bbe9834c1812ddbac0ff74efa66788e259a75aeb6e9574176d9b - Sigstore transparency entry: 747174175
- Sigstore integration time:
-
Permalink:
xunzhimeng/xueqiu_mcp@81538991ec699b345cceca9865e91dfe1083fe56 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/xunzhimeng
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@81538991ec699b345cceca9865e91dfe1083fe56 -
Trigger Event:
workflow_dispatch
-
Statement type: