Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.dune.com/llms.txt

Use this file to discover all available pages before exploring further.

The tokens_xrpl.transfers table contains token movement data for XRP Ledger assets indexed on Dune. It brings native XRP transfers, issued currency payments, checks, escrows, payment channel claims, and AMM-related token movement into one curated table. This dataset includes:
  • Native XRP and issued currency transfer rows
  • Payment, check, escrow, payment channel, AMM deposit, and AMM withdraw activity
  • Asset identifiers using xrpl_asset_id, issuer, currency, and currency hex fields
  • USD valuation when an hourly USD price is available for the asset
This table represents token movement on XRP Ledger, not just simple Payment transactions. It also includes AMM liquidity movements and other transaction types that move XRP or issued currencies, so filter by transfer_type or transaction_type when you need a narrower view.

Utility

The XRPL transfers table provides a consistent view of token movement on XRP Ledger, enabling you to:
  • Track flows of XRP and issued currencies between XRPL accounts
  • Analyze transfer activity by asset, issuer, transaction type, and day
  • Separate regular payments from checks, escrows, payment channels, and AMM liquidity activity
  • Monitor partial payments and transaction results alongside the normalized transfer amount

Methodology

According to the official XRP Ledger docs, fungible assets include native XRP and issued currencies held through trust lines, while Payment transactions can deliver XRP or issued currencies and may also use partial payment semantics. XRPL also has protocol-native checks, escrows, payment channels, and AMM deposit and withdraw transactions that can move assets. The tokens_xrpl.transfers table is built around those XRPL transaction semantics:
  • It keeps successful XRPL transactions that produce token movement, including Payment, CheckCash, EscrowFinish, PaymentChannelClaim, AMMDeposit, and AMMWithdraw.
  • It normalizes native XRP and issued currencies into a shared transfer schema with from, to, issuer, currency, symbol, and xrpl_asset_id.
  • It labels each row with both the underlying transaction_type and a normalized transfer_type, such as payment, check_cash, escrow_finish, payment_channel_claim, amm_deposit, amm_withdraw, amm_lp_mint, and amm_lp_burn.
  • It carries partial_payment_flag for XRPL Payment rows where partial payment semantics apply.
  • Native XRP uses 6 decimals; issued currencies may not have a decimal value populated because XRPL issued currencies use their own decimal representation.

Pricing Methodology

The price_usd and amount_usd columns come from Dune’s external hourly price feed for XRPL assets. If an asset has a price for that hour, the transfer row gets a USD price and value. If not, both columns stay NULL. For more details on Dune’s pricing methodology, see the Prices documentation.

Table Schema

ColumnTypeDescription
unique_keyVARCHARSurrogate key to identify a unique transfer row
blockchainVARCHARBlockchain name; always xrpl
block_monthDATEMonth of the ledger close time
block_dateDATEDate of the ledger close time
block_timeTIMESTAMP WITH TIME ZONELedger close timestamp
block_numberBIGINTXRPL ledger index
tx_hashVARCHARTransaction hash
token_standardVARCHARToken standard label, such as native or issued
tx_fromVARCHARAccount that submitted the transaction
tx_toVARCHARDestination account from the transaction when available
tx_indexBIGINTTransaction index within the ledger
fromVARCHARSource account for the token movement
toVARCHARDestination account for the token movement
xrpl_asset_idVARCHARDune asset identifier for the XRPL asset
issuerVARCHARIssuer account for issued currencies; native XRP uses the native XRP identifier
currencyVARCHARXRPL currency code or native XRP symbol
currency_hexVARCHARHex-encoded currency code when applicable
symbolVARCHARDisplay symbol for the asset
decimalsINTEGERNumber of decimals used to scale amount_raw when available
amount_rawDOUBLERaw amount from the XRPL transfer representation
amountDOUBLENormalized transfer amount
price_usdDOUBLEHourly USD price used to calculate amount_usd
amount_usdDOUBLEUSD value of the transfer
transfer_typeVARCHARNormalized transfer category
transaction_typeVARCHARUnderlying XRPL transaction type
transaction_resultVARCHARXRPL transaction result code
partial_payment_flagBOOLEANWhether the transaction used XRPL partial payment semantics
_updated_atTIMESTAMP WITH TIME ZONETimestamp when the curated row was last written

Sample Queries

Query token movement for a specific XRPL account This query returns recent incoming and outgoing token transfers for an XRPL account:
SELECT
    block_time,
    tx_hash,
    symbol,
    transfer_type,
    transaction_type,
    CASE
        WHEN "from" = 'r3CUuqXukpx393PvgP6Cn2z3kx5vPmesWf' THEN 'Outgoing'
        WHEN "to" = 'r3CUuqXukpx393PvgP6Cn2z3kx5vPmesWf' THEN 'Incoming'
    END AS direction,
    amount,
    amount_usd
FROM tokens_xrpl.transfers
WHERE (
        "from" = 'r3CUuqXukpx393PvgP6Cn2z3kx5vPmesWf'
        OR "to" = 'r3CUuqXukpx393PvgP6Cn2z3kx5vPmesWf'
    )
    AND block_date >= current_date - interval '30' day
ORDER BY block_time DESC
LIMIT 100
Calculate daily transfer volume for native XRP This query aggregates recent native XRP transfer activity:
SELECT
    block_date,
    symbol,
    COUNT(*) AS num_rows,
    SUM(amount) AS total_amount,
    SUM(amount_usd) AS total_amount_usd
FROM tokens_xrpl.transfers
WHERE xrpl_asset_id = 'xrp'
    AND block_date >= current_date - interval '30' day
GROUP BY 1, 2
ORDER BY 1 DESC
Split XRPL activity by transfer type This query separates regular payments from checks, escrows, payment channels, and AMM activity:
SELECT
    block_date,
    transfer_type,
    transaction_type,
    COUNT(*) AS num_rows,
    SUM(amount) AS total_amount,
    SUM(amount_usd) AS total_amount_usd
FROM tokens_xrpl.transfers
WHERE block_date >= current_date - interval '30' day
GROUP BY 1, 2, 3
ORDER BY 1 DESC, 4 DESC