3

Suppose I have a transaction hash and it belongs to some transaction which was done on a smart contract. From the hash, how do I determine what was the contract method which was called and with what parameters?

2

One easy way is to use an explorer. For example see this and click on "Invocation data" and you see that function "breakCookie" was called with the name "Roman". This requires that the author of the contract uploaded their source code, so that names can be determined from the compiled bytecode.

Another way is to look at the input field of the transaction and parse it according to the ABI. You will not have the name of the method, but will see the values of the parameters.

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.