Docs

starknet_getTransactionReceipt - Get Transaction Receipt

Get the execution receipt for a Starknet transaction by hash. Returns status, fees, events, and execution details for transaction verification and monitoring.

Returns the receipt of a transaction identified by its hash. The receipt includes execution status, actual fee paid, emitted events, and block inclusion details. This is the primary method for confirming whether a transaction succeeded or reverted.

Overview

After a transaction is submitted to Starknet, it goes through several stages: RECEIVED, ACCEPTED_ON_L2, and finally ACCEPTED_ON_L1 (once the proof is verified on Ethereum). The transaction receipt reflects the current status and provides detailed execution results.

Starknet transaction receipts differ from EVM receipts in several ways:

  • Fees are denominated in STRK or ETH (depending on the fee token used)
  • Events use felt252 keys and data values (Cairo's native field element type)
  • Execution status distinguishes between SUCCEEDED and REVERTED
  • L2-to-L1 messages emitted during execution are tracked in messages_sent
  • execution_resources reports fee-relevant buckets such as l1_gas, l2_gas, and l1_data_gas

Errors

CodeMessageDescription
29Transaction hash not foundThe transaction does not exist or has not been processed yet

Examples

Use Cases

  • Transaction Confirmation - Verify that a submitted transaction was executed successfully
  • Fee Tracking - Record actual fees paid for cost analysis and accounting
  • Event Monitoring - Extract emitted events for token transfers, contract state changes, and DeFi activity
  • Error Debugging - Inspect revert reasons for failed transactions
  • L1 Finality Tracking - Monitor when transactions achieve ACCEPTED_ON_L1 finality via Ethereum proof verification
  • Payment Verification - Confirm token transfer completion for payment processing systems