ve-exchange-rates: Venezuelan Exchange Rates
Get current exchange rates for Venezuela:
- 1. Tasa BCV - Official Central Bank rate from the BCV website
- Tasa USDT Binance P2P - Average from P2P market
- Brecha cambiaria - Gap between official and parallel rates
Usage
Run the wrapper script to get current rates:
CODEBLOCK0
The shell script is now a thin wrapper around a Python implementation:
CODEBLOCK1
Output
The script returns:
- - BCV official rate (Bs/USD)
- BCV source used
- BCV "Fecha Valor" extracted from the site
- Warning if the BCV date does not match the expected current run window
- Binance P2P USDT rates (buy/sell/average)
- Gap percentage between BCV and P2P
- Example conversion from 100 USD at BCV rate into USDT at P2P rate
Data Sources
- - BCV rate: scraped directly from bcv.org.ve
- BCV validation: extracts and validates Fecha Valor from the BCV page
- Fallback for BCV: exchangerate-api.com only if BCV cannot be parsed
- USDT P2P: Binance P2P API (
p2p.binance.com)
Notes
- - BCV is the primary source and should be treated as the authoritative rate
- The skill warns when the BCV "Fecha Valor" does not match today or tomorrow
- P2P rates fluctuate constantly based on market conditions
- Main implementation now lives in Python for readability and easier auditing
- The shell entrypoint is only a thin wrapper that invokes INLINECODE1
- The implementation uses standard library HTTP requests and
bc for decimal math formatting compatibility - If BCV is temporarily unavailable, the skill falls back to a secondary source to preserve functionality
ve-exchange-rates: 委内瑞拉汇率
获取委内瑞拉当前汇率:
- 1. BCV汇率 - 来自BCV网站的官方中央银行汇率
- 币安P2P USDT汇率 - P2P市场平均汇率
- 汇率差 - 官方汇率与平行市场汇率之间的差距
使用方法
运行包装脚本获取当前汇率:
bash
./skills/ve-exchange-rates/scripts/get-rates.sh
该Shell脚本现为Python实现的轻量包装:
bash
python3 ./skills/ve-exchange-rates/scripts/get_rates.py
输出结果
脚本返回:
- - BCV官方汇率(玻利瓦尔/美元)
- 所使用的BCV数据源
- 从网站提取的BCV估值日期
- 若BCV日期与预期当前运行窗口不匹配时的警告
- 币安P2P USDT汇率(买入/卖出/平均)
- BCV与P2P之间的汇率差百分比
- 以BCV汇率兑换100美元为USDT的示例(按P2P汇率)
数据来源
- - BCV汇率:直接从bcv.org.ve抓取
- BCV验证:从BCV页面提取并验证估值日期
- BCV备用方案:仅当无法解析BCV时使用exchangerate-api.com
- USDT P2P:币安P2P API(p2p.binance.com)
注意事项
- - BCV为主要数据源,应视为权威汇率
- 当BCV估值日期与当天或次日不匹配时,技能会发出警告
- P2P汇率根据市场状况持续波动
- 主要实现现采用Python编写,以提高可读性和审计便利性
- Shell入口仅为调用get_rates.py的轻量包装
- 实现使用标准库HTTP请求和bc进行十进制数学格式化兼容
- 若BCV暂时不可用,技能将回退至备用数据源以保持功能正常