Volume Monitor
Live crypto data · 8 exchanges

Developer API

The JSON endpoints behind this site's own charts are public and free to call directly: no API key, no signup. This page documents every one of them — parameters, a curl example and a sample response — plus the full list of metrics /api/series accepts.

5 endpoints9 series metricsFree, no API keyAs of 17:05 UTC

Terms

Quick start

curl 'https://swolecharts.com/api/series/oi?base=BTC&range=7d'

Every response is JSON. Bad input is a 400 with {"error": "..."}; a missing or unreachable database is still a 200 with empty arrays, never a 500.

Endpoints

GET /api/series/<metric>

History for one metric: compact time/value arrays, auto-picking the coarsest table that covers the requested range.

ParamInRequiredDefaultDescription
metricpathrequired—One of the metric names or aliases in the table below, e.g. oi, funding, price, volume, liquidations, long-short, taker-flow, cvd, basis.
basequeryone of base/market—Coin, e.g. BTC. Give exactly one of base or market.
marketqueryone of base/market—venue:perp|spot:SYMBOL, e.g. binance:perp:BTCUSDT.
rangequeryoptional1dHow far back, e.g. 6h, 30d, 12w, 1y (max 730d). Ignored if start is given.
startqueryoptional—Epoch ms. Needs end unless range is also given.
endqueryoptionalnowEpoch ms.
stepqueryoptionalautoOne of 1m, 5m, 15m, 1h, 4h, 1d; raised automatically so the response stays under 1500 points.
venuequeryoptional—binance, bybit or hyperliquid.
typequeryoptionalperpperp, spot or all (market_id metrics only).
kindqueryoptionalaccountsaccounts or top_pos (long-short only).
curl 'https://swolecharts.com/api/series/oi?base=BTC&range=7d&step=1h'

Open a live example response →

Example response (trimmed)
{
  "metric": "oi",
  "step": 3600000,
  "start": 1758931200000,
  "end": 1759536000000,
  "source": "market_1h",
  "fields": [
    "v"
  ],
  "t": [
    1758931200000,
    1758934800000,
    1758938400000
  ],
  "v": [
    16123456789.0,
    16205000000.0,
    16090000000.0
  ],
  "gaps": [],
  "db": true,
  "base": "BTC",
  "market": null,
  "venue": null,
  "type": "perp"
}

Always 200: bad input is a 400 with {"error": ...}; a missing or unreachable database still returns 200 with empty arrays and "db": false or "error": "unavailable". "gaps" marks the parts of the range the engine was not recording, so a chart can shade them instead of implying zero activity.

GET /api/markets

Every tracked coin right now: price, 24h volume, open interest and funding across Binance, Bybit and Hyperliquid, one row per coin with every venue's markets nested inside.

No query parameters.

curl 'https://swolecharts.com/api/markets'

Open a live example response →

Example response (trimmed)
{
  "server_ts": 1759007345123,
  "uptime_since": 1758996345123,
  "coins": [
    {
      "base": "BTC",
      "oi_1h": 0.012,
      "oi_4h": -0.004,
      "oi_24h": 0.031,
      "perp_vol24h": 29000000000.0,
      "spot_vol24h": 2100000000.0,
      "oi_usd": 16200000000.0,
      "funding_avg": 0.0001,
      "funding_spread": 3e-05,
      "venues": [
        "binance",
        "bybit",
        "hyperliquid"
      ],
      "perps": [
        {
          "venue": "binance",
          "symbol": "BTCUSDT",
          "quote": "USDT",
          "price": 84950.0,
          "vol24h": 20000000000.0,
          "funding": 0.0001,
          "oi_usd": 8000000000.0,
          "px_1h": 0.004,
          "px_4h": -0.001,
          "px_24h": 0.021,
          "oi_1h": 0.01,
          "oi_4h": -0.003,
          "oi_24h": 0.028,
          "url": "https://www.binance.com/en/futures/BTCUSDT",
          "hip3": false
        }
      ],
      "spots": [
        {
          "venue": "binance",
          "symbol": "BTCUSDT",
          "quote": "USDT",
          "price": 84955.0,
          "vol24h": 2100000000.0,
          "funding": null,
          "oi_usd": null,
          "px_1h": 0.004,
          "px_4h": -0.001,
          "px_24h": 0.021,
          "oi_1h": null,
          "oi_4h": null,
          "oi_24h": null,
          "url": "https://www.binance.com/en/trade/BTC_USDT",
          "hip3": false
        }
      ],
      "hip3": false
    }
  ]
}

No query parameters; always the full snapshot. Response is truncated above to one coin — the real endpoint lists every tracked coin.

GET /api/coin/<base>

Everything this site knows about one coin right now: its market row, recent spike alerts, long/short ratio history and liquidation summary.

ParamInRequiredDefaultDescription
basepathrequired—Coin, e.g. BTC.
curl 'https://swolecharts.com/api/coin/BTC'

Open a live example response →

Example response (trimmed)
{
  "long_short": {
    "binance_accounts": {
      "symbol": "BTCUSDT",
      "long": 0.62,
      "ts": 1759007300000,
      "chg_1h": 0.01,
      "chg_4h": -0.02,
      "chg_24h": 0.04
    }
  },
  "server_ts": 1759007345123,
  "uptime_since": 1758996345123,
  "market": {
    "base": "BTC",
    "oi_usd": 16200000000.0,
    "funding_avg": 0.0001,
    "perp_vol24h": 29000000000.0,
    "spot_vol24h": 2100000000.0,
    "venues": [
      "binance",
      "bybit",
      "hyperliquid"
    ],
    "hip3": false
  },
  "alerts": [
    {
      "id": 4821,
      "ts": 1759007100000,
      "venue": "binance",
      "symbol": "BTCUSDT",
      "kind": "volume",
      "dir": "buy",
      "sig": 6.2
    }
  ],
  "hits24h": 3,
  "net_flow24h": 1250000.0,
  "liquidations": {
    "since": 1758920945123,
    "totals": {
      "1h": {
        "long": 120000.0,
        "short": 40000.0,
        "count": 9
      },
      "24h": {
        "long": 4100000.0,
        "short": 3300000.0,
        "count": 214
      }
    },
    "by_venue": {
      "binance": {
        "long": 2000000.0,
        "short": 1500000.0,
        "count": 120
      }
    },
    "coins": [
      {
        "base": "BTC",
        "24h": {
          "long": 4100000.0,
          "short": 3300000.0
        }
      }
    ],
    "biggest": [
      {
        "ts": 1759006800000,
        "venue": "bybit",
        "symbol": "BTCUSDT",
        "base": "BTC",
        "side": "long",
        "usd": 380000.0,
        "price": 84200.0
      }
    ],
    "recent": [
      {
        "ts": 1759007320000,
        "venue": "binance",
        "symbol": "BTCUSDT",
        "base": "BTC",
        "side": "short",
        "usd": 15000.0,
        "price": 84950.0
      }
    ]
  }
}

404 with {"error": "unknown coin"} for a base this site doesn't track.

GET /api/liquidations

Rolling liquidation totals (1h/4h/12h/24h), by venue and by coin, plus the biggest and most recent individual liquidations, in memory since this process started.

No query parameters.

curl 'https://swolecharts.com/api/liquidations'

Open a live example response →

Example response (trimmed)
{
  "since": 1758920945123,
  "server_ts": 1759007345123,
  "uptime_since": 1758996345123,
  "totals": {
    "1h": {
      "long": 820000.0,
      "short": 610000.0,
      "count": 44
    },
    "4h": {
      "long": 2400000.0,
      "short": 1900000.0,
      "count": 168
    },
    "12h": {
      "long": 5100000.0,
      "short": 4300000.0,
      "count": 410
    },
    "24h": {
      "long": 9800000.0,
      "short": 8200000.0,
      "count": 812
    }
  },
  "by_venue": {
    "binance": {
      "long": 5200000.0,
      "short": 4100000.0,
      "count": 430
    },
    "bybit": {
      "long": 2600000.0,
      "short": 2300000.0,
      "count": 240
    },
    "hyperliquid": {
      "long": 2000000.0,
      "short": 1800000.0,
      "count": 142
    }
  },
  "coins": [
    {
      "base": "BTC",
      "1h": {
        "long": 120000.0,
        "short": 40000.0
      },
      "4h": {
        "long": 300000.0,
        "short": 110000.0
      },
      "12h": {
        "long": 700000.0,
        "short": 260000.0
      },
      "24h": {
        "long": 4100000.0,
        "short": 3300000.0
      }
    }
  ],
  "biggest": [
    {
      "ts": 1759006800000,
      "venue": "bybit",
      "symbol": "BTCUSDT",
      "base": "BTC",
      "side": "long",
      "usd": 380000.0,
      "price": 84200.0
    }
  ],
  "recent": [
    {
      "ts": 1759007320000,
      "venue": "binance",
      "symbol": "BTCUSDT",
      "base": "BTC",
      "side": "short",
      "usd": 15000.0,
      "price": 84950.0
    }
  ],
  "timeline": [
    {
      "t": 1759006800000,
      "long": 210000.0,
      "short": 95000.0
    }
  ]
}

No query parameters; always every coin. For one coin's history over a chosen range use /api/series/liquidations?base=..., or the "liquidations" key of /api/coin/<base> for its rolling totals only.

GET /api/long-short

Latest long/short account and top-trader position ratios per coin, from Binance and Bybit, ranked by 24h perp volume.

No query parameters.

curl 'https://swolecharts.com/api/long-short'

Open a live example response →

Example response (trimmed)
{
  "server_ts": 1759007345123,
  "coins": [
    {
      "base": "BTC",
      "binance_accounts": {
        "symbol": "BTCUSDT",
        "long": 0.62,
        "ts": 1759007300000,
        "chg_1h": 0.01,
        "chg_4h": -0.02,
        "chg_24h": 0.04
      },
      "binance_top_pos": {
        "symbol": "BTCUSDT",
        "long": 0.55,
        "ts": 1759007300000,
        "chg_1h": -0.003,
        "chg_4h": 0.01,
        "chg_24h": -0.02
      },
      "bybit_accounts": {
        "symbol": "BTCUSDT",
        "long": 0.58,
        "ts": 1759007280000,
        "chg_1h": 0.02,
        "chg_4h": 0.0,
        "chg_24h": 0.03
      }
    }
  ]
}

No query parameters; always every coin, latest reading only (no history). For history of one coin use /api/series/long-short?base=...&kind=accounts, or /api/coin/<base> (its "long_short" key includes history).

/api/series metrics

Every name api_series.py accepts
MetricAliasesFieldsSelector
basis perp-basis, premium, spot-basis v, ann base (+ optionally venue) or market (perp only); always the perp vs. its spot pair
cvd cumulative-volume-delta net, v base (+ type=perp|spot|all and optionally venue), or market
funding funding-rate v base (+ type=perp|spot|all and optionally venue), or market
liquidations liqs long, short base (+ type=perp|spot|all and optionally venue), or market
long-short long-short-ratio v base (+ optionally venue) or market (perp only); kind=accounts|top_pos
oi open-interest v base (+ type=perp|spot|all and optionally venue), or market
price — v base (+ type=perp|spot|all and optionally venue), or market
taker-flow net-flow, taker-buy-sell, taker-net-flow buy, sell, net base (+ type=perp|spot|all and optionally venue), or market
volume — v base (+ type=perp|spot|all and optionally venue), or market

Steps: 1m, 5m, 15m, 1h, 4h, 1d (auto-raised to keep a response under 1500 points). Range up to 730 days. type: perp, spot, all. kind (long-short only): accounts, top_pos.

API FAQ

Do I need an API key?

No. Every endpoint on this page is public and free, the same JSON the site's own pages call.

Can I resell this data?

No. Treat it as swolecharts-derived aggregates for your own use, dashboards or articles with attribution, not as a raw market-data feed to redistribute or resell.

Is there a rate limit?

No published limit, but there's no SLA either: poll a few times a minute per endpoint at most, and cache responses — most are already Cache-Control'd for 30–300 seconds depending on the step.

Why did /api/series/&lt;metric&gt; return an empty array?

Either the range predates this site tracking that market (see "gaps"), or the database was briefly unreachable ("error": "unavailable"); retry, it never 500s.

What metrics and aliases exist?

See the metric reference table above — it's generated from the same list the endpoint itself validates against, so it can't go out of date.