Skip to main content

Overview

Receipt is a branded type containing the results and metadata from executing a transaction on Ethereum. Receipts include gas usage, logs, status, and contract addresses.

Type Definition

Creating Receipts

from

Create receipt from fields.
Validation: All required fields must be provided. logsBloom must be 256 bytes.

Receipt Fields

Transaction Identifiers

  • transactionHash: Transaction hash
  • transactionIndex: Position in block (0-based)
  • blockHash: Block hash
  • blockNumber: Block height

Addresses

  • from: Sender address
  • to: Recipient address (null for contract creation)
  • contractAddress: Deployed contract address (null for non-creation)

Gas Usage

  • gasUsed: Gas consumed by this transaction
  • cumulativeGasUsed: Total gas used in block up to this transaction
  • effectiveGasPrice: Actual gas price paid (wei per gas)

Execution Results

  • status: Execution status (pending, success, failed)
  • logs: Event logs emitted
  • logsBloom: Bloom filter for log topics (256 bytes)

Transaction Type

  • type: Transaction type
    • "legacy" - Pre-EIP-2930
    • "eip2930" - Access list transactions
    • "eip1559" - Fee market transactions
    • "eip4844" - Blob transactions
    • "eip7702" - Account abstraction

EIP-4844 (Blob Transactions)

  • blobGasUsed: Gas used for blobs (optional)
  • blobGasPrice: Price per blob gas (optional)

Common Patterns

Contract Creation

Processing Logs

Gas Analysis

Status Checking

EIP-4844 Blob Transactions

Type Alias

TransactionReceiptType - Alias for ReceiptType.

Errors

InvalidReceiptError: Missing required field or invalid value.

See Also