SocioCryptoBridges to Neutron using Satellite
Updated 2023-11-07
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
›
⌄
-- forked from Bridges to Neutron using Squid @ https://flipsidecrypto.xyz/edit/queries/4db57926-e181-4472-bbc9-1004e7b3a414
with prices as
(
SELECT CASE when symbol='BNB' then 'WBNB'
else symbol end as token_symbol, *
FROM osmosis.core.ez_prices
)
SELECT 'satellite' as platform,
source_chain,
--date_trunc('day',block_timestamp) as date,
count(DISTINCT sender) as n_senders,
count(DISTINCT tx_hash) as n_bridges,
sum(CASE when a.token_symbol in ('USDC','axlUSDC', 'FRAX') then amount else amount*price end) as vol,
avg(CASE when a.token_symbol in ('USDC','axlUSDC', 'FRAX') then amount else amount*price end) as avg_size
FROM axelar.core.ez_satellite a
LEFT JOIN prices b
on a.token_symbol = b.token_symbol AND date_trunc('hour',a.block_timestamp) = b.recorded_hour
WHERE destination_chain = 'neutron'
GROUP by 1,2
Run a query to Download Data