eosjs icon indicating copy to clipboard operation
eosjs copied to clipboard

How to get total balance and refund size

Open jeaimetu opened this issue 8 years ago • 2 comments

Hi, I used getCurrencyBalance and getAccount to get a EOS balance. However both returns are strange.

  1. getCurrencyBalance : this only returns "unstaked balance".

  2. getAccount : this is more strange. this returns staked size for bandwidth, CPU. There is field "result.voter_info.unstaking". in here what is the meaning of info.unstaking? Even I unstake some EOS, this field value does not change.

  3. so my questions is how to get a) Total balance b) Refund(Initiating unstake, so this will take 3 days to be completely unstaked.

  • all terms what I used are based on "http://eosflare.io".

thanks.

jeaimetu avatar Jun 15 '18 02:06 jeaimetu

Have you already checked EOSIO/eos for this answer? I can ask around for this but there is probably a discussion / feature in the works already.

see: https://github.com/eosio/eos/issues

jcalfee avatar Jun 15 '18 14:06 jcalfee

I used getTableRows to solve this.

jeaimetu avatar Jun 25 '18 03:06 jeaimetu