Subscription OHLC by intervals
Streams 2000 DEX trades by token on BNB Chain as they happen, where side currency smart contract is 0xd6fd…44ec and currency smart contract is 0xbb4c…095c, sorted by block time: chain ID, block time, sum of trade amount, trade price, side currency symbol, currency symbol and count.
What it returns
- chain ID
- block time
- sum of trade amount
- trade price
- side currency symbol
- currency symbol
- count
Filters
- side currency smart contract is 0xd6fd…44ec
- currency smart contract is 0xbb4c…095c
The subscription
subscription pair($network: evm_network, $baseCurrency: String, $quoteCurrency: String) {
EVM(network: $network) {
DEXTradeByTokens(
orderBy: {ascendingByField: "Block_Time"}
where: {Trade: {Side: {Currency: {SmartContract: {is: $baseCurrency}}}, Currency: {SmartContract: {is: $quoteCurrency}}}}
limit: {count: 2000}
) {
ChainId
Block {
Time(interval: {in: minutes, count: 15})
}
volume: sum(of: Trade_Amount)
Trade {
high: Price(maximum: Trade_Price)
low: Price(minimum: Trade_Price)
open: Price(minimum: Block_Number)
close: Price(maximum: Block_Number)
Side {
Currency {
Symbol
}
}
Currency {
Symbol
}
}
count
}
}
}
Variables
{
"network": "bsc",
"baseCurrency": "0xd6fdde76b8c1c45b33790cc8751d5b88984c44ec",
"quoteCurrency": "0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c",
"interval": 15,
"till": "2023-08-01",
"from": "2023-04-30"
}
Similar queries
- USD1 trades on fourmeme · BNB Chain · DEXTradeByTokens
- BSC trades · BNB Chain · DEXTradeByTokens
- monitor mempool trades bsc · BNB Chain · DEXTradeByTokens
- Tokens on BSC network · BNB Chain · DEXTradeByTokens
- token price stream · BNB Chain · DEXTradeByTokens