hessCurrent_TVL
    Updated 2 days ago
    with tvl_usdd as ( select * from (
    SELECT
    livequery.live.udf_api (
    'https://api.dune.com/api/v1/query/4281530/results?api_key=ZUTpBBwY5IhK5S1NfbV0EJ1VfVQ72wt3') as resp)
    ,
    table(FLATTEN(parse_json(resp:data:"result":"rows"))))
    ,
    tvl as (select TO_TIMESTAMP(REPLACE(value:"date", ' UTC', '')) AS date,
    value:"tvl" as "TVL (USD)"
    from tvl_usdd)
    ,
    price as ( select RECORDED_HOUR::date as day,
    avg(price) as prices
    from osmosis.price.ez_prices
    where symbol = 'SEI'
    group by 1)

    select date,
    "TVL (USD)",
    "TVL (USD)"/prices as "TVL (SEI)",
    prices
    from tvl a join price b on a.date= b.day
    order by 1 desc
    limit 2


    Last run: 1 day ago
    DATE
    TVL (USD)
    TVL (SEI)
    PRICES
    1
    2025-03-10 00:00:00.000
    295187594
    1450777413.603310.2034685619
    2
    2025-03-09 00:00:00.000
    298473993
    1445210259.27610.2065263453
    2
    136B
    23s