missing-data

Returns the latest 100 DEX trades by token on Base, where currency smart contract is 0xcbB7…33Bf, side currency smart contract is 0x4200…0006 and block time before 2025-05-10: block time, sum of trade side amount in USD, median of trade price in USD and median of trade price.

By Sebastian · saved 23 May 2025 · Bitquery API v2

What it returns

Filters

The query

query EVMTokenPrice {
    EVM(dataset: combined, network: base) {
        DEXTradeByTokens(
            orderBy: { descendingByField: "Block_Time"}
            limit: { count: 100 }
            where: {
              Block: {
            
                     Time: { before: "2025-05-10T10:00:00Z" }
                }
                Trade: {
                
                    Currency: {
                        SmartContract: { is: "0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf" }
                    },
                    Side: {
                        Currency: {
                            SmartContract: { is: "0x4200000000000000000000000000000000000006" }
                        }
                        AmountInUSD: { gt: "0.25" }
                    }
              
                    Success: true
                    PriceAsymmetry: { le: 0.1 }
                }
                TransactionStatus: {Success: true}
            }
        ) {
            Block {
                Time(interval: {in: hours, count: 1 })
            }
            volume: sum(of: Trade_Side_AmountInUSD)
            price: median(of: Trade_PriceInUSD)
            priceNative: median(of: Trade_Price)
        }
    }
}

Similar queries