THORChain Data: Index Cross-Chain Swaps, Outbounds, and Pools

Index THORChain swaps, streaming swaps, outbounds, refunds, liquidity, and pool balance changes, delivered to your own database. Real-time and complete historical data, no THORNode to run.


THORChain is a decentralized cross-chain liquidity protocol that lets users add liquidity or swap native assets across chains, without pegging or wrapping them. A network of nodes observes transactions arriving at THORChain's vaults on each supported chain, agrees on the user's intent, which is usually expressed as a memo in the inbound transaction, and then executes the swap and sends the output asset on the destination chain. It brands itself as a DEX for swapping Bitcoin, Ethereum, and other native assets.

THORChain itself is a Cosmos SDK chain running on CometBFT, so its record of all that cross-chain activity is a stream of ABCI events. Swaps, streaming swaps, outbounds, refunds, liquidity adds, and pool balance changes are emitted at the block level, while observation and price-feed messages arrive as transactions. Indexing Co ingests THORChain blocks with their transaction results and events and delivers the rows you shape to your PostgreSQL, warehouse, or webhook. See how the project frames it at thorchain.org.

Source THORChain blocks
Ingest tx + block events
Decode swap, outbound events
Transform your JavaScript
Deliver your database

Why THORChain data is hard

One Swap, Many Chains A swap starts with an inbound transaction on one chain, is executed on THORChain, and ends with an outbound on another. The THORChain events tie it together through the inbound tx ID, source chain, addresses, and memo, and you need all of them to follow the trade end to end.
Most Events Are Block-Level Swaps, outbounds, refunds, liquidity adds, and pool balance changes show up in finalize_block_events, not inside the transaction that triggered them. Transaction results mostly hold node observation and price-feed messages. Read only tx results and you miss the trades.
Streaming Swaps Split Over Blocks Large trades can execute as streaming swaps, with sub-swaps spread across blocks and tracked by quantity, count, interval, and failed swap counters. Reconstructing the full trade means stitching those events together by tx ID.
Memos and Asset Strings Intent lives in memos like =:BSC.USDT:address:limit, and amounts come as strings like 2076124 ETH.ETH that pair a quantity with a CHAIN.ASSET identifier. Your pipeline has to parse both before the numbers are usable.

What Indexing Co delivers for THORChain

The DIY Path

Stand up and maintain the THORChain indexing stack yourself.

  • Run a THORNode, or rent CometBFT RPC, or depend on a hosted API.
  • Fetch block and block_results for every height.
  • Parse swap, outbound, refund, and pool events from finalize_block_events.
  • Build backfill, upgrade handling, and real-time delivery from scratch.
Indexing Co

THORChain blocks, tx results, and events, shaped by you, delivered to your store.

  • Swap, streaming swap, outbound, refund, and liquidity events.
  • Pool balance changes and network events from every block.
  • Lands in your PostgreSQL, BigQuery, warehouse, or webhook.
  • Real-time delivery plus complete backfilled history. No node to run.

What you can index

THORChain event type What it carries
swap Pool, inbound tx ID, chain, from, to, coin, memo, emitted asset, slip, liquidity fee in RUNE
streaming_swap Tx ID, interval, quantity, count, deposit, in, out, failed swaps
outbound, refund Inbound tx ID, destination chain, addresses, coin, memo, refund reason
add_liquidity, pool_balance_change, pol_reserve_deploy Pool, RUNE and asset amounts, provider addresses and units
trade_account_deposit, trade_account_withdraw Asset, amount, RUNE and asset addresses
rewards, gas, rev_share, mint_burn, burn Bond and fund rewards, per-asset gas amounts, THORName revenue share payouts, supply changes
oracle_price, message (tx level) Price feed symbols and prices, message action such as MsgDeposit

A transform, not a subgraph

You write the transform in JavaScript, not AssemblyScript, and change it without re-indexing from block zero. Indexing Co runs your function over each block server-side: read the block-level events you care about and return rows for your destination.

// Indexing Co transform: THORChain swaps and outbounds from block-level events
function transform(block) {
  const results = [];
  const height = Number(block.height);
  const time = block.block?.header?.time;

  for (const event of block.finalize_block_events || []) {
    if (event.type !== 'swap' && event.type !== 'outbound') continue;
    const attrs = {};
    for (const a of event.attributes || []) attrs[a.key] = a.value;
    results.push({
      chain: block._network,
      block: height,
      block_time: time,
      event_type: event.type,
      in_tx_id: attrs.in_tx_id || attrs.id,
      source_chain: attrs.chain,
      from_address: attrs.from,
      to_address: attrs.to,
      coin: attrs.coin,
      pool: attrs.pool || null,
      emit_asset: attrs.emit_asset || null,
      liquidity_fee_in_rune: attrs.liquidity_fee_in_rune || null,
      memo: attrs.memo,
    });
  }
  return results;
}

THORChain with Indexing Co

Run it yourself if

You want full control of THORChain infrastructure and have the team to operate a THORNode, parse block-level swap and pool events, and build backfill and delivery in-house.

Use Indexing Co if

You want THORChain swaps, outbounds, refunds, liquidity, and pool changes delivered to your own database, shaped by your transform, with real-time plus complete history and no node to run.

Get a DemoOpen the Console

Related Reading

FAQ

Do I need to run a THORNode?

No. Indexing Co sources THORChain blocks and transaction results for you, including history, so you do not operate a node or depend on a third-party endpoint.

Where are swaps in a THORChain block?

In finalize_block_events. Each swap event carries the pool, inbound tx ID, source chain, from and to addresses, coin, memo, emitted asset, and liquidity fee. The transform above reads them directly.

Can I follow a swap across chains?

On the THORChain side, yes. The swap and outbound events share the inbound tx ID and carry the source chain and addresses, so you can join inbound, swap, and outbound rows. Confirming the transactions on the external chains themselves is a separate pipeline on those networks.

Does Indexing Co parse memos and asset strings?

The pipeline delivers memos and coin strings exactly as THORChain emits them. Splitting a memo into action, target asset, and destination, or a coin string into amount and CHAIN.ASSET, is a few lines in your transform.

Where does the THORChain data go?

Into your own destination: PostgreSQL, BigQuery, a warehouse, or a webhook. You define the output schema and own the storage.

Get Started

Index THORChain in minutes. Set up your first swaps or liquidity pipeline without running a node.

Get a DemoOpen the Console