observeBalance

fun observeBalance(address: String): Flow<BigInteger>

Observe dust balance for an address (live updates).

Reactive Balance: Returns Flow that emits new balance whenever:

  • Database cache is updated (new tokens, state changes)

  • Time passes (dust generates)

Note on Time Updates: This Flow does NOT automatically emit every second as dust generates. To show live generation, collect this Flow and also poll periodically:

combine(
dustRepository.observeBalance(address),
ticker(1000) // Emit every second
) { balance, _ -> balance }

Return

Flow of balance in Specks

Parameters

address

Wallet address