theta.GetAccount

This API returns the details of the account being queried in json format.

Parameters

Object NameRequiredTypeDetail
addressStringthe address of the account
"params":[
    {
        "address":"0x2E833968E5bB786Ae419c4d13189fB081Cc43bab"
    }
]

Result

Result Fields

KeyTypeDetail
codeStringthe hash of the smart contract bytecode (for smart contract accounts)
coinsStringthe native token balance
reserved_fundsStringfund reserved for micropayment through the off-chain resource-oriented payment pool
rootStringthe root hash of the data Merkle-Patricia trie (for smart contract accounts)
sequenceStringthe current sequence number of the account

Example

Request

curl <your-endpoint> \
    -X POST \
    -H "Content-Type: application/json" \
    -d '{"jsonrpc":"2.0","method":"theta.GetAccount","params":[{"address":"0x2E833968E5bB786Ae419c4d13189fB081Cc43bab"}],"id":1}'

Return

{
    "jsonrpc": "2.0",
    "id": 1,
    "result": {
        "sequence": "82",
        "coins": {
            "thetawei": "0",
            "tfuelwei": "0"
        },
        "reserved_funds": [],
        "last_updated_block_height": "735970",
        "root": "0x0000000000000000000000000000000000000000000000000000000000000000",
        "code": "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"
    }
}
Language
Click Try It! to start a request and see the response here!