mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
1.2 KiB
1.2 KiB
JSON-RPC Namespaces
Reth supports all standard Ethereum JSON-RPC API methods. The API methods are grouped into namespaces, which are listed below:
- admin: Administrative APIs for the node. DO NOT expose these APIs to the public internet.
- eth: Ethereum APIs for interacting with the Ethereum blockchain.
- tracing: APIs for tracing the execution of transactions, compatible with the popular Parity Tracing module.
- debug: APIs for debugging the node, originally created by Geth.
One can easily interact with these APIs just like they would with any Ethereum client. You can use curl, a programming language with a low-level library, or a tool like Foundry to interact with the chain at the exposed HTTP or WS port. As a reminder, you need to run the command below to enable all of these apis:
RUST_LOG=info reth node --http --http.api "eth,admin,debug,tracing"
The IPC transport is also supported with
--ipc!
This allows you to then call:
cast block-number
cast rpc admin_nodeInfo
cast rpc debug_traceTransaction
cast rpc trace_replayBlockTransactions