ots_traceTransaction
JSON-RPC method returns the complete execution trace of a transaction on the Hyperliquid EVM blockchain. This Otterscan-specific method extracts all variations of calls, contract creations, and self-destructs, presenting them as a detailed call tree that reveals the full execution flow.
Get your own node endpoint todayStart for free and get your app to production levels immediately. No credit card required.You can sign up with your GitHub, X, Google, or Microsoft account.
Parameters
- transaction hash (string, required): The hash of the transaction to trace
Response
The method returns an array of trace entries representing the complete execution tree, or null if the transaction doesn’t exist.Response structure
Each trace entry contains:type
— the type of operation (CALL
,CREATE
,CREATE2
,SELFDESTRUCT
)depth
— the depth in the call stackfrom
— the address initiating the operationto
— the target address (for calls) or created contract addressvalue
— the amount of ETH transferred (in wei, hex)input
— the input data for the operationoutput
— the output data from the operation (optional)
Usage example
Shell
Example response
Trace types
CALL
— Regular function call to a contractDELEGATECALL
— Delegate call preserving msg.senderSTATICCALL
— Read-only call that cannot modify stateCREATE
— Contract deployment using CREATE opcodeCREATE2
— Contract deployment using CREATE2 opcodeSELFDESTRUCT
— Contract self-destruction
Use cases
Theots_traceTransaction
method is essential for:
- Transaction debugging: Understand the complete execution flow of complex transactions
- DeFi analysis: Trace token swaps through multiple DEX routers
- Security auditing: Identify unexpected contract interactions
- Gas optimization: Find expensive operations in the call tree
- MEV analysis: Study arbitrage bot strategies and execution paths
- Contract testing: Verify expected call patterns in integration tests
- Forensic investigation: Analyze exploit transactions step by step
- Performance profiling: Identify bottlenecks in contract interactions
- Educational tools: Visualize how smart contracts interact
- Block explorers: Display detailed transaction execution trees
Body
application/json