Skip to main content

platform.getBalance RPC Method

Get the balance of an asset controlled by a given address.

Updated on
Nov 2, 2023

platform.getBalance RPC Method

Parameters

addresses
array
An array of address strings

Returns

balance
string
The total balance, in nAVAX.
unlocked
string
The unlocked balance, in nAVAX.
lockedStakeable
string
The locked stakeable balance, in nAVAX.
lockedNotStakeable
string
The locked and not stakeable balance, in nAVAX.
balances
object
A mapping of addresses to their respective balances in atomic units
unlockeds
object
A mapping of addresses to their respective unlocked balances
lockedStakeables
object
A mapping of an address to its locked stakeable balance
lockedNotStakeables
object
A mapping of an address to its not locked stakeable balance
utxoIDs
array
A array of UTXO (Unspent Transaction Output) IDs, with each entry containing a transaction ID and output index
txID
string
The transaction id
outputIndex
integer
The output index
Request
1
curl --location --request POST https://docs-demo.avalanche-mainnet.quiknode.pro/ext/bc/C/rpc/ext/bc/P \
2
--header 'Content-Type: application/json' \
3
--data-raw '{
4
"jsonrpc":"2.0",
5
"id" :1,
6
"method" :"platform.getBalance",
7
"params" :{
8
"addresses":["P-avax1tnuesf6cqwnjw7fxjyk7lhch0vhf0v95wj5jvy"]
9
}
10
}'
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free