Skip to main content
POST
/
66f812de2a6724a75a51f60dd6f2a154
debug_printBlock
curl --request POST \
  --url https://nd-954-882-037.p2pify.com/66f812de2a6724a75a51f60dd6f2a154 \
  --header 'Content-Type: application/json' \
  --data '
{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "debug_printBlock",
  "params": [
    30000000
  ]
}
'
{
  "jsonrpc": "<string>",
  "id": 123,
  "result": "<string>"
}
Arbitrum API method that returns a human-readable representation of a block. Unlike eth_getBlockByNumber which returns structured JSON, this method returns a verbose text dump of the entire block structure including all header fields, transactions, and uncles. The output format uses Go’s spew.Sdump formatting.
Learn how to deploy a node with the debug and trace API methods enabled.
This method is available for post-Nitro blocks only (block 22,207,815 and later). For pre-Nitro blocks, use the arbtrace_* methods instead.
Get you 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

  • number — the block number as a decimal integer.

Response

  • result — a human-readable string representation of the block, including all internal fields and nested structures.

debug_printBlock code examples

const ethers = require('ethers');
const NODE_URL = "YOUR_CHAINSTACK_ENDPOINT";
const provider = new ethers.JsonRpcProvider(NODE_URL);

const debugPrintBlock = async (blockNumber) => {
  const result = await provider.send("debug_printBlock", [blockNumber]);
  console.log(result);
};

debugPrintBlock(30000000);

Use case

The debug_printBlock method is useful for quick debugging when you need a comprehensive view of a block’s internal structure. The human-readable output format reveals all fields including those not typically exposed by standard RPC methods, making it valuable for diagnosing block-level issues and understanding the complete block composition.

Body

application/json
id
integer
default:1
jsonrpc
string
default:2.0
method
string
default:debug_printBlock
params
integer[]

The block number as a decimal integer.

Response

200 - application/json

Returns a human-readable representation of the block.

jsonrpc
string
id
integer
result
string
Last modified on March 13, 2026