Query PancakeSwap Pairs created for Token

Returns 10 arguments on Ethereum and BNB Chain, where smart contract address is 0xBCfC…2812 and smart contract event is PairCreated, sorted by block height: block height, any of argument value, tx from address and transaction hash.

By richard.pinedo · saved 11 March 2021 · run 7 times · Bitquery API v1

What it returns

Filters

The query

{
  ethereum(network: bsc) {
    arguments(
      smartContractAddress: {is: "0xBCfCcbde45cE874adCB698cC183deBcF17952812"}
      smartContractEvent: {is: "PairCreated"}
      options: {asc: "block.height", limit: 10}
    ) {
      block {
        height
      }
      any(
        of: argument_value
        argument: {is: "token0"}
        value: {in: "0x1af3b59a839e97e944c65177ab3a024b499133f8"}
      )
      transaction {
        txFrom {
          address
        }
        hash
      }
    }
  }
}

Similar queries