Trades for a given address for an specific currency

Returns the latest 10 DEX trades on Ethereum, where buy buyer is 0x1f77…b167, buy currency smart contract is 0x497a…65a8 and buy seller is 0x1f77…b167: block number, block time, from, to, transaction hash, buy amount, buy buyer and 12 more fields.

By gaurav · saved 1 March 2023 · run 55 times · Bitquery API v2

What it returns

Filters

The query

{
  EVM(dataset: combined, network: eth) {
    buyside: DEXTrades(
      limit: {count: 10}
      orderBy: {descending: Block_Time}
      where: {Trade: {Buy: {Buyer: {is: "0x1f77dfeb0e6fed1ecf0b41d4c81330df6a6fb167"}, Currency: {SmartContract: {is: "0x497a9a79e82e6fc0ff10a16f6f75e6fcd5ae65a8"}}}}}
    ) {
      Block {
        Number
        Time
      }
      Transaction {
        From
        To
        Hash
      }
      Trade {
        Buy {
          Amount
          Buyer
          Currency {
            Name
            Symbol
            SmartContract
          }
          Seller
          Price
        }
        Sell {
          Amount
          Buyer
          Currency {
            Name
            SmartContract
            Symbol
          }
          Seller
          Price
        }
      }
    }
    sellside: DEXTrades(
      limit: {count: 10}
      orderBy: {descending: Block_Time}
      where: {Trade: {Buy: {Seller: {is: "0x1f77dfeb0e6fed1ecf0b41d4c81330df6a6fb167"}, Currency: {SmartContract: {is: "0x497a9a79e82e6fc0ff10a16f6f75e6fcd5ae65a8"}}}}}
    ) {
      Block {
        Number
        Time
      }
      Transaction {
        From
        To
        Hash
      }
      Trade {
        Buy {
          Amount
          Buyer
          Currency {
            Name
            Symbol
            SmartContract
          }
          Seller
          Price
        }
        Sell {
          Amount
          Buyer
          Currency {
            Name
            SmartContract
            Symbol
          }
          Seller
          Price
        }
      }
    }
  }
}

Similar queries