I am trying to deploy a "verifyTx(tx_hash){}" function that takes a hash and tells me the state (succ vs. fail vs. pending), but I was hoping to get more advanced information on the hash if possible:
- Can I check what type of transaction was called? e.g. a mint, a burn, a transfer etc.? Is there any way to query the name of the function from the transaction receipt log?
- Is there any way to catch the scenario where the user speeds up a transaction on the network? Is there any reference that the new TX (hash) replaced this (hash)? I am seemingly failing to understand why these don't show as dropped/replaced and the overriding hash shows no indication that it was not the original (this seems like an oversight) - am I missing some way to track this? Note, I am well aware of Events but due to the live nature of our dapp I am hoping to log these to a ledger and query using crons to validate some web2 components along with the transaction and the more information I can gather about the transaction, the better.
Notes:
- I'm using an Infura endpoint, and technically I'm working specifically with Polygon for this use case. (polygonscan as the blockchain explorer)
- I am aware of transaction receipts and logs, but this still seems limited (where does Etherscan for example pull all of its rich metadata?)