数据分析

Crypto Market Data

试用

Fetch reusable cryptocurrency realtime spot prices and historical price/K-line data for a symbol or coin id. Use when a user asks to get crypto realtime data...

它能做什么

Fetch reusable cryptocurrency realtime spot prices and historical price/K-line data for a symbol or coin id. Use when a user asks to get crypto realtime data, historical candles, full price history, Binance spot data, CoinGecko market-chart data, or wants to reuse market data in another project.

技能文档

Crypto Market Data

Use this skill to retrieve clean JSON market data that can be copied into any project.

Quick Start

When this skill is installed from ClawHub or copied into an OpenClaw skills folder, run the bundled Node script from the skill directory:

node scripts/fetch-market-data.mjs BTC --realtime --history --interval 1d --range max

If the skill is installed in Codex locally, the same command can be run with the local path:

node ~/.codex/skills/crypto-market-data/scripts/fetch-market-data.mjs BTC --realtime --history --interval 1d --range max

Import it from another Node or OpenClaw project:

import { fetchCryptoMarketData } from "~/.codex/skills/crypto-market-data/scripts/fetch-market-data.mjs";

const data = await fetchCryptoMarketData({
  symbol: "BTC",
  realtime: true,
  history: true,
  interval: "1d",
  range: "max",
});

Source Selection

  • Use --history-source binance for exchange K-lines. This is best for trading charts, but history starts when the pair listed on Binance.
  • Use --history-source coingecko --coin-id bitcoin --range max for coin/project price history. This is better when the user asks for “全部历史价格”.
  • Use Binance realtime for spot ticker data when the asset has a liquid USDT, USDC, or FDUSD spot pair.
  • Do not invent market cap, supply, or history. If a source is missing, return an error or mark the field missing.

Common Commands

Realtime only:

node ~/.codex/skills/crypto-market-data/scripts/fetch-market-data.mjs SOL --realtime

Binance full K-line history:

node ~/.codex/skills/crypto-market-data/scripts/fetch-market-data.mjs ETH --history --interval 1d --range max --history-source binance

CoinGecko full price history:

node ~/.codex/skills/crypto-market-data/scripts/fetch-market-data.mjs BTC --history --history-source coingecko --coin-id bitcoin --range max

Write JSON to a file:

node ~/.codex/skills/crypto-market-data/scripts/fetch-market-data.mjs TRUMP --realtime --history --range 30d --out trump-market.json

OpenClaw Usage

When an OpenClaw agent needs market data, use this skill and execute the script with the requested symbol, source, interval, and range. Prefer JSON output and keep source errors non-fatal.

Example prompts after installation:

  • “Use crypto-market-data to fetch BTC realtime spot data and full historical prices.”
  • “Use crypto-market-data to fetch SOL 1d Binance K-lines for the last year.”
  • “Use crypto-market-data to fetch CoinGecko full history for bitcoin.”

Output Shape

The script returns:

  • query: requested symbol, pair, interval, range and source choice.
  • realtime: latest spot ticker from Binance when requested.
  • history: candle/price series with source metadata.
  • errors: non-fatal source errors.

Read references/data-sources.md when deciding between Binance, CoinGecko, and CMC semantics.

相关技能

Fetch live and historical cryptocurrency market data (prices, klines/candlesticks, order books, trades, 24h stats, futures funding rates, open interest) with...

1 次安装2 星标

通过 CoinGecko 与 GeckoTerminal API 实时获取加密货币行情数据,并处理鉴权与错误。

21 次安装2 星标

Live Bitcoin & crypto price data via CoinGecko API. Fetch BTC/USD, ETH/USD, multi-asset quotes. Supports both Demo (free) and Pro API keys. No credentials in prompts—only .env isolation.

Crypto & DeFi market data for AI agents — spot prices, market data, DEX liquidity, DeFi protocol TVL, gas prices, Fear & Greed sentiment, trending coins, and...

1 次安装

Fetches next-hour predicted price for BTC/ETH from external prediction API. Supports BTCUSDT and ETHUSDT symbols only.

Analyze one BTC or ETH derivatives setup using current public Deribit, Hyperliquid, and Polymarket data. Use for read-only strategy research, volatility, opt...

2 次安装