Skip to main content
Account data is available through both the high-level client and the auth extension. Use StargateClient methods for most cases, and drop down to the auth extension when you need the raw protobuf response.

Using StargateClient

getAccount returns null for addresses that have never received tokens. getSequence throws if the account does not exist.

Supported Account Types

The default accountFromAny parser handles these Cosmos SDK account types: Any unrecognized type URL causes accountFromAny to throw. Use a custom AccountParser to handle chain-specific account types.

Using the Auth Extension Directly

The auth extension returns the raw protobuf Any type. StargateClient parses this with accountFromAny, which handles BaseAccount, ModuleAccount, and all vesting account types.

Custom Account Parser

Chains with non-standard account types require a custom AccountParser:
Fall back to accountFromAny for standard types so your parser stays forward-compatible with Cosmos SDK updates.

Next Steps

Bank Queries

Token balances and supply.

Error Handling

Handle missing accounts and other query errors.