Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

multiCandle

Streams the open candle of up to 8 coins on one subscription. Served by the API service at /api-ws.

ChannelmultiCandleserver → client · type multiCandle

Keep the last bar of up to 8 coins live on one subscription, e.g. a markets list with sparklines.

Subscribe
{
  "method": "subscribe",
  "subscription": {
    "type": "multiCandle",
    "coins": [
      "BTC",
      "ETH"
    ],
    "interval": "1m"
  }
}
Try it
WS wss://rpc.txflow-testnet.xyz/api-ws
Subscription parameters
coinsstring[]required

Up to 8 coins. Use base names (`BTC`): candles are keyed by base name, so `BTC-USDC` would key the first push differently from the rest.

intervalstringrequired
"1m""3m""5m""15m""30m""1h""2h""4h""8h""12h""1d"
typestringrequired
"multiCandle"
Server message
channelstring
"multiCandle"
dataobject
candlesobject

Coin → its latest candle. A push carries only the coins that changed.

intervalstring
Message example
{
  "channel": "multiCandle",
  "data": {
    "interval": "1m",
    "candles": {
      "BTC": {
        "t": 1791894480000,
        "T": 1791894539999,
        "s": "BTC",
        "i": "1m",
        "o": "83264.9",
        "h": "83290.7",
        "l": "83264.9",
        "c": "83276.9",
        "v": "0.0804",
        "n": 17
      }
    }
  }
}

data.candles maps each coin to its latest candle and carries only the coins that changed since the previous push (updates are coalesced over about 200 ms). Subscribe with base names such as BTC: candles are keyed by their s field, which is the base name, so subscribing with BTC-USDC keys the first push differently from later ones. Seed each chart with candleSnapshot; for a single coin use candle.