post https://polygon-mainnet-archive.allthatnode.com:8545/
Returns traces created at given block.
Note for trace_ methods
- trace_ namespace methods are only available on paid plans.
- developer plan, team plan, enterprise plan, custom plans. dedicated nodes
- trace_ namespace methods are only available on erigon client.
Parameters
hash
|quantity
|tag
- block hash, or hex encoded integer block number, or the string "latest", "earliest" or "pending", see the default block parameter.
curl https://polygon-mainnet-archive.allthatnode.com:8545/8U3JLUhzIDg3GShvy9hkCCSYkLGc11kj \
--request POST \
--header "Content-Type: application/json" \
--data '{
"jsonrpc": "2.0",
"id": 1,
"method": "trace_block",
"params": [
"0x2B9BB83"
]
}'
Returns
- An
array
ofblock trace
s: A list of calls to other contracts containing one object per call, in transaction execution order.action
- The ParityTrace object, which has the following fields:from
- The address of the sendercallType
- The type of method such as call, delegatecallgas
- The gas provided by the sender, encoded as hexadecimalinput
- The data sent along with the transactionto
- The address of the receivervalue
- The integer of the value sent with this transaction, encoded as hexadecimal
blockHash
- The hash of the block where this transaction was inblockNumber
- An integer value representing the block number where this transaction was inerror
- The error message, if anyresult
- The ParityTraceResult object which has the following fields:- gasUsed - The amount of gas used by this specific transaction alone
- output - The value returned by the contract call, and it only contains the actual value sent by the RETURN method. If the RETURN method was not executed, the output is empty bytes
subtraces
- The traces of contract calls made by the transactiontraceAddress
- The list of addresses where the call executed, the address of the parents and the order of the current sub calltransactionHash
- The hash of the transactiontransactionPosition
- The transaction positiontype
- The value of the method such as call or create
{
"jsonrpc": "2.0",
"id": 1,
"result": [
{
"action": {
"from": "0x1111111254eeb25477b68fb85ed929f73a960582",
"callType": "call",
"gas": "0x17dc3",
"input": "0xa9059cbb0000000000000000000000002887c9820624645869a37254fb20af831c5c95c0000000000000000000000000000000000000000000000000000000e8d4a51000",
"to": "0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270",
"value": "0x0"
},
"blockHash": "0x7ed725696f12503201879dda5598649a1e62776f74370042d9631444fe9930c7",
"blockNumber": 45726595,
"result": {
"gasUsed": "0x5a9b",
"output": "0x0000000000000000000000000000000000000000000000000000000000000001"
},
"subtraces": 0,
"traceAddress": [
0,
1,
2
],
"transactionHash": "0x0948a540fd0ae9fe2c3dbf2cc014c82cb989e7974e5ae78d3e282fb5e975039a",
"transactionPosition": 37,
"type": "call"
},
{
"action": {
"from": "0x2887c9820624645869a37254fb20af831c5c95c0",
"callType": "staticcall",
"gas": "0x1298f",
"input": "0x70a082310000000000000000000000002887c9820624645869a37254fb20af831c5c95c0",
"to": "0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270",
"value": "0x0"
},
"blockHash": "0x7ed725696f12503201879dda5598649a1e62776f74370042d9631444fe9930c7",
"blockNumber": 45726595,
"result": {
"gasUsed": "0x234",
"output": "0x000000000000000000000000000000000000000000000000000000e8d4a51000"
},
"subtraces": 0,
"traceAddress": [
0,
2
],
"transactionHash": "0x0948a540fd0ae9fe2c3dbf2cc014c82cb989e7974e5ae78d3e282fb5e975039a",
"transactionPosition": 37,
"type": "call"
},
{
"action": {
"from": "0x2887c9820624645869a37254fb20af831c5c95c0",
"callType": "call",
"gas": "0x115f3",
"input": "0xa9059cbb00000000000000000000000073b9eea6f7e90e19bec936bbf90eca1994b7cb76000000000000000000000000000000000000000000000000000000e8d4a51000",
"to": "0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270",
"value": "0x0"
},
"blockHash": "0x7ed725696f12503201879dda5598649a1e62776f74370042d9631444fe9930c7",
"blockNumber": 45726595,
"result": {
"gasUsed": "0x1f9f",
"output": "0x0000000000000000000000000000000000000000000000000000000000000001"
},
"subtraces": 0,
"traceAddress": [
0,
3
],
"transactionHash": "0x0948a540fd0ae9fe2c3dbf2cc014c82cb989e7974e5ae78d3e282fb5e975039a",
"transactionPosition": 37,
"type": "call"
}
]
}