1

I found this endpoint is to obtain the token balance from Ethereum blockchain, however, I noticed that this function doesn't work on Rospten network. Please advise

https://api.etherscan.io/api?module=account&action=tokenbalance&contractaddress=0x6bb495e358d7aab0540d9b38996e715fcc4f1ba2&address=0x63a5f2232a519321237e31d0a79f6c20e0e652d3&tag=latest&apikey=JKXR76EA1NK9XSKES1T2BNYBZ41T3BJ2JH

Possible I could have the same function works on Ropsten network?

0

According to the docs, you must simply append "-ropsten" to the subdomain. Your URL should look as follows:

https://api-ropsten.etherscan.io/api?module=account&action=tokenbalance&contractaddress=0x6bb495e358d7aab0540d9b38996e715fcc4f1ba2&address=0x63a5f2232a519321237e31d0a79f6c20e0e652d3&tag=latest&apikey=JKXR76EA1NK9XSKES1T2BNYBZ41T3BJ2JH
  • @shane- you saved my day! Thank you so much – DavidB Aug 11 at 7:52
  • @shane- I have a quick question for you here, can I have my local private geth node running on my local server with the etherscan api ? – DavidB Aug 13 at 1:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.