# Debug and trace APIs

A dedicated Fantom node has the debug_* API methods enabled. For the full list of the available debug and trace API methods, see Debug namespace (opens new window).

# Usage examples

You can debug and trace transactions on Fantom by replaying them in the Ethereum Virtual Machine to get the execution details in the exact same way as they happened on the chain.

# debug_traceBlockByNumber

Trace all transactions included in a block with debug_traceBlockByNumber:

curl -H "Content-Type: application/json" -d '{"id": 1, "method": "debug_traceBlockByNumber", "params": ["BLOCK_NUMBER", {"tracer": "callTracer"}]}' ENDPOINT


  • BLOCK_NUMBER — the number of the block to get the traces of included transactions.
  • ENDPOINT — your node HTTPS endpoint.

See View node access and credentials.

For example, trace all smart contract interactions in block 43013027:

curl -H "Content-Type: application/json" -d '{"id": 1, "method": "debug_traceBlockByNumber", "params": ["0x29053A3", {"tracer": "callTracer"}]}' https://nd-123-456-789.p2pify.com/3c6e0b8a9c15224a8228b9a98ca1531d