check buys/sells

Returns transfers on Ethereum and BNB Chain, where currency is 0x6e9a…7cee: amount.

By Ignacio · saved 24 January 2022 · Bitquery API v1

What it returns

Filters

The query

query ($address: String!, $currency: String!) {
  ethereum(network: bsc) {
    out: transfers(
      currency: {is: $currency}
      any: [{sender: {is: $address}}, {receiver: {is: $address}}]
    ) {
      buys: amount(receiver: {is: $address}, calculate: sum)
      sells: amount(sender: {is: $address}, calculate: sum)
    }
  }
}

Variables

{
  "address": "",
  "currency": "0x6e9aa690b2cc5de762348b5bbdec0b1b27267cee"
}

Similar queries