get latest price and liquidity of a token in token pair
Returns balance updates on Ethereum, where balance update address is 0x1bCd…55eE and currency smart contract is 0x6b17…1d0f: sum of balance update amount and price in USD.
What it returns
- sum of balance update amount
- price in USD
Filters
- balance update address is 0x1bCd…55eE
- currency smart contract is 0x6b17…1d0f
The query
query MyQuery {
EVM(dataset: combined, network: eth) {
BalanceUpdates(
where: {BalanceUpdate: {Address: {is: "0x1bCd6B0E97B51D76FD1752111a1fe2b473F655eE"}},
Currency: {SmartContract: {is: "0x6b175474e89094c44da98b954eedeac495271d0f"}}}
) {
dai_liq: sum(of: BalanceUpdate_Amount)
joinDEXTradeByTokens(
Trade_Currency_SmartContract: Currency_SmartContract
orderBy: {descending: Block_Time}
limit: {count: 1}
) {
Trade {
PriceInUSD
}
}
}
}
}
Similar queries
- eth balance · Ethereum · BalanceUpdates
- Ethereum balance view · Ethereum · BalanceUpdates
- Balance update API explanation · Ethereum · BalanceUpdates
- MyQuery EVM · BNB Chain · BalanceUpdates
- usdt_holder_balance_update_ · Ethereum · BalanceUpdates