Sub updates balance for usdc example

Streams balance updates on Ethereum as they happen, where currency smart contract is 0xa0b8…eb48 and balance update address is not 0x: block number, block time, balance update amount, balance update type, currency symbol, currency name and smart contract.

By Aleksey · saved 12 February 2024 · Bitquery API v2

What it returns

Filters

The subscription

subscription ($network: evm_network,  $token: String!) {
  EVM(network: $network) {
    BalanceUpdates(
      where: {
        BalanceUpdate: {Address: {not: "0x"}}
        Currency: {SmartContract: {is: $token}}
      }
    ) {
      Block {
        Number
        Time
      }
      BalanceUpdate {
        Amount
        Type
      }
      Currency {
        Symbol
        Name
        SmartContract
      }
    }
  }
}

Variables

{"network":"eth","token":"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48"}

Similar queries