Portal Community

getBalance

Returns an account's HBAR balance plus any HTS tokens it holds.

FieldTypeRequiredDescription
accountIdtext✓ YesHedera account ID, e.g. 0.0.98
networkselectNoSee Networks. Defaults to Hedera:DefaultNetwork.

Example response:

{
  "accountId": "0.0.98",
  "balanceTinybars": 500000000,
  "balanceHbar": 5.0,
  "tokens": [
    { "tokenId": "0.0.12345", "balance": 1000, "decimals": 2 }
  ]
}

getInfo

Returns account metadata beyond just the balance.

FieldTypeRequiredDescription
accountIdtext✓ YesHedera account ID, e.g. 0.0.98
networkselectNoSee Networks. Defaults to Hedera:DefaultNetwork.

Example response:

{
  "accountId": "0.0.98",
  "evmAddress": "0x0000000000000000000000000000000000000062",
  "memo": "treasury account",
  "autoRenewPeriodSeconds": 7776000,
  "key": { "type": "ED25519", "key": "302a300506032b6570032100..." },
  "deleted": false
}
Response FieldMeaning
evmAddressThe account's 20-byte EVM-compatible alias address, if one exists.
memoFree-text memo set on the account.
autoRenewPeriodSecondsHow often the account auto-renews (and is charged a renewal fee) if not otherwise deleted.
keyThe account's public key and key type (e.g. ED25519, ECDSA_SECP256K1).
deletedWhether the account has been deleted on-network.
getBalance vs. getInfo: Use getBalance when you only need the HBAR/token numbers — it's the lighter call. Use getInfo when you need account metadata like the EVM address or key, e.g. before constructing a cross-chain reference.