Skip to content

Latest commit

 

History

History
33 lines (25 loc) · 1.3 KB

File metadata and controls

33 lines (25 loc) · 1.3 KB
description Returns the balance of the account of given address.

kaia_getBalance

Parameters

Name Type Description
address 20-byte DATA Address to check for balance.
block number or hash QUANTITY | TAG | HASH Integer or hexadecimal block number, or the string "earliest", "latest" or "pending", or block hash.

Return Value

Type Description
QUANTITY Integer of the current balance in peb.

Example

{% code overflow="wrap" %}

// Request
curl -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"kaia_getBalance","params":["0xc94770007dda54cF92009BFF0dE90c06F603a09f", "latest"],"id":1}' http://kaia.blockpi.network/v1/rpc/your-api-key

// Result
{
  "jsonrpc": "2.0","id":1,
  "result": "0x0234c8a3397aab58" // 158972490234375000
}

{% endcode %}