API Reference

cfx_getBalance - Conflux

Returns the balance of the given account, identified by its address.

Parameters

  • BASE32 - Address to check for balance.
  • QUANTITY|TAG - (optional, default: "latest_state") Integer epoch number, or the string "latest_state", "latest_confirmed", "latest_checkpoint" or "earliest"

Returns

QUANTITY - Integer of the current balance in Drip.


Example

Request

curl -X POST \ --data '{"jsonrpc":"2.0","method":"cfx_getBalance","params":["cfx:aan8jr1vfpfctx5z68j0mfesn5y6e9b0ta16f4mc0f", "latest_state"],"id":1}' \ -H "Content-Type: application/json" \ https://cfx-core.unifra.io/v1/ad2eb3c7a9404cc6a35a6641eaf70577

Result

{ "jsonrpc": "2.0", "result": "0x49016ead61758c447", "id": 1 }
Path Params
string
required
Body Params
string
Defaults to 2.0
string
Defaults to cfx_getBalance
params
array of strings
params
int32
Defaults to 0
Responses

Language
URL
Click Try It! to start a request and see the response here! Or choose an example:
application/json