DEX Structured Data Table

DEX Table Coverage:

Total Chains13
Total DEXs80
Total Pairs1,878,964
Total Trades3,594,991,700
Total Tokens1,652,424
Total Aggregators8

Metric Example: Cross Chain Trading Volume

SELECT sum(abs(amount0_usd)) as Volume
      , date_trunc('day', signed_at) as date
      , chain_name
FROM reports.dex 
WHERE chain_name IN ('eth_mainnet', 'arbitrum_mainnet', 'optimism_mainnet', 'matic_mainnet')
GROUP BY date, chain_name

DEX Trades Data Dictionary

Column NameData TypeDescription
chain_namestringStores the chain name.
chain_idintegerEvery chain_name has a unique number that acts as a numerical identifier for that chain.
block_heightintegerStores the block height.
signed_atdatetimeStores the timestamp.
tx_hashstringEvery transaction on the blockchain has a transaction hash (tx_hash) that acts as a unique identifier for that transaction. The tx_hash column allows you to query specific information from a particular transaction.
protocol_namestringStores the name of the DEX that facilitated the event.
protocol_addressstringStores the contract address of the DEX that facilitated the event.
versionfloatDEXs often have multiple version - e.g Uniswap V1, V2 and V3. The version column allows you to look at a specific version of the DEX.
forkstringMany DEXs are a fork of an already established DEX. The fork column allows you to see which DEX has been forked.
fork_versionstringSimilarly to the version column, fork_version gives you the version of the forked DEX. For example, most DEXs are a fork of Uniswap V2; therefore, fork = aave & fork_version = 2
aggregator_namestringStores the aggregator responsible for the event.
aggregator_addressstringStores the contract address of the aggregator responsible for the event.
eventstringStores the event taking place - e.g swap, add_liquidity and remove_liquidity.
pair_addressstringStores the address of the pair that the user interacts with.
token0_addressstringStores the address of token0 in the specific pair.
token0_tickerstringStores the ticker symbol of token0 in the specific pair.
token1_addressstringStores the address of token1 in the specific pair.
token1_tickerstringStores the ticker symbol of token1 in the specific pair.
amount0_unscaledfloatStores the raw, on-chain amount of token0 involved in the event. Blockchains don't work with decimal numbers which is why they multiply values by 10^num_decimal to turn decimal numbers (price or token amount) into integers. For example, instead of a transaction's gas cost being 0.000000000000000001 ether, it's shown as 1 wei. Therefore, this field has all the raw token amounts that are multiplied by 10^num_decimal.
amount0floatStores the amount of token0 used in the transaction. For example, 1 ETH, 100 USDC, 30 UNI, etc.
amount0_usdfloatStores the USD amount of token0 used in the transaction.
amount1_unscaledfloatStores the raw, on-chain amount of token1 involved in the transaction.
amount1floatStores the amount of token1 used in the transaction. For example, 1 ETH, 100 USDC, 30 UNI, etc.
amount1_usdfloatStores the USD amount of token1 used in the transaction.
senderstringStores the wallet address that initiated the transaction.
gas_ethfloatStores the gas fee, denominated in ETH.
gas_usdfloatStores the gas fee, denominated in USD.