Comment on page
Returns the receipt of a transaction by transaction hash.
eth_getTransactionReceiptcommand is used to return the receipt of a transaction by its transaction hash.
Use cases of
- Track the status of a transaction
- Obtain the contract address for a contract creation TX
Transaction receipts are not available for any pending transactions. Note that
eth_getTransactionReceiptreturns null for all unknown or pending transactions.
Note: the receipt is not available for pending transactions.
DATA, 32 Bytes - hash of transaction
Object- A transaction receipt object, or null when no receipt was found:
DATA, 32 Bytes - hash of the transaction.
QUANTITY- integer of the transactions index position in the block.
DATA, 32 Bytes - hash of the block where this transaction was in.
QUANTITY- block number where this transaction was in.
DATA, 20 Bytes - address of the sender.
DATA, 20 Bytes - address of the receiver. null when its a contract creation transaction.
QUANTITY- The total amount of gas used when this transaction was executed in the block.
QUANTITY- The amount of gas used by this specific transaction alone.
DATA, 20 Bytes - The contract address created, if the transaction was a contract creation, otherwise null.
Array- Array of log objects, which this transaction generated.
DATA, 256 Bytes - Bloom filter for light clients to quickly retrieve related logs.
It also returns either:
DATA32 bytes of post-transaction stateroot (pre Byzantium)
QUANTITYeither 1 (success) or 0 (failure)
curl https://eth-mainnet.blastapi.io/<project-id> \
-X POST \
-H "Content-Type: application/json" \
transactionIndex: '0x1', // 1
blockNumber: '0xb', // 11
cumulativeGasUsed: '0x33bc', // 13244
gasUsed: '0x4dc', // 1244
contractAddress: '0xb60e8dd61c5d32be8058bb8eb970870f07233155', // or null, if none was created
// logs as returned by getFilterLogs, etc.
logsBloom: "0x00...0", // 256 byte bloom filter