accountBalanceByAddress method

Future<AccountBalanceResponse> accountBalanceByAddress(
  1. String accountAddress
)

Return the /account/balance response for the specified account. @param {string} accountAddress The account address to get the balance of. @returns {Promise

Implementation

Future<rosetta.AccountBalanceResponse> accountBalanceByAddress(
    String accountAddress) async {
  assert(networkIdentifier != null, "Cannot get networkIdentifier");
  var result = await request('/account/balance', {
    "network_identifier": networkIdentifier,
    "account_identifier": {"address": accountAddress}
  });
  return rosetta.AccountBalanceResponse.fromMap(result);
}