Balance update after transfer sent--stream
Streams the latest transaction balance as they happen, where transaction from is 0xafd8…f00e and token balance balance change reason code is 10: pre balance, post balance, pre balance in USD, post balance in USD and calculate.
What it returns
- pre balance
- post balance
- pre balance in USD
- post balance in USD
- calculate
Filters
- transaction from is 0xafd8…f00e
- token balance balance change reason code is 10
The subscription
subscription {
EVM {
TransactionBalances(
where: {TokenBalance: {BalanceChangeReasonCode: {eq: 10}}, Transaction: {From: {is: "0xafd8cd311c7bf2635573ebebb97c1a3c7e90f00e"}}}
orderBy: {descending: Block_Time}
limit: {count: 1}
) {
TokenBalance {
PreBalance
PostBalance
PreBalanceInUSD
PostBalanceInUSD
}
amount:calculate(expression: "$TokenBalance_PreBalance - $TokenBalance_PostBalance")
amount_usd:calculate(expression: "$TokenBalance_PreBalanceInUSD - $TokenBalance_PostBalanceInUSD")
}
}
}
Similar queries
- get latest balance of a pool and it's tokens · Ethereum · TransactionBalances
- balance of address stream · Ethereum · TransactionBalances
- Watch MEV Rewards to Builders · Ethereum · TransactionBalances
- All Self-Destruct Event Balances Stream · Ethereum · TransactionBalances
- token balance stream on EVM · Ethereum · TransactionBalances