Portal Community

getBalance

Reads free, reserved, and frozen balance plus the account nonce from the chain's System.Account storage map, decoded directly from the SCALE-encoded response — no indexer or third-party API involved.

FieldTypeRequiredDescription
networkselect✓ Yescentrifuge | altair | development. No default — see Networks.
addresstext✓ YesSS58 address to query. Must be encoded with the SS58 prefix matching network.

Example response:

{
  "address": "4d3...",
  "freeBalance": "5000000000000000000",
  "reservedBalance": "0",
  "frozenBalance": "0",
  "nonce": 3,
  "status": "success"
}
Response FieldMeaning
freeBalanceTransferable balance, in base units (Planck) as a decimal string.
reservedBalanceReserved (non-transferable) balance, in base units.
frozenBalanceFrozen balance, in base units.
nonceAccount nonce — useful for diagnosing a stuck extrinsic once write operations ship.
All amounts are base-unit strings. freeBalance and friends come back as Planck (base-unit) decimal strings, not human CFG/AIR amounts — pass them through utility.convertUnits with the network's native decimals (18 for both CFG and AIR) to get a display value.

Validation and Error Behavior

SituationError Code
network missingCFG_MISSING_NETWORK
address missingCFG_MISSING_ADDRESS
network not a recognized keyCFG_INVALID_NETWORK
address fails SS58 checksumVAL_INVALID_SS58_ADDRESS
address's embedded SS58 prefix doesn't match network's prefixVAL_NETWORK_MISMATCH
Never-funded accounts aren't an error. If System.Account storage is empty for the address (it has never received a transfer), the node returns a successful result with all three balances at "0" and nonce: 0 — a zero balance is normal chain state, not a failure.
Address/network mismatch is a hard guard, not a warning. The same 32-byte public key is a valid address on every SS58 network — only the prefix differs. Rather than silently reading storage under a reinterpreted prefix, a prefix mismatch between address and network fails outright with VAL_NETWORK_MISMATCH. Use utility.convertAddress to re-encode an address for the network you actually intend to query.

account.transfer — Not Available

A native transfer operation (balances.transfer_keep_alive) is designed at the Services layer, but it is not wired into this node's routing and always returns CHAIN_SIGNING_NOT_AVAILABLE when invoked directly against the service — there is no production-grade .NET Substrate client capable of sr25519 signing today. See Roadmap.