SwapsGetting

Returns the latest 5 events on BNB Chain, where log smart contract is 0x5fbf…835d, signature name is Swap and block date since 2023-10-10: smart contract, exit index, transaction hash, gas price, transaction index, gas, from and 9 more fields.

By Vertex · saved 16 November 2023 · run 4 times · Bitquery API v2

What it returns

Filters

The query

query Get_Ext_Swap($since: String, $till: String, $address: String, $limit: Int, $offset: Int, $chain: evm_network = bsc) {
  EVM(dataset: combined, network: $chain) {
    Events(
      orderBy: {descending: Block_Number}
      limit: {count: $limit, offset: $offset}
      where: {Log: {SmartContract: {is: $address}, Signature: {Name: {is: "Swap"}}, ExitIndex: {}}, Block: {Date: {since: $since, till: $till}}, TransactionStatus: {Success: true}}
    ) {
      Log {
        SmartContract
        ExitIndex
      }
      Transaction {
        Hash
        GasPrice
        Index
        Gas
        From
        Nonce
        Value
        To
      }
      Block {
        Number
        Time
      }
      Arguments {
        Name
        Value {
          ... on EVM_ABI_Address_Value_Arg {
            address
          }
          ... on EVM_ABI_BigInt_Value_Arg {
            bigInteger
          }
        }
        Type
      }
    }
  }
}

Variables

{
  "since": "2023-10-10",
  "till": "2023-11-16",
  "address": "0x5fbf666f8fbc7abe3a5ad59565afcd0323ff835d",
  "limit": 5,
  "offset": 0,
  "evm_network": "bsc"
}

Similar queries