0

I am trying to get the transactions of an address using https://api.etherscan.io/api?module=account&action=txlist&address=0x9bb1499d06f3036a12f653f00b889731d04c47a0&startblock=0&endblock=92649034&sort=asc&apikey=XXXXX

however, I get the results "No transactions found" when in fact, a transaction exists, and can be viewed on etherscan.io site.

I wonder if anyone has encountered the same problem. Is this a bug on the etherscan side? Perhaps the api.etherscan side doesnt not have the most recent transaction information?

Any insights would be greatly appreciated! Thanks!!enter image description here

Marci Banez
  • 115
  • 1
  • 9

1 Answers1

0

The txlist endpoint only returns transactions from and to to the specified address.

You're trying to view transactions from and to address 0x9bb1.... But this specific tx (on the screenshot) originated from 0x2204... and was sent to contract 0x30ad....

The 0x9bb1... only acts in the event logs produced by the transactions, and most likely the tx was executing a transfer() function with this address as a param.

TLDR: When you're transfering tokens, you're sending a transaction to the token contract - not to the token recepient.

Petr Hejda
  • 40,554
  • 8
  • 72
  • 100
  • Thanks for the insights! I understand what you mean. So if i want to check these transfer() information, what etherscan endpoint do you reckon i should use? And btw, I use to be able to view this transfer() details just fine previously... – Marci Banez Jun 17 '21 at 09:52
  • You can use the `tokentx` action of the `accounts` module ([docs](https://etherscan.io/apis#accounts)). – Petr Hejda Jun 17 '21 at 11:20
  • Thanks for the info! Anyway, yesterday seemed to be a problem on the Etherscan side. It worked after a few hours. Their api endpoint must not have been fully updated like the one on their website. – Marci Banez Jun 18 '21 at 03:16
  • I'm facing this issue too and just saw this. I'm not sure I fully understand.. In my case I am trying to retrieve all transactions from an address and it shows on etherscan but not via the API call. The odd thing is that the "From" address in one of the transactions from etherscan DID originate from the address that I am checking for. What am I missing with this? – crabulus_maximus Sep 29 '22 at 16:28