Replays all transactions that were included in this block by block hash.
Supported on Polygon zkEVM (mainnet) only.
Parameters
blockHash
[REQUIRED] - The block hashtracer
[REQUIRED] - The tracer type. Please refer to Geth implementation for more tracer type.
Returns
This returns based on callTracer. Please refer to Geth implementation for more return data fields.
Object
- Full trace of the block.result
- Trace Object, which has the following fields:from
- The address the transaction is sent fromto
- The address the transaction is directed togas
- The gas provided for the transaction executiongasUsed
- The gasPrice used for each paid gasinput
- The data sent along with the transactionoutput
- The output datatype
- Type of the transactionvalue
- The value transferred in Wei, encoded as a hexadecimal
API Endpoint
The format of a polygon-zkevm-rpc endpoint is
https://open-platform.nodereal.io/{{apiKey}}/polygon-zkevm-rpc/
Here is an example:
https://open-platform.nodereal.io/4c0a1c23661a4e26bcbcwed461e34ea9/polygon-zkevm-rpc/
Example
Request
curl https://open-platform.nodereal.io/{{apiKey}}/polygon-zkevm-rpc/ \
-X POST \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"debug_traceBlockByHash","params":["0xcb1e9e529fddcfdad8c4d43eabf8264d55d13305105cf760dfdae166ddc42046", {"tracer": "callTracer"}],"id": 0 }'
Result