Afonso_Diazby route
    Updated 2025-05-02
    with

    main as (
    select
    tx_hash,
    block_timestamp,
    origin_from_address as user,
    symbol_in,
    symbol_out,
    split(platform, '-')[0] as platform,
    greatest(symbol_in, symbol_out) || ' - ' || least(symbol_in, symbol_out) as token_pair,
    case
    when symbol_in in ('USDC', 'USDT', 'USDC.e', 'DAI') then 'StableCoin'
    when token_in = '0x19aac5f612f524b754ca7e7c41cbfa2e981a4432' then 'WKLAY'
    else 'Other'
    end || ' -> ' || case
    when symbol_out in ('USDC', 'USDT', 'USDC.e', 'DAI') then 'StableCoin'
    when token_out = '0x19aac5f612f524b754ca7e7c41cbfa2e981a4432' then 'WKLAY'
    else 'Other'
    end as route,
    case
    when symbol_in in ('USDC', 'USDT', 'USDC.e', 'DAI') then amount_in
    when symbol_out in ('USDC', 'USDT', 'USDC.e', 'DAI') then amount_out
    else nvl(amount_in_usd, amount_out_usd)
    end as amount_usd
    from
    kaia.defi.ez_dex_swaps
    where
    amount_usd > 0
    and block_timestamp >= '2024-01-01'

    )

    select
    route,
    count(distinct tx_hash) as swaps,
    Last run: 27 days ago
    ROUTE
    SWAPS
    SWAPPERS
    VOLUME_USD
    AVERAGE_AMOUNT_USD
    DAILY_AVERAGE_SWAPS
    DAILY_AVERAGE_SWAPPERS
    1
    StableCoin -> Other1412452117398227094642.519257143.5195038943174.049438263.81573
    2
    Other -> Other146560206403006470.618.23075701429.79472160.527859
    3
    StableCoin -> WKLAY1606837168861409059294.601897222.7792803923610.869663379.462921
    4
    WKLAY -> Other2006236341069289185759.59124.038944484538.995475771.649321
    5
    Other -> StableCoin1478334141429227122895.430634136.5513735113329.581081318.533784
    6
    StableCoin -> StableCoin7042144412196036518.846962109.2302184761582.50337199.148315
    7
    Other -> WKLAY2053793333173297083776.04126.5305672724657.126984755.494331
    8
    WKLAY -> StableCoin1746423178257433882111.774333213.9238735743924.546067400.577528
    8
    708B
    14s