debug_traceBlockByHash

Retrieves detailed execution information about transactions within a given block hash.

Parameters

  1. Blockhash - the hash of the block to be traced.

  2. Tracer - choose from one of these options:

    • 4byteTracer - Solidity contract functions are addressed using the first four byte of the Keccak-256 hash of their signature. This tracer monitors and analyzes the usage of specific function signatures within smart contracts by capturing their unique first four bytes.

    • callTracer - collects data about all call frames executed within a transaction, creating a hierarchical list of call frames structured mirroring the EVM's operations. This is useful for debugging and analytical purposes.

    • prestateTracer - captures and analyzes the state of the blockchain before the execution of a specific transaction. It helps in understanding the state changes and effects that a transaction will have on the blockchain's data and accounts before the transaction is actually executed.

    • noopTracer - returns empty results. This is used for testing purpose.

    • opcountTracer - count and track the number of operations (or opcodes) executed during a specific transaction.

    • unigramTracer - counts the frequency of occurrence of each opcode.

    • bigramTracer - a bigram refers to a sequence of two bytes or characters. This tracer is designed to observe and provide insights into the patterns and occurrences of these two-byte sequences as they appear within the data of executed transactions.

    • trigramTracer - a trigram refers to a sequence of three bytes or characters. This tracer is designed to observe and provide insights into the patterns and occurrences of these three-byte sequences as they appear within the data of executed transactions.

    • evmdisTracer - generates the bytecode disassembly of executed transactions, providing developers with insights into how smart contracts operate at a low-level bytecode level for debugging, security audits, and performance optimization purposes.

Sample Request

curl https://lb.nodies.app/v1/<INSERT URL> \
   -H "x-api-key: <API-KEY>" \
   -X POST \
   -H "Content-Type: application/json" \
   -d '{ 
  "method": "debug_traceBlockByHash",
  "params": [
    "0x656fcfdec6065b932607243d2fab1e80963454f7e058af1238a0f8aa62598ad8",
    {
      "tracer": "callTracer"
    }
  ],
  "id": 1,
  "jsonrpc": "2.0"
}'

Sample Response

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": [
    {
      "result": {
        "calls": [
          {
            "calls": [
              {
                "from": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
                "gas": "0x300c",
                "gasUsed": "0x0",
                "input": "0x",
                "output": "0x",
                "to": "0xa5650ec938eda846e1ee3518f75a457382af5202",
                "type": "CALL",
                "value": "0xf8b0a10e470000"
              },
              {
                "calls": [
                  {
                    "from": "0x38de71124f7a447a01d67945a51edce9ff491251",
                    "gas": "0xfea08",
                    "gasUsed": "0x13fe",
                    "input": "0xb71e0f71c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca066000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000094000000000000000000000000042b8289c97896529ec2fe49ba1a8b9c956a86cc00000000000002d400a56dd28c2c5b91dd63b4d4e78ecac713987837176800b104866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
                    "output": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000a500000000000000000000000000000000000000000000000000000000000000b100000000000000000000000000000000000000000000000000000000000002d400000000000000000000000004866796aabb6b58e6bc4d91a2ae99105b2c58ae00000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000042b8289c97896529ec2fe49ba1a8b9c956a86cc000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000146dd28c2c5b91dd63b4d4e78ecac71398783717680000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000",
                    "to": "0xc1b15d3b262beec0e3565c11c9e0f6134bdacb36",
                    "type": "CALL",
                    "value": "0x0"
                  },
                  {
                    "calls": [
                      {
                        "calls": [
                          {
                            "error": "execution reverted",
                            "from": "0x04866796aabb6b58e6bc4d91a2ae99105b2c58ae",
                            "gas": "0x39ab2",
                            "gasUsed": "0x613",
                            "input": "0x66ad5c8a00000000000000000000000000000000000000000000000000000000000000a5000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000002d400000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000000286dd28c2c5b91dd63b4d4e78ecac713987837176804866796aabb6b58e6bc4d91a2ae99105b2c58ae0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000",
                            "to": "0x04866796aabb6b58e6bc4d91a2ae99105b2c58ae",
                            "type": "CALL",
                            "value": "0x0"
                          }
                        ],
                        "from": "0xb6319cc6c8c27a8f5daf0dd3df91ea35c4720dd7",
                        "gas": "0x3d090",
                        "gasUsed": "0x9a15",
                        "input": "0x001d356700000000000000000000000000000000000000000000000000000000000000a5000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000002d400000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000000286dd28c2c5b91dd63b4d4e78ecac713987837176804866796aabb6b58e6bc4d91a2ae99105b2c58ae0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000",
                        "output": "0x",
                        "to": "0x04866796aabb6b58e6bc4d91a2ae99105b2c58ae",
                        "type": "CALL",
                        "value": "0x0"
                      }
                    ],
                    "from": "0x38de71124f7a447a01d67945a51edce9ff491251",
                    "gas": "0xf9e70",
                    "gasUsed": "0xe3d0",
                    "input": "0xc2fa481300000000000000000000000000000000000000000000000000000000000000a500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000004866796aabb6b58e6bc4d91a2ae99105b2c58ae00000000000000000000000000000000000000000000000000000000000002d4000000000000000000000000000000000000000000000000000000000003d090000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000286dd28c2c5b91dd63b4d4e78ecac713987837176804866796aabb6b58e6bc4d91a2ae99105b2c58ae0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000",
                    "output": "0x",
                    "to": "0xb6319cc6c8c27a8f5daf0dd3df91ea35c4720dd7",
                    "type": "CALL",
                    "value": "0x0"
                  }
                ],
                "from": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
                "gas": "0x107ca0",
                "gasUsed": "0x182c8",
                "input": "0x987fa2d500000000000000000000000000000000000000000000000000000000000000a500000000000000000000000004866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000000000000000000000000000000000000003d090c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca066c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca06600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000094000000000000000000000000042b8289c97896529ec2fe49ba1a8b9c956a86cc00000000000002d400a56dd28c2c5b91dd63b4d4e78ecac713987837176800b104866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
                "output": "0x",
                "to": "0x38de71124f7a447a01d67945a51edce9ff491251",
                "type": "CALL",
                "value": "0x0"
              }
            ],
            "from": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
            "gas": "0x118303",
            "gasUsed": "0x246d1",
            "input": "0x0508941e00000000000000000000000000000000000000000000000000000000000000a500000000000000000000000004866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000000000000000000000000000000000000003d090c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca066c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca06600000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000094000000000000000000000000042b8289c97896529ec2fe49ba1a8b9c956a86cc00000000000002d400a56dd28c2c5b91dd63b4d4e78ecac713987837176800b104866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
            "output": "0x",
            "to": "0xacbd57daaafb7d9798992a7b0382fc67d3e316f3",
            "type": "DELEGATECALL"
          }
        ],
        "from": "0xe93685f3bba03016f02bd1828badd6195988d950",
        "gas": "0x11de14",
        "gasUsed": "0x25ae0",
        "input": "0x0508941e00000000000000000000000000000000000000000000000000000000000000a500000000000000000000000004866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000000000000000000000000000000000000003d090c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca066c7035aad2e0c8cdc3c0e7911c7b1cda5d672a8c06c6551606349c5475e0ca06600000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000094000000000000000000000000042b8289c97896529ec2fe49ba1a8b9c956a86cc00000000000002d400a56dd28c2c5b91dd63b4d4e78ecac713987837176800b104866796aabb6b58e6bc4d91a2ae99105b2c58ae000000000000000000000000a5650ec938eda846e1ee3518f75a457382af52020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
        "output": "0x",
        "to": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
        "type": "CALL",
        "value": "0xf8b0a10e470000"
      }
    },
    {
      "result": {
        "calls": [
          {
            "calls": [
              {
                "calls": [
                  {
                    "from": "0x38de71124f7a447a01d67945a51edce9ff491251",
                    "gas": "0x80b7f",
                    "gasUsed": "0x1554",
                    "input": "0xb71e0f719add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c0000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000d40000000000000000000000004d73adb72bc3dd368966edd0f0b2148401a178e2000000000000319b006a2f6f07cdcf3588944bf4c42ac74ff24bf56e759000b183c30eb8bc9ad7c56532895840039e62659896ea00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000000000000000000000000000",
                    "output": "0x0000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006a00000000000000000000000000000000000000000000000000000000000000b1000000000000000000000000000000000000000000000000000000000000319b00000000000000000000000083c30eb8bc9ad7c56532895840039e62659896ea00000000000000000000000000000000000000000000000000000000000000e00000000000000000000000004d73adb72bc3dd368966edd0f0b2148401a178e2000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000142f6f07cdcf3588944bf4c42ac74ff24bf56e7590000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000",
                    "to": "0xc1b15d3b262beec0e3565c11c9e0f6134bdacb36",
                    "type": "CALL",
                    "value": "0x0"
                  },
                  {
                    "calls": [
                      {
                        "from": "0xb6319cc6c8c27a8f5daf0dd3df91ea35c4720dd7",
                        "gas": "0x14c08",
                        "gasUsed": "0xa381",
                        "input": "0x001d3567000000000000000000000000000000000000000000000000000000000000006a0000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000319b00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000000282f6f07cdcf3588944bf4c42ac74ff24bf56e759083c30eb8bc9ad7c56532895840039e62659896ea000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000",
                        "output": "0x",
                        "to": "0x83c30eb8bc9ad7c56532895840039e62659896ea",
                        "type": "CALL",
                        "value": "0x0"
                      }
                    ],
                    "from": "0x38de71124f7a447a01d67945a51edce9ff491251",
                    "gas": "0x7bd6f",
                    "gasUsed": "0xed48",
                    "input": "0xc2fa4813000000000000000000000000000000000000000000000000000000000000006a00000000000000000000000000000000000000000000000000000000000000c000000000000000000000000083c30eb8bc9ad7c56532895840039e62659896ea000000000000000000000000000000000000000000000000000000000000319b0000000000000000000000000000000000000000000000000000000000014c08000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000282f6f07cdcf3588944bf4c42ac74ff24bf56e759083c30eb8bc9ad7c56532895840039e62659896ea000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000",
                    "output": "0x",
                    "to": "0xb6319cc6c8c27a8f5daf0dd3df91ea35c4720dd7",
                    "type": "CALL",
                    "value": "0x0"
                  }
                ],
                "from": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
                "gas": "0x87e29",
                "gasUsed": "0x18ece",
                "input": "0x987fa2d5000000000000000000000000000000000000000000000000000000000000006a00000000000000000000000083c30eb8bc9ad7c56532895840039e62659896ea0000000000000000000000000000000000000000000000000000000000014c089add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c9add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c00000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000d40000000000000000000000004d73adb72bc3dd368966edd0f0b2148401a178e2000000000000319b006a2f6f07cdcf3588944bf4c42ac74ff24bf56e759000b183c30eb8bc9ad7c56532895840039e62659896ea00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000000000000000000000000000",
                "output": "0x",
                "to": "0x38de71124f7a447a01d67945a51edce9ff491251",
                "type": "CALL",
                "value": "0x0"
              }
            ],
            "from": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
            "gas": "0x8dd54",
            "gasUsed": "0x1cc17",
            "input": "0x252f7b01000000000000000000000000000000000000000000000000000000000000006a00000000000000000000000083c30eb8bc9ad7c56532895840039e62659896ea0000000000000000000000000000000000000000000000000000000000014c089add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c9add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c00000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000d40000000000000000000000004d73adb72bc3dd368966edd0f0b2148401a178e2000000000000319b006a2f6f07cdcf3588944bf4c42ac74ff24bf56e759000b183c30eb8bc9ad7c56532895840039e62659896ea00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000000000000000000000000000",
            "output": "0x",
            "to": "0xacbd57daaafb7d9798992a7b0382fc67d3e316f3",
            "type": "DELEGATECALL"
          }
        ],
        "from": "0xe93685f3bba03016f02bd1828badd6195988d950",
        "gas": "0x91548",
        "gasUsed": "0x1e02c",
        "input": "0x252f7b01000000000000000000000000000000000000000000000000000000000000006a00000000000000000000000083c30eb8bc9ad7c56532895840039e62659896ea0000000000000000000000000000000000000000000000000000000000014c089add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c9add5a02519d1e0f5d8005cf3cc349e15fc403612c66a4835f2e814173c8437c00000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000d40000000000000000000000004d73adb72bc3dd368966edd0f0b2148401a178e2000000000000319b006a2f6f07cdcf3588944bf4c42ac74ff24bf56e759000b183c30eb8bc9ad7c56532895840039e62659896ea00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000032cdc63449c0000000000000000000000000000000000000000000000000000000000000000014e1093de92181b70515f0e977f48728bfc9e42a40000000000000000000000000000000000000000000000000",
        "output": "0x",
        "to": "0xcb566e3b6934fa77258d68ea18e931fa75e1aaaa",
        "type": "CALL",
        "value": "0x0"
      }
    }
  ]
}

Last updated