Acting on a prepared transaction
Transactions have a variety of actions that can be called on them, in all cases this is done by passing the transaction to the various action functions.
Sending a transaction
Send the prepared transaction to the blockchain. Sending a transaction requires a wallet.
See Wallets for more information on how to create a wallet.
sendAndConfirmTransaction
Send a transaction and wait for it to be mined. Useful when you want to block until the transaction is fully confirmed onchain before proceeding to the next step.
waitForReceipt
Wait for a transaction to be mined and get the transaction receipt.
estimateGas
Estimating gas used by a transaction
estimateGasCost
Estimating gas cost in ether and wei for a transaction
simulateTransaction
Simulate a transaction to see if it would be successful.
encode
Encode a transaction data to be used later