0

Let's say I've created an Ethereum account using this code:

web3.eth.accounts.create();
> {
    address: "0xb8CE9ab6943e0eCED004cDe8e3bBed6568B2Fa01",
    privateKey: "0x348ce564d427a3311b6536bbcff9390d69395b06ed6c486954e971d960fe8709",
    signTransaction: function(tx){...},
    sign: function(data){...},
    encrypt: function(password){...}
}

How do I connect (unlock) to that account later and see all the ETH and other tokens it contains?

Alon
  • 10,381
  • 23
  • 88
  • 152

1 Answers1

0

How do I connect (unlock) to that account later and see all the ETH and other tokens it contains?

eth.accounts shows you all known accounts. To unlock and see balance of the first one:

> personal.lockAccount(eth.accounts[0])
> eth.getBalance(eth.accounts[0])
palik
  • 2,425
  • 23
  • 31