Afonso_DiazTop Swappers
    Updated 2025-04-08
    with

    pricet as (
    select
    hour::date as date,
    token_address,
    avg(price) as token_price_usd
    from
    ink.price.ez_prices_hourly
    group by 1, 2
    ),

    txns as (
    select
    tx_hash,
    block_timestamp,
    origin_from_address as swapper,
    a.contract_address as token_out,
    b.contract_address as token_in,
    nvl(a.decoded_log:value, a.decoded_log:wad) as amount_out_unadj,
    nvl(b.decoded_log:value, b.decoded_log:wad) as amount_in_unadj
    from
    ink.core.ez_decoded_event_logs a
    join
    ink.core.ez_decoded_event_logs b using (tx_hash, block_timestamp, event_name)
    where
    a.event_name = 'Transfer'
    and nvl(a.decoded_log:from, a.decoded_log:src) = swapper
    and nvl(b.decoded_log:to, b.decoded_log:dst) = swapper
    and tx_succeeded
    and origin_to_address = '0x652e53c6a4fe39b6b30426d9c96376a105c89a95'
    and tx_hash in (select distinct tx_hash from ink.core.ez_decoded_event_logs where event_name = 'Swap')

    union all

    select
    Last run: about 2 months ago
    SWAPPER
    SWAPS
    VOLUME_USD
    AVERAGE_AMOUNT_USD
    1
    0xea9c63b4abe4302e93272f4ed479f9b41ffa242b300943519.6098564123145.065366188
    2
    0x628ca62ada2762d37716309e8f40f301e5b5d9f11384303628.856827372219.385012159
    3
    0x64c2cc66b764a7adadbfee7d7f048b85eac03846234165068.700365259705.421796433
    4
    0xf76400be96d91e4d645e7c8cae70c0886dfd170a531125463.135737114236.277091784
    5
    0xadfa990003337a372f35315abac9dd50a4c14315345118957.492640049344.804326493
    6
    0x2bd37ee76d757c59d2afefb608f4fb7d74c077e150892315.776693977181.72396987
    7
    0x3a137fb6b0808628b6031071df0e9455be5a216317988122.081553016492.302131581
    8
    0xb6f28ae8f31d85dc27361852b986286113bc588d19286554.038625731450.802284509
    9
    0x10b60a2724d9b323bdf0ed11be527e0c35da772d17875696.068430944425.25881141
    10
    0xbbd33948107e6c6e2bd6d5fee16f85abad3a4f071653260.0583083893328.753644274
    10
    816B
    11s