correct_date_time

Returns the latest DEX trades on Ethereum, where smart contract address is 0x79dc…c796, time since 2024-04-01 and time till 2024-04-04: iso8601, block height, trade index, protocol, full name, address address, annotation and 9 more fields.

By Omkar_BQ · saved 5 April 2024 · Bitquery API v1

What it returns

Filters

The query

{
  ethereum(network: ethereum,) {
    dexTrades(
      options: {desc: ["block.height", "tradeIndex"], offset: 0}
      time: {since: "2024-04-01T14:44:19", till: "2024-04-04T14:44:19"}
      smartContractAddress: {is: "0x79dcf937272c49fe83002cf3e341c6edc153c796"}
    ) {
      block {
        timestamp {
          iso8601
        }
        height
      }
      tradeIndex
      protocol
      exchange {
        fullName
      }
      smartContract {
        address {
          address
          annotation
        }
      }
      buyAmount
      buyCurrency {
        address
        symbol
      }
      buy_amount_usd: buyAmount(in: USD)
      sellAmount
      sellCurrency {
        address
        symbol
      }
      sell_amount_usd: sellAmount(in: USD)
      buyPriceInUSD: expression(get: "buy_amount_usd / buyAmount")
      sellPriceInUSD: expression(get: "sell_amount_usd / sellAmount")
      transaction {
        hash
      }
      price
    }
  }
}

Similar queries