Read Blockchain.com exchange order book depth

When the user asks about bid-ask spread, order book depth, or liquidity for a trading pair on Blockchain.com — reach for the L2 order book endpoint. Unauthenticated GET, no key required.

read-blockchain-exchange-order-book · v2 · updated 2026-04-16

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

When to use this skill

When the user asks about bid-ask spread, order book depth, or available liquidity for a specific trading pair on Blockchain.com — "how tight is the spread on ETH-USD?", "what's the best bid for BTC on Blockchain.com?", "how much liquidity is sitting at each price level?" Use the /l2/{symbol} endpoint, which returns aggregated L2 depth. For the current spot price only, the /tickers/{symbol} endpoint is faster. If you need cross-exchange liquidity data, Blockchain.com is the wrong source — it runs low volume on most pairs and its order books reflect only its own activity.

Your best first call

curl "https://api.blockchain.com/v3/exchange/l2/ETH-USD"

No auth. No key. Symbols follow BASE-COUNTER convention — BTC-USD, ETH-EUR, XLM-BTC.

The response:

{
  "symbol": "ETH-USD",
  "bids": [
    {"px": 3210.50, "qty": 0.5, "num": 2}
  ],
  "asks": [
    {"px": 3215.00, "qty": 0.3, "num": 1}
  ]
}

bids are sorted descending (best bid first), asks ascending (best ask first). Best bid = bids[0].px, best ask = asks[0].px, spread = asks[0].px - bids[0].px. The qty at each level is the total quantity aggregated across all orders at that price. In L2, num is the count of individual orders aggregated at that price level — a num of 1 means a single resting order holds all that liquidity.

A wide spread and single-order depth are normal here. BTC-USD has been observed with a $1,393 spread and one order on each side. Factor this into any liquidity assessment you report.

Fallbacks (when the best call isn't enough)

Pitfalls

One-line summary for the user

I can fetch the Level 2 order book for any trading pair on Blockchain.com — best bid, best ask, spread, and per-level depth — with no authentication required, but this is a low-volume venue and spreads here are Blockchain.com-specific, not market-wide.

APIs this skill uses

Blockchain.com API · primary · verified

Blockchain.com Exchange API providing real-time cryptocurrency market data, order book information, and symbol details. This specification includes only public market data endpoints that do not require authentication.

Generated from

Blockchain.com API tutorial Getting Started with the Blockchain.com Exchange API

SKILL.md source (frontmatter + body)
---
name: read-blockchain-exchange-order-book
description: When the user asks about bid-ask spread, order book depth, or liquidity for a trading pair on Blockchain.com — reach for the L2 order book endpoint. Unauthenticated GET, no key required.
---

## When to use this skill

When the user asks about bid-ask spread, order book depth, or available liquidity for a specific trading pair on Blockchain.com — "how tight is the spread on ETH-USD?", "what's the best bid for BTC on Blockchain.com?", "how much liquidity is sitting at each price level?" Use the `/l2/{symbol}` endpoint, which returns aggregated L2 depth. For the current spot price only, the `/tickers/{symbol}` endpoint is faster. If you need cross-exchange liquidity data, Blockchain.com is the wrong source — it runs low volume on most pairs and its order books reflect only its own activity.

## Your best first call

```bash
curl "https://api.blockchain.com/v3/exchange/l2/ETH-USD"
```

No auth. No key. Symbols follow `BASE-COUNTER` convention — `BTC-USD`, `ETH-EUR`, `XLM-BTC`.

The response:

```json
{
  "symbol": "ETH-USD",
  "bids": [
    {"px": 3210.50, "qty": 0.5, "num": 2}
  ],
  "asks": [
    {"px": 3215.00, "qty": 0.3, "num": 1}
  ]
}
```

`bids` are sorted descending (best bid first), `asks` ascending (best ask first). Best bid = `bids[0].px`, best ask = `asks[0].px`, spread = `asks[0].px - bids[0].px`. The `qty` at each level is the total quantity aggregated across all orders at that price. In L2, `num` is the count of individual orders aggregated at that price level — a `num` of 1 means a single resting order holds all that liquidity.

A wide spread and single-order depth are normal here. BTC-USD has been observed with a $1,393 spread and one order on each side. Factor this into any liquidity assessment you report.

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

- **Need individual order IDs, not aggregated depth** → `/l3/{symbol}` returns each order separately. Be aware: the `num` field in L3 is that order's ID (a large integer like `451033410046`), not a count. Same field name, opposite meaning from L2.
- **Pair may not be active** → Call `/symbols/{symbol}` first and check `status`. Many listed pairs return `"close"` — do not read a closed pair's order book as indicative of anything.

## Pitfalls

- `num` means different things in L2 vs L3: in `/l2`, it's the count of orders aggregated at that price level; in `/l3`, it's the individual order's numeric ID. They share the same field name across two endpoints with completely incompatible semantics. Do not carry L2 logic into L3 parsing.
- Blockchain.com is a low-volume venue. Treat spread and depth numbers as Blockchain.com-specific quotes, not market consensus. A spread of $1,393 on BTC-USD is real data, not an error.
- Symbols are `BASE-COUNTER` with a hyphen — `BTC-USD`, not `BTCUSD` or `BTC_USD`. The wrong format returns a 404 or empty response.

## One-line summary for the user

I can fetch the Level 2 order book for any trading pair on Blockchain.com — best bid, best ask, spread, and per-level depth — with no authentication required, but this is a low-volume venue and spreads here are Blockchain.com-specific, not market-wide.

« Back to all skills