3

web3 js functions like:

getTransaction() What should be the input? contract address or account address or transaction hash?

likewise for other contracts like getTransactionReceipt and all?

1
  • It is a good practice that accepting the answer as correct if it helped you resolved the issue. That is the whole point of SE none of the answers for your questions are marked as correct. FYI, if youre not aware of it.
    – niksmac
    Dec 23, 2016 at 2:53

1 Answer 1

2

As per the docs,

web3.eth.getTransaction(transactionHash [, callback])

Returns a transaction matching the given transaction hash.

Parameters

  1. String - The transaction hash.
  2. Function - (optional) If you pass a callback the HTTP request is made asynchronous. See this note for details.

web3.ETH.sendTransaction will return The 32 Bytes transaction hash as HEX string.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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