Provides scripts to fetch Hong Kong stock market data including real-time quotes, financials, southbound capital flows, FX rates, and macroeconomic indicators. All data sources are free and require no API keys.
Ships in yuping322-finskills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
自包含的数据工具包,提供港股市场实时金融数据和定量计算。所有数据源免费,无需API密钥。
安装依赖(一次性):
pip install -r requirements.txt
所有脚本位于 scripts/ 目录。从技能根目录运行。
scripts/hk_stock_data.py)获取港股实时行情、历史数据和基本信息。
| 命令 | 用途 |
|---|---|
python scripts/hk_stock_data.py 00700 | 腾讯控股基本信息 |
python scripts/hk_stock_data.py 00700 --price | 实时价格和历史数据 |
python scripts/hk_stock_data.py 00700 --financial | 财务指标和估值数据 |
python scripts/hk_stock_data.py 00700 --dividend | 股息历史和分红信息 |
scripts/southbound_flow.py)获取南向资金流向和持仓数据。
| 命令 | 用途 |
|---|---|
python scripts/southbound_flow.py --daily | 每日南向资金流向 |
python scripts/southbound_flow.py --holdings | 南向资金持仓明细 |
python scripts/southbound_flow.py --sector | 行业资金流向分析 |
python scripts/southbound_flow.py --top | 净买入/卖出TOP榜 |
scripts/hk_financials.py)获取港股财务报表和财务指标。
| 命令 | 用途 |
|---|---|
python scripts/hk_financials.py 00700 --income | 损益表数据 |
python scripts/hk_financials.py 00700 --balance | 资产负债表 |
python scripts/hk_financials.py 00700 --cashflow | 现金流量表 |
python scripts/hk_financials.py 00700 --ratios | 财务比率分析 |
scripts/fx_data.py)获取港币汇率和相关数据。
| 命令 | 用途 |
|---|---|
python scripts/fx_data.py HKD --spot | 港币即期汇率 |
python scripts/fx_data.py HKD --forward | 远期汇率 |
python scripts/fx_data.py HKD --history | 历史汇率走势 |
python scripts/fx_data.py HKD --volatility | 汇率波动率 |
scripts/hk_macro.py)获取香港宏观经济指标。
| 命令 | 用途 |
|---|---|
python scripts/hk_macro.py --gdp | GDP数据 |
python scripts/hk_macro.py --cpi | CPI通胀数据 |
python scripts/hk_macro.py --unemployment | 失业率数据 |
python scripts/hk_macro.py --interest | 利率数据 |
scripts/hk_etf.py)获取港股ETF相关数据。
| 命令 | 用途 |
|---|---|
python scripts/hk_etf.py --list | ETF列表和基本信息 |
python scripts/hk_etf.py 02800 --holdings | ETF持仓明细 |
python scripts/hk_etf.py 02800 --flow | ETF资金流向 |
python scripts/hk_etf.py --performance | ETF表现分析 |
{
"symbol": "00700.HK",
"name": "腾讯控股",
"price": {
"current": 320.5,
"change": 5.2,
"change_pct": 1.65
},
"market_cap": 3072000000000,
"pe_ratio": 18.5,
"dividend_yield": 0.85,
"timestamp": "2026-02-15 16:00:00"
}
{
"symbol": "00700.HK",
"financials": {
"revenue": 560118000000,
"net_profit": 115219000000,
"eps": 12.0,
"roe": 0.156,
"debt_ratio": 0.234
},
"period": "2024Q3",
"currency": "HKD"
}
{
"error": "Invalid stock code",
"message": "Stock code 99999.HK not found",
"suggestion": "Please check the stock code format"
}
from scripts.hk_stock_data import get_stock_info
# 获取腾讯控股信息
info = get_stock_info("00700")
print(f"当前价格: {info['price']['current']} HKD")
print(f"市值: {info['market_cap']:,} HKD")
from scripts.southbound_flow import get_daily_flow
# 获取最近5天南向资金流向
for i in range(5):
flow_data = get_daily_flow(days_back=i)
print(f"第{i+1}天净流入: {flow_data['net_flow']:,} HKD")
# 可选:设置代理(如果需要)
export HTTP_PROXY=http://proxy.example.com:8080
export HTTPS_PROXY=http://proxy.example.com:8080
# 可选:设置缓存目录
export HK_DATA_CACHE=/path/to/cache
{
"data_sources": {
"hkex": {
"base_url": "https://www.hkex.com.hk",
"timeout": 30
},
"cache": {
"enabled": true,
"ttl": 300
}
}
}
HK Market Data Toolkit - 专业的港股数据获取工具
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/yuping322-finskills:findata-toolkit-hkfrom yuping322-finskills
yuping322-finskills@fin-skills is listed by howard-lynn-ye/fin-rsi — review the source before installing
npx claudepluginhub howard-lynn-ye/fin-rsi --plugin yuping322-finskills107 skills in this plugin
/ab-ah-premium-monitor跟踪 AB 股比价与 A+H 溢价/折价,并结合流动性与事件因素给出风险提示。当用户询问AB股比价、A+H溢价、跨市场定价差或需要溢价监控时使用。/block-deal-monitor跟踪并解读A股大宗交易(折溢价、买卖方、金额、连续性),用于识别潜在建仓/派发、短期抛压与承接强弱,并输出可执行的跟踪清单与风控规则。当用户询问大宗交易、折价率、大额成交、机构接盘、或想用大宗交易做信号时使用。/bse-selection-analyzer扫描与分析北交所(BSE)标的,按流动性、成长性、行业景气与“专精特新”特征输出候选清单,并给出流动性与波动风险提示。当用户询问北交所精选、北交所选股、专精特新筛选、或需要北交所板块研究时使用。/buyback-monitorAnalyze share repurchases (authorization, pace, dilution vs buybacks) and capital return sustainability. Use when the user asks about buybacks, shareholder yield, or capital return analysis.Other plugins' skills for the same job