Skip to main content

Trace methods

Infura provides access to the following trace API methods to allow users to gain insights into the execution of smart contracts and transactions:

info
  • Trace API is currently an open beta feature, available to paying Infura customers.
  • trace_block and trace_transaction returns trace diagnostic information.

trace

Provides an ordered trace of the instructions executed by the Ethereum Virtual Machine (EVM) during the execution of a smart contract transaction. Excludes precompiled contracts.

Trace example
"trace":[
{
"action":{
"callType":"call",
"from":"0xfe3b557e8fb62b89f4916b721be55ceb828dbd73",
"gas":"0xffadea",
"input":"0x",
"to":"0x0100000000000000000000000000000000000000",
"value":"0x0"
},
"result":{
"gasUsed":"0x1e",
"output":"0x"
},
"subtraces":0,
"traceAddress":[
],
"type":"call"
}
]
KeyValue
actionTransaction details.
callTypeWhether the transaction is call or create.
fromAddress of the transaction sender.
gasGas provided by sender.
inputTransaction data.
toTarget of the transaction.
valueValue transferred in the transaction.
resultTransaction result.
gasUsedGas used by the transaction. Includes any refunds of unused gas.
outputReturn value of the contract call. Contains only the actual value sent by a RETURN operation. If a RETURN was not executed, the output is empty bytes.
subTracesTraces of contract calls made by the transaction.
traceAddressTree list address of where the call occurred, address of the parents, and order of the current sub call.
transactionHashHash of the transaction.
transactionPositionTransaction position.
typeWhether the transaction is a CALL or CREATE series operation.