Ethereum
¿Listo para usar esto en producción?
El plan gratuito cubre proyectos personales. El pago por uso escala sin necesidad de tarjeta.
Ethereum
El plan gratuito cubre proyectos personales. El pago por uso escala sin necesidad de tarjeta.
debug_traceBlock is the raw-bytes variant of block tracing on Ethereum mainnet (chain ID 1, native coin ETH). Instead of naming a block by hash or number, you hand the node the block itself as RLP-encoded bytes; it decodes them, re-runs every transaction against the parent state, and returns an opcode-level trace for each one in block order. This is the method to reach for when you already hold the serialized block — say, captured off the devp2p wire — rather than asking the node to look one up. Requests go to https://ethereum.therpc.io/YOUR_API_KEY. Like its siblings, it replays the whole block through the EVM, so a debug-enabled archive node is needed for the parent state of older blocks.
| # | Nombre | Tipo | Requerido | Descripción |
|---|---|---|---|---|
| 1 | rlpBlock | string | Sí | RLP-encoded block data. The block must be a valid, known block; the node re-executes it against the parent state. |
| 2 | options | object | No | Same tracer configuration object as debug_traceTransaction. |
| Tipo | Descripción |
|---|---|
| array | Array of per-transaction trace results in block order, identical in shape to debug_traceBlockByHash output. |
Try it live in the Ethereum playground.
| Código | Mensaje | Causa |
|---|---|---|
-32601 | Method not found | debug namespace not enabled on the node. |
-32602 | Invalid params | RLP data is malformed, empty, or does not decode to a valid block structure. |
-32000 | block not found | Parent state for the provided block is not available (archive state missing). |
eth_getBlockByHash with full transactions, then re-encode header and body to RLP — get a single field wrong and the node throws -32602.block not found even though your RLP decodes fine.debug_traceBlockByHash exactly — both replay every transaction in the block, so a busy mainnet block is just as heavy whichever entry point you use.Parámetros
0x-prefixed RLP-encoded block
Same tracer configuration object as debug_traceTransaction.