investing

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Investing.com — Datos via HTML Scrape

Investing.com — 通过HTML抓取数据

Skill para extraer datos de Investing.com parseando el HTML publico. Sin API key, sin autenticacion.

本工具通过解析公开HTML从Investing.com提取数据,无需API密钥,无需身份验证。

⚠️ Aviso Legal y Tecnico

⚠️ 法律与技术声明

  • Investing.com no expone API publica. Los datos se extraen de las paginas HTML con Cloudflare bot protection.
  • Dependencia obligatoria:
    curl_cffi
    (impersona Chrome 120 a nivel TLS —
    requests
    puro devuelve el challenge de Cloudflare, no datos).
  • Rate limit agresivo: respetar 1-2 segundos entre requests. Cloudflare devuelve 429/403 si se hacen muchas requests muy rapido. El script reintenta con backoff automatico.
  • Datos delayed: el precio mostrado en la pagina es el del ultimo cierre disponible (15-20 min de delay para US equities, similar para otros).
  • Respetar terminos de servicio de Investing.com. No hacer mas de 1-2 requests/segundo. No usar para redistribuir masivamente.
  • Investing.com se reserva el derecho de bloquear rangos de IP. El skill puede dejar de funcionar en cualquier momento.

  • Investing.com 未提供公开API。数据通过抓取带有Cloudflare反机器人保护的HTML页面获取。
  • 强制依赖库:
    curl_cffi
    (在TLS层面模拟Chrome 120 — 纯
    requests
    库会返回Cloudflare验证页面,无法获取数据)。
  • 严格速率限制: 请求间隔需保持1-2秒。短时间内发送大量请求会触发Cloudflare的429/403错误。脚本会自动进行退避重试。
  • 数据延迟: 页面显示的价格为最近一次收盘数据(美股延迟15-20分钟,其他品种类似)。
  • 请遵守Investing.com的服务条款,每秒请求不超过1-2次,不得用于大规模数据分发。
  • Investing.com有权封禁IP段,本工具可能随时停止工作。

Scripts

脚本

ScriptDescripcion
fetch_investing.pyScript principal: todos los modos disponibles

脚本描述
fetch_investing.py主脚本:包含所有可用模式

Instalacion de dependencias

依赖库安装

bash
pip install curl_cffi
NO funciona con
requests
puro. Cloudflare detecta y bloquea.

bash
pip install curl_cffi
requests
库无法使用,会被Cloudflare检测并拦截。

Uso rapido

快速使用

bash
undefined
bash
undefined

=== COTIZACIONES (auto-detect tipo) ===

=== 报价(自动检测类型) ===

python scripts/fetch_investing.py quote gold python scripts/fetch_investing.py quote eur-usd python scripts/fetch_investing.py quote us-spx-500 python scripts/fetch_investing.py quote bitcoin python scripts/fetch_investing.py quote ypf-sa --type equities python scripts/fetch_investing.py quote apple-computer-inc -q
python scripts/fetch_investing.py quote gold python scripts/fetch_investing.py quote eur-usd python scripts/fetch_investing.py quote us-spx-500 python scripts/fetch_investing.py quote bitcoin python scripts/fetch_investing.py quote ypf-sa --type equities python scripts/fetch_investing.py quote apple-computer-inc -q

=== BUSQUEDA EN SITEMAPS ===

=== 站点地图搜索 ===

python scripts/fetch_investing.py search YPF python scripts/fetch_investing.py search gold --category commodities python scripts/fetch_investing.py search MERVAL --category indices python scripts/fetch_investing.py search AR --category currencies --limit 30
python scripts/fetch_investing.py search YPF python scripts/fetch_investing.py search gold --category commodities python scripts/fetch_investing.py search MERVAL --category indices python scripts/fetch_investing.py search AR --category currencies --limit 30

=== SITEMAPS COMPLETOS ===

=== 完整站点地图 ===

python scripts/fetch_investing.py sitemap commodities # 344 instrumentos python scripts/fetch_investing.py sitemap currencies # 2,394 cruces python scripts/fetch_investing.py sitemap indices # 20K+ indices python scripts/fetch_investing.py sitemap equities # 81K+ acciones python scripts/fetch_investing.py sitemap etfs # 30K+ ETFs
python scripts/fetch_investing.py sitemap commodities # 344种工具 python scripts/fetch_investing.py sitemap currencies # 2394种货币对 python scripts/fetch_investing.py sitemap indices # 20000+种指数 python scripts/fetch_investing.py sitemap equities # 81000+支股票 python scripts/fetch_investing.py sitemap etfs # 30000+支ETF

=== HISTORICO OHLCV ===

=== OHLCV历史数据 ===

python scripts/fetch_investing.py historical gold python scripts/fetch_investing.py historical eur-usd python scripts/fetch_investing.py historical ypf-sa --pages 5 # ~115 dias python scripts/fetch_investing.py historical apple-computer-inc
python scripts/fetch_investing.py historical gold python scripts/fetch_investing.py historical eur-usd python scripts/fetch_investing.py historical ypf-sa --pages 5 # ~115天 python scripts/fetch_investing.py historical apple-computer-inc

=== FUNDAMENTALS ===

=== 基本面数据 ===

python scripts/fetch_investing.py profile apple-computer-inc python scripts/fetch_investing.py financials apple-computer-inc --ftype income python scripts/fetch_investing.py financials apple-computer-inc --ftype balance python scripts/fetch_investing.py financials apple-computer-inc --ftype cashflow python scripts/fetch_investing.py ratios apple-computer-inc python scripts/fetch_investing.py dividends apple-computer-inc python scripts/fetch_investing.py earnings apple-computer-inc
python scripts/fetch_investing.py profile apple-computer-inc python scripts/fetch_investing.py financials apple-computer-inc --ftype income python scripts/fetch_investing.py financials apple-computer-inc --ftype balance python scripts/fetch_investing.py financials apple-computer-inc --ftype cashflow python scripts/fetch_investing.py ratios apple-computer-inc python scripts/fetch_investing.py dividends apple-computer-inc python scripts/fetch_investing.py earnings apple-computer-inc

=== GUARDAR A ARCHIVO ===

=== 保存到文件 ===

python scripts/fetch_investing.py quote gold -o gold_quote.json python scripts/fetch_investing.py historical ypf-sa -o ypf_hist.json
python scripts/fetch_investing.py quote gold -o gold_quote.json python scripts/fetch_investing.py historical ypf-sa -o ypf_hist.json

=== MODO SILENCIOSO (solo JSON, sin logs) ===

=== 静默模式(仅输出JSON,无日志) ===

python scripts/fetch_investing.py quote gold -q

---
python scripts/fetch_investing.py quote gold -q

---

Modos disponibles

可用模式

ModoDataEndpoint
quote
Cotizacion (precio, cambio, OHLC, volume, pair_id)
www.investing.com/{type}/{slug}
search
Busqueda fuzzy sobre sitemaps publicosSitemap XMLs
sitemap
Descarga sitemap completo (URLs de instrumentos)Sitemap XMLs
historical
Historico OHLCV desde la tabla HTML
/{type}/{slug}-historical-data
profile
Descripcion, sector, industria, pais, sede, empleados
/{type}/{slug}-company-profile
financials
Income / Balance / Cash Flow (TTM + ultimos 5 anios)
/{type}/{slug}-income-statement
etc.
ratios
Margenes, retornos, valuation ratios
/{type}/{slug}-ratios
dividends
Historial completo de dividendos
/{type}/{slug}-dividends
earnings
Earnings history (EPS real vs estimado)
/{type}/{slug}-earnings

模式数据内容端点
quote
报价(价格、涨跌幅、OHLC、成交量、pair_id)
www.investing.com/{type}/{slug}
search
基于公开站点地图的模糊搜索站点地图XML
sitemap
下载完整站点地图(工具URL)站点地图XML
historical
从HTML表格获取OHLCV历史数据
/{type}/{slug}-historical-data
profile
公司描述、行业、产业、国家、总部、员工数
/{type}/{slug}-company-profile
financials
利润表/资产负债表/现金流量表(TTM+最近5年)
/{type}/{slug}-income-statement
ratios
利润率、回报率、估值比率
/{type}/{slug}-ratios
dividends
完整股息历史
/{type}/{slug}-dividends
earnings
收益历史(实际EPS vs 预期EPS)
/{type}/{slug}-earnings

Tipos de instrumentos

工具类型

Tipo
--type
Slug exampleCobertura
Equity (stock/ADR)
equities
apple-computer-inc
,
ypf-sa
,
ggal
81,518
Commodity
commodities
gold
,
crude-oil
,
brent-oil
344
Indice
indices
us-spx-500
,
ibovespa
,
dax
20,000+
Currency pair (forex)
currencies
eur-usd
,
usd-ars
,
brl-usd
2,394
ETF
etfs
spdr-s-p-500
,
vanguard-ftse-all-world
30,000+
Crypto
crypto
bitcoin
,
ethereum
4,135+ coins, 20K+ pairs
Tasa / Bono
rates-bonds
(no en sitemap directo)20,000+
Fondo
funds
(no en sitemap directo)100K+
Certificado
certificates
(no en sitemap directo)6,222
Auto-deteccion: si no pasas
--type
, el script prueba commodities → currencies → indices → etfs → crypto → equities. Las equities son las mas lentas/rate-limited, asi que se prueban al final.

类型
--type
参数
Slug示例覆盖数量
股票(普通股/ADR)
equities
apple-computer-inc
,
ypf-sa
,
ggal
81518
大宗商品
commodities
gold
,
crude-oil
,
brent-oil
344
指数
indices
us-spx-500
,
ibovespa
,
dax
20000+
货币对(外汇)
currencies
eur-usd
,
usd-ars
,
brl-usd
2394
ETF
etfs
spdr-s-p-500
,
vanguard-ftse-all-world
30000+
加密货币
crypto
bitcoin
,
ethereum
4135+种代币,20000+种交易对
利率/债券
rates-bonds
(不在直接站点地图中)20000+
基金
funds
(不在直接站点地图中)100000+
凭证
certificates
(不在直接站点地图中)6222
自动检测: 如果不传入
--type
参数,脚本会按以下顺序尝试:大宗商品→货币对→指数→ETF→加密货币→股票。股票的速率限制最严格,因此放在最后尝试。

Slugs utiles (Argentina / LatAm)

实用Slug(阿根廷/拉美地区)

SlugNombreSimboloTipo
ypf-sa
YPF Sociedad AnonimaYPFequities
ypf-sociedad
YPF Sociedad (variante)YPFequities
pampa-energia
Pampa Energia SAPAMPmequities
pampa-energia-sa
Pampa Energia ADRPAMequities
central-puerto
Central Puerto S.A.CEPUmequities
central-puerto-adr
Central Puerto ADRCEPUequities
tenaris
Tenaris SATENRequities
tenaris-sa
Tenaris ADRTSequities
bbva
Banco Bilbao Vizcaya ArgentariaBBVAequities
banco-macro-sa
Banco Macro SABMAequities
mercadolibre
MercadoLibreMELIequities
mercadolibre-inc
MercadoLibre IncMELIequities
globant-sa
Globant SAGLOBequities
globant-cedear
Globant CEDEARGLOBmequities
despegar-com
DespegarDESPequities
despegar-ba
Despegar Buenos AiresDESPmequities
galicia-b
Grupo Financiero Galicia (BA)GGALmequities
grupo-financiero-galicia-sa-adr
Grupo Financiero Galicia ADRGGALequities
edenor
EdenorEDNmequities
transportadora-de-gas-del-sur-sa
TGS SATGSmequities
siderar
Ternium / SiderarTXRequities
aluar
AluarALUAequities
mirgor
MirgorMIRGequities
loma-negra
Loma NegraLOMAequities
cresud
CresudCRESYequities
transener
TransenerTRANequities
capex
CapexCAPXequities
solvay
SolvaySOLBequities
holcim
HolcimHCMLYequities
consultatio-s.
ConsultatioCONOequities
garovaglio
GarovaglioGCLAequities
laboratorios-richmond
Laboratorios RichmondRICHequities
longvie
LongvieLONGequities
rigolleau
RigolleauRIGOequities
Slug名称代码类型
ypf-sa
YPF股份公司YPFequities
ypf-sociedad
YPF股份公司(变体)YPFequities
pampa-energia
Pampa Energia SAPAMPmequities
pampa-energia-sa
Pampa Energia ADRPAMequities
central-puerto
Central Puerto S.A.CEPUmequities
central-puerto-adr
Central Puerto ADRCEPUequities
tenaris
Tenaris SATENRequities
tenaris-sa
Tenaris ADRTSequities
bbva
西班牙对外银行阿根廷分行BBVAequities
banco-macro-sa
Banco Macro SABMAequities
mercadolibre
MercadoLibreMELIequities
mercadolibre-inc
MercadoLibre IncMELIequities
globant-sa
Globant SAGLOBequities
globant-cedear
Globant CEDEARGLOBmequities
despegar-com
DespegarDESPequities
despegar-ba
Despegar布宜诺斯艾利斯DESPmequities
galicia-b
加利西亚金融集团(布宜诺斯艾利斯)GGALmequities
grupo-financiero-galicia-sa-adr
加利西亚金融集团ADRGGALequities
edenor
EdenorEDNmequities
transportadora-de-gas-del-sur-sa
TGS SATGSmequities
siderar
Ternium / SiderarTXRequities
aluar
AluarALUAequities
mirgor
MirgorMIRGequities
loma-negra
Loma NegraLOMAequities
cresud
CresudCRESYequities
transener
TransenerTRANequities
capex
CapexCAPXequities
solvay
SolvaySOLBequities
holcim
HolcimHCMLYequities
consultatio-s.
ConsultatioCONOequities
garovaglio
GarovaglioGCLAequities
laboratorios-richmond
Laboratorios RichmondRICHequities
longvie
LongvieLONGequities
rigolleau
RigolleauRIGOequities

Currencies (FX)

货币对(外汇)

SlugParNotas
usd-ars
USD/ARS (oficial)Dolar oficial
eur-usd
EUR/USDMayor
brl-usd
BRL/USD (oficial)Dolar oficial Brasil
mxn-usd
MXN/USD (oficial)Peso mexicano
ars-brl
ARS/BRLPeso argentino vs real
ars-mxn
ARS/MXNPeso argentino vs peso mexicano
aed-ars
AED/ARSDirham → Peso
MEP / CCL / Blue: Investing.com no expone estos pares derivados como tales. Para MEP/CCL/blue, usar data912 que sí los cubre.

Slug货币对说明
usd-ars
USD/ARS(官方)官方美元
eur-usd
EUR/USD主要货币对
brl-usd
BRL/USD(官方)巴西官方美元
mxn-usd
MXN/USD(官方)墨西哥比索
ars-brl
ARS/BRL阿根廷比索兑巴西雷亚尔
ars-mxn
ARS/MXN阿根廷比索兑墨西哥比索
aed-ars
AED/ARS迪拉姆兑阿根廷比索
MEP / CCL / 蓝美元: Investing.com未直接提供这些衍生货币对的数据。如需获取MEP/CCL/蓝美元数据,请使用data912工具。

Datos devueltos

返回数据格式

quote

quote

json
{
  "last": "4,501.47",         // precio formateado (con separadores)
  "last_raw": 4501.47,         // precio como float
  "change": -0.78,             // cambio absoluto vs last_close
  "change_pct": -0.02,         // (no siempre presente)
  "last_close": 4502.25,       // (no siempre presente)
  "bid": 4500.74,              // bid (commodities, currencies)
  "ask": 4501.19,              // ask
  "open": 4502.5,              // apertura del dia
  "high": 4508.75,             // maximo del dia
  "low": 4499.97,              // minimo del dia
  "volume": 1633,              // volumen
  "avg_volume": 0,             // volumen promedio
  "prev_close": null,          // cierre anterior
  "pair_id": 1057391,          // ID interno de investing.com
  "name": "Gold Futures",      // nombre completo
  "symbol": "GC",              // ticker
  "currency": "USD",           // moneda
  "exchange": null,            // exchange
  "country": null,             // pais
  "updated_epoch": 1749091200, // timestamp ultima actualizacion
  "page_title": "Gold Futures - Investing.com",
  "slug": "gold",
  "type": "commodities",
  "url": "https://www.investing.com/commodities/gold"
}
Nota: no todos los campos aparecen en todos los instrumentos. Equities suelen tener
last
,
last_raw
,
change
,
bid
,
ask
,
open
,
high
,
low
,
volume
,
prev_close
,
pair_id
,
name
,
symbol
,
currency
,
exchange
. Commodities suelen incluir ademas
updated_epoch
.
json
{
  "last": "4,501.47",         // 格式化价格(带分隔符)
  "last_raw": 4501.47,         // 浮点型价格
  "change": -0.78,             // 较上次收盘价的绝对涨跌幅
  "change_pct": -0.02,         // (并非始终存在)
  "last_close": 4502.25,       // (并非始终存在)
  "bid": 4500.74,              // 买价(大宗商品、货币对)
  "ask": 4501.19,              // 卖价
  "open": 4502.5,              // 当日开盘价
  "high": 4508.75,             // 当日最高价
  "low": 4499.97,              // 当日最低价
  "volume": 1633,              // 成交量
  "avg_volume": 0,             // 平均成交量
  "prev_close": null,          // 前收盘价
  "pair_id": 1057391,          // Investing.com内部ID
  "name": "Gold Futures",      // 完整名称
  "symbol": "GC",              // 交易代码
  "currency": "USD",           // 计价货币
  "exchange": null,            // 交易所
  "country": null,             // 国家
  "updated_epoch": 1749091200, // 最后更新时间戳
  "page_title": "Gold Futures - Investing.com",
  "slug": "gold",
  "type": "commodities",
  "url": "https://www.investing.com/commodities/gold"
}
注意: 并非所有工具都会返回全部字段。股票通常包含
last
,
last_raw
,
change
,
bid
,
ask
,
open
,
high
,
low
,
volume
,
prev_close
,
pair_id
,
name
,
symbol
,
currency
,
exchange
。大宗商品还会额外包含
updated_epoch

historical

historical

json
{
  "slug": "gold",
  "type": "commodities",
  "count": 23,
  "rows": [
    {
      "date": "Jun 04, 2026",
      "price": "4,497.70",
      "open": "4,481.76",
      "high": "4,543.12",
      "low": "4,470.55",
      "vol": "3.16K",
      "change_pct": "+0.69%"
    },
    ...
  ]
}
23 dias por default (1 pagina). Usar
--pages 5
para ~115 dias, etc.
json
{
  "slug": "gold",
  "type": "commodities",
  "count": 23,
  "rows": [
    {
      "date": "Jun 04, 2026",
      "price": "4,497.70",
      "open": "4,481.76",
      "high": "4,543.12",
      "low": "4,470.55",
      "vol": "3.16K",
      "change_pct": "+0.69%"
    },
    ...
  ]
}
默认返回23天数据(1页)。使用
--pages 5
可获取约115天数据,以此类推。

financials

financials

Devuelve estructura con periodos (TTM, 2024, 2023, 2022, 2021, 2020) y filas con label + valores:
json
{
  "slug": "apple-computer-inc",
  "type": "equities",
  "ftype": "income",
  "periods": ["TTM", "2024", "2023", "2022", "2021", "2020"],
  "count": 23,
  "rows": [
    {"label": "Total Revenue", "values": ["394,328", "385,100", "383,285", "394,328", "365,817", "274,515"]},
    {"label": "Gross Profit", "values": ["170,000", ...]},
    ...
  ]
}
--ftype income
|
balance
|
cashflow
返回包含周期(TTM、2024、2023、2022、2021、2020)和标签+数值行的结构:
json
{
  "slug": "apple-computer-inc",
  "type": "equities",
  "ftype": "income",
  "periods": ["TTM", "2024", "2023", "2022", "2021", "2020"],
  "count": 23,
  "rows": [
    {"label": "Total Revenue", "values": ["394,328", "385,100", "383,285", "394,328", "365,817", "274,515"]},
    {"label": "Gross Profit", "values": ["170,000", ...]},
    ...
  ]
}
--ftype
可选值:
income
|
balance
|
cashflow

ratios

ratios

Misma estructura que
financials
pero con ratios (margenes, retornos, valuation, etc).
financials
结构相同,但内容为财务比率(利润率、回报率、估值等)。

dividends

dividends

Array de filas con celdas (fecha, dividend, yield, etc):
json
{
  "slug": "apple-computer-inc",
  "type": "equities",
  "count": 18,
  "rows": [
    ["Ex-Dividend Date", "May 09, 2025", "Quarterly", "0.26", "..."],
    ...
  ]
}
包含日期、股息、收益率等字段的数组:
json
{
  "slug": "apple-computer-inc",
  "type": "equities",
  "count": 18,
  "rows": [
    ["Ex-Dividend Date", "May 09, 2025", "Quarterly", "0.26", "..."],
    ...
  ]
}

earnings

earnings

Array de filas (date, EPS actual, EPS estimado, surprise, etc):
json
{
  "slug": "apple-computer-inc",
  "type": "equities",
  "count": 20,
  "rows": [
    ["Aug 01, 2024", "Q3 2024", "1.40", "1.35", "+3.70%", "..."],
    ...
  ]
}

包含日期、实际EPS、预期EPS、超出预期幅度等字段的数组:
json
{
  "slug": "apple-computer-inc",
  "type": "equities",
  "count": 20,
  "rows": [
    ["Aug 01, 2024", "Q3 2024", "1.40", "1.35", "+3.70%", "..."],
    ...
  ]
}

Consideraciones tecnicas

技术说明

¿Por que
curl_cffi
y no
requests
?

为什么使用
curl_cffi
而不是
requests

Investing.com usa Cloudflare con proteccion anti-bot a nivel TLS. El User-Agent no importa — Cloudflare hace TLS fingerprinting y rechaza clientes que no sean navegadores reales.
  • requests
    (Python puro, TLS fingerprint de Python urllib3): bloqueado, devuelve challenge HTML.
  • curl_cffi.requests.Session(impersonate="chrome120")
    : pasa el challenge porque impersona el fingerprint TLS de Chrome 120.
curl_cffi
es un wrapper sobre
curl-impersonate
(fork de libcurl con fingerprints pre-cargados). Es una libreria con wheels precompilados para Windows/Mac/Linux — instalar y usar sin compilar nada.
Investing.com使用Cloudflare的TLS层反机器人保护。User-Agent无关紧要——Cloudflare会进行TLS指纹识别,拒绝非真实浏览器的客户端。
  • requests
    (纯Python实现,TLS指纹来自Python urllib3):被拦截,返回验证页面。
  • curl_cffi.requests.Session(impersonate="chrome120")
    可通过验证,因为它模拟了Chrome 120的TLS指纹。
curl_cffi
curl-impersonate
(libcurl的分支,预加载了指纹)的Python封装库。它提供Windows/Mac/Linux的预编译包,无需编译即可安装使用。

Rate limit y Cloudflare

速率限制与Cloudflare

Cloudflare impone rate limits agresivos:
  • /equities/ es el path mas rate-limited (mas requests, mas proteccion)
  • /commodities/, /currencies/, /indices/ son mas permisivos
  • Si haces 10+ requests en pocos segundos → 429 o 403 con "Just a moment..."
  • Backoff recomendado: 2-3 segundos entre requests
  • Si recibis 429, esperar 1-2 minutos
El script maneja esto con retries + backoff exponencial. Si el IP esta muy marcado, la unica solucion es esperar o usar un proxy residencial.
Cloudflare实施严格的速率限制:
  • **/equities/**路径的速率限制最严格(请求量最大,保护级别最高)
  • /commodities//currencies/、**/indices/**路径限制相对宽松
  • 短时间内发送10+请求会触发429或403错误,提示"Just a moment..."
  • 建议退避间隔:请求间隔2-3秒
  • 如果收到429错误,请等待1-2分钟
脚本通过重试+指数退避机制处理此问题。如果IP被标记,唯一解决方法是等待或使用住宅代理。

Auto-deteccion de tipo

类型自动检测

Cuando no se pasa
--type
, el script prueba los 6 paths uno por uno. Esto dispara 6 requests, lo que puede rate-limitar. Recomendacion: pasar
--type
siempre que se sepa.
Orden de prueba (mas rapido primero):
  1. commodities
    (344 instrumentos)
  2. currencies
    (2,394)
  3. indices
    (20K+)
  4. etfs
    (30K+)
  5. crypto
    (4K+)
  6. equities
    (81K+, rate-limited)
当不传入
--type
参数时,脚本会依次尝试6种路径。这会触发6次请求,可能触发速率限制。建议: 已知工具类型时务必传入
--type
参数。
尝试顺序(从最快到最慢):
  1. commodities
    (344种工具)
  2. currencies
    (2394种)
  3. indices
    (20000+种)
  4. etfs
    (30000+种)
  5. crypto
    (4000+种)
  6. equities
    (81000+种,速率限制严格)

Sitemaps

站点地图

Los sitemaps son la unica fuente totalmente publica y no rate-limited. Son utiles para:
  • Descubrir slugs de instrumentos (no hay API de "search" publica)
  • Construir catalogos locales
  • Backups de listings
Cantidad de instrumentos por sitemap (verificado 2026-06-04):
  • equities: 81,518 (9 archivos)
  • commodities: 344 (1 archivo)
  • indices: 20,000+ (2 archivos)
  • currencies: 2,394 (2 archivos)
  • etfs: 30,000+ (3 archivos)
  • crypto coins: 4,135
  • crypto pairs: 20,000+ (2 archivos)
  • rates/bonds: 20,000+ (2 archivos)
  • funds: 100K+ (11 archivos)
  • certificates: 6,222

站点地图是唯一完全公开且无速率限制的数据来源,可用于:
  • 发现工具的slug(无公开搜索API)
  • 构建本地目录
  • 备份工具列表
各站点地图的工具数量(2026-06-04验证):
  • equities: 81518(9个文件)
  • commodities: 344(1个文件)
  • indices: 20000+(2个文件)
  • currencies: 2394(2个文件)
  • etfs: 30000+(3个文件)
  • crypto coins: 4135
  • crypto pairs: 20000+(2个文件)
  • rates/bonds: 20000+(2个文件)
  • funds: 100000+(11个文件)
  • certificates: 6222

Limitaciones

局限性

  1. Rate limit agresivo: en uso intensivo, CF puede bloquear el IP. Es problema del sitio, no del script.
  2. Cloudflare puede romper el skill en cualquier momento cambiando el challenge.
  3. Historico paginado: 23 dias por default, hay que pasar
    --pages
    para mas.

  1. 严格速率限制: 频繁使用时,Cloudflare可能封禁IP。这是网站自身限制,与脚本无关。
  2. Cloudflare可能随时修改验证机制,导致工具失效。
  3. 历史数据分页: 默认返回23天数据,需传入
    --pages
    参数获取更多数据。

Estructura del skill

工具结构

skills/investing/
├── SKILL.md                          # Este archivo (guia rapida)
├── references/
│   └── REFERENCE.md                  # Documentacion completa + endpoints
└── scripts/
    └── fetch_investing.py            # Script principal

Documentacion detallada: Consultar references/REFERENCE.md para la documentacion exhaustiva de los endpoints, estructuras JSON, ejemplos y troubleshooting.
skills/investing/
├── SKILL.md                          # 本文件(快速指南)
├── references/
│   └── REFERENCE.md                  # 完整文档 + 端点说明
└── scripts/
    └── fetch_investing.py            # 主脚本

详细文档: 请查看references/REFERENCE.md获取端点、JSON结构、示例及故障排除的完整说明。