Get Account Info

Once your web application successfully connects to Adena, in most cases, you would first want to get information about the connected account. Use the getAccount method to receive a series of data about the account including its address, balance, public key, account number, and sequence.

Code

adena.GetAccount();

Params

Response

Account Model

Sample Request

adena.GetAccount()

Sample Response

{
   "code": 0,
   "status": "success",
   "type": "GET_ACCOUNT",
   "message": "Get account.",
   "data": {
      //status of the account; inactive if never used
      "status": "ACTIVE",
      //account address
      "address": "g1fnakf9vrd6uqn8qdmp88yam4p0ngy572answ9f",
      //account balance
      "coins": "3618115104ugnot",
      "public_key": {
        //key generation algorithm
        "@type": "/tm.PubKeySecp256k1",
        //public key value
        "value": "A3cWVULHSHC1mwK8o1vfJHKfNMvLEvKU/sHPQoFWRoey"
      },
      //account number
      "account_number": "5547",
      //nonce
      "sequence": "23"
      "chainId": "test3"
   },
}

Last updated