Skip to main content

Get account balance

GET

Returns the balance of coin/fungible asset (primary fungible asset store only) for the specified account, asset type, and ledger version of a specific transaction. If no ledger version is specified in the request, the latest ledger version is used.Aptos nodes prune account state history according to a configurable retention period. If the requested ledger version has been pruned, the server responds with a 410 status code.
Path Parameters
chainstringrequired
Parameter specifying the target chain to query.
networkstringrequired
Parameter specifying the network of the target chain.
addressstringrequired
The address of the account to retrieve. Account addresses without the hexadecimal prefix can also be queried.
asset_typestringrequired
A parameter used to specify the type of asset to retrieve.The asset type must be provided in one of the following formats:
  • Coin: Struct-form asset ID (e.g., 0x1::aptos_coin::AptosCoin)
  • Fungible Asset: Object address that owns the Token Metadata (e.g., 0xa)
Query Parameters
ledger_versioninteger
The ledger version of the transaction to fetch account state from.If no value is provided, the latest version is used.
Responses
codestringrequired
Code identifying the cause of the failed request.
messagestringrequired
Detailed message including the name and value of the invalid parameter.
{
"code": "ERROR_CODE",
"message": "Bad Request"
}
cURL
curl -X GET 'https://aptos-mainnet.nodit.io/v1/accounts/0x1/balance/0x1::aptos_coin::AptosCoin' \
-H 'Content-Type: application/json' \
-H 'X-API-KEY: nodit-demo'