Skip to content
docs

computeBalanceChanges

computeBalanceChanges(accountKeys, snapshot, signer?): BalanceChanges | null

Defined in: simulate.ts:69

Balance changes from pre/post balances. accountKeys is the message’s account list in order (static keys, then the lookups’ writable, then readonly addresses — what loadedAddresses lists). A token account that exists on one side only (created or closed) counts from or to zero. Returns null when the balances are missing.

readonly (string | null)[]

BalanceSnapshot

string | null

BalanceChanges | null