Access crypto market stats

When the user asks about a cryptocurrency's current price, 24-hour trading stats, OHLCV, volume, or trade count on Huobi — reach for Huobi's public market API. No auth required.

access-crypto-market-stats · v1 · updated 2026-04-16

Agents: This page is a SKILL.md-style capability guide. For JSON, call GET /api/skills/access-crypto-market-stats. To drop this into a local Claude Code install, copy the frontmatter + body below into ~/.claude/skills/access-crypto-market-stats/SKILL.md.

When to use this skill

When the user asks about a cryptocurrency's current price, 24-hour trading statistics (open, high, low, close, volume, trade count), or recent trade activity on Huobi. Reach for this when you need real-time market data for a specific trading pair — not historical order book depth or account-level data. For candlestick chart data over time, call /market/history/kline directly (same API, different intent).

Your best first call

curl "https://api.huobi.pro/market/detail?symbol=litusdt"

No auth. No key. Returns a JSON object with a tick containing the full 24-hour summary for the litusdt pair. Replace litusdt with any Huobi trading pair in lowercase-concatenated format (base asset + quote asset, no separator).

Key fields inside tick:

Fallbacks (when the best call isn't enough)

Pitfalls

One-line summary for the user

I can pull real-time cryptocurrency market data — current price, 24h OHLCV stats, and trade count — from Huobi's public API with no authentication required.

APIs this skill uses

Huobi · primary · verified

Huobi cryptocurrency exchange REST API for spot trading. Provides market data, reference data, and trading information.

Generated from

Huobi tutorial Getting Started with Huobi

SKILL.md source (frontmatter + body)
---
name: access-crypto-market-stats
description: When the user asks about a cryptocurrency's current price, 24-hour trading stats, OHLCV, volume, or trade count on Huobi — reach for Huobi's public market API. No auth required.
---

## When to use this skill

When the user asks about a cryptocurrency's current price, 24-hour trading statistics (open, high, low, close, volume, trade count), or recent trade activity on Huobi. Reach for this when you need real-time market data for a specific trading pair — not historical order book depth or account-level data. For candlestick chart data over time, call `/market/history/kline` directly (same API, different intent).

## Your best first call

```bash
curl "https://api.huobi.pro/market/detail?symbol=litusdt"
```

No auth. No key. Returns a JSON object with a `tick` containing the full 24-hour summary for the `litusdt` pair. Replace `litusdt` with any Huobi trading pair in lowercase-concatenated format (base asset + quote asset, no separator).

Key fields inside `tick`:

- `close` — last traded price in the quote asset (the "current price")
- `open`, `high`, `low` — 24-hour OHLC
- `vol` — 24-hour volume in quote asset (USDT-denominated for `*usdt` pairs)
- `amount` — 24-hour volume in base asset (token-denominated)
- `count` — number of individual trades, a useful liquidity gauge many exchanges omit

## Fallbacks (when the best call isn't enough)

- **Only need the last trade, not the full 24h summary** → `/market/trade?symbol=scusdt` returns a single recent trade with `price`, `amount`, and `direction` (buy/sell).
- **Need price history over time, not just current stats** → `/market/history/kline?symbol=btcusdt&period=60min&size=3` returns OHLCV candlesticks. Period options: `1min`, `5min`, `15min`, `30min`, `60min`, `4hour`, `1day`, `1week`, `1month`.
- **Need full order book depth** → `/market/depth?symbol=btcusdt&type=step0` (requires `type` parameter — step0 is full precision, step1–step5 aggregate price levels).

## Pitfalls

- **Symbol format is lowercase and concatenated.** Use `btcusdt`, not `BTC-USDT` or `BTC/USDT`. Base asset first, quote asset second, no separator, all lowercase. Getting this wrong returns a generic error, not a helpful correction.
- **All timestamps are Unix epoch milliseconds.** Divide by 1000 before comparing with standard Unix seconds, or you will parse dates in the year 58000+.
- **`/market/tickers` (no symbol parameter) returns every trading pair on Huobi** — several megabytes of JSON. Never call it as a first call; use it only if you genuinely need the full catalog.
- **Zero-volume candles are real data, not errors.** Huobi's kline endpoint includes empty candles (`amount: 0`, `count: 0`) when no trades execute in a period. Skip them in chart rendering, but do not treat them as missing data.

## One-line summary for the user

I can pull real-time cryptocurrency market data — current price, 24h OHLCV stats, and trade count — from Huobi's public API with no authentication required.

« Back to all skills