DEX Token Price Discovery
Returns DEX trades on Ethereum and Polygon, where buy currency is 0x623a…3665 or 0xb763…43e5 and sell currency is not 0x623a…3665 or 0xb763…43e5, sorted by date year date month: start of interval, month, year, buy currency address, decimals, buy currency name, buy currency symbol and 19 more fields.
What it returns
- start of interval
- month
- year
- buy currency address
- decimals
- buy currency name
- buy currency symbol
- token ID
- token type
- sell currency address
- sell currency name
- sell currency symbol
- base currency address
- base currency name
- base currency symbol
- quote currency address
- quote currency name
- quote currency symbol
- count
- price
- quote price
- buy amount
- sell amount
- base amount
- quote amount
- expression
Filters
- buy currency is 0x623a…3665 or 0xb763…43e5
- sell currency is not 0x623a…3665 or 0xb763…43e5
The query
query MyQuery($tokenAddresses: [String!]) {
ethereum(network: matic) {
dexTrades(
buyCurrency: {in: $tokenAddresses}
sellCurrency: {notIn: $tokenAddresses}
options: {asc: ["date.year", "date.month"]}
) {
date {
startOfInterval(unit: month, interval: 1)
month
year
}
buyCurrency {
address
decimals
name
symbol
tokenId
tokenType
}
sellCurrency {
address
decimals
name
symbol
tokenId
tokenType
}
baseCurrency {
address
name
symbol
decimals
tokenId
tokenType
}
quoteCurrency {
address
decimals
name
symbol
tokenId
tokenType
}
count
price(calculate: average)
quotePrice(calculate: average)
buyAmount(calculate: sum)
sellAmount(calculate: sum)
baseAmount(calculate: sum)
quoteAmount(calculate: sum)
buyAmountUSD: buyAmount(calculate: sum, in: USD)
sellAmountUSD: sellAmount(calculate: sum, in: USD)
baseAmountUSD: baseAmount(calculate: sum, in: USD)
quoteAmountUSD: quoteAmount(calculate: sum, in: USD)
quote_rate: expression(get: "sellAmountUSD / buyAmount")
}
}
}
Variables
{
"tokenAddresses": ["0x623a1350f6b749575f92ea54d0f745f9f07d3665", "0xb763f1177e9b2fb66fbe0d50372e3e2575c043e5"]
}
Similar queries
- trades · Ethereum · DEXTrades
- matic_DEXTrades · Polygon · DEXTrades
- prediction_dextrades · Polygon · DEXTrades
- matic MAPU trades · Polygon · DEXTrades
- List of DEX supported · Polygon · DEXTrades