Standard JSON RPC Requirements
- Archive node with JSON RPC interface should strictly follow input/output interface described in https://ethereum.github.io/execution-apis/api-documentation/
- WebSocket interface (optional/highly recommended to enable) is used to subscribe to new block heads. Otherwise, Blockscout will trigger new blocks fetching by periodical polling the JSON RPC
eth_blockNumbermethod. - Support for the following standard Ethereum JSON RPC methods (documented at https://ethereum.github.io/execution-apis/api-documentation/)
eth_blockNumbereth_calleth_getBalanceeth_getCodeeth_getBlockByHasheth_getBlockByNumbereth_getTransactionByHasheth_getTransactionByBlockHashAndIndexeth_getTransactionByBlockNumberAndIndexeth_getTransactionReceipteth_getUncleByBlockHashAndIndexeth_getLogs
Fetching Pending Transactions
Note pending transactions must be supported by the RPC node to enable this functionality with BlockscoutEnable Tracing to Fetch Internal Transactions
JSON RPC Performance Benchmarks
Time measures for response time of crucial JSON RPC methods for indexing in Blockscout. Ways to improve speed.eth_getBlockByNumberwithout transaction receipts for a block with 15 transactions: Desired response time is < 0.5s. For instance, in case of the Gnosis chain archive node, the response time for the block with ~20 transactions is ~0.4s.eth_getTransactionReceiptfor random transactions desired response time is < 0.5s. For the Gnosis chain archive node the response time is ~0.3 - 0.4s.- Batched
eth_getTransactionReceiptfor 15 transactions acceptable response time is Less than 1s. For the Gnosis chain archive node, it is ~0.6 - 0.7s
Rate Limit
The desired rate limit for RPC endpoint is 200 req/sec for the indexing phase and 100 req/sec for the indexed chain.EVM Requirements & Clients
- All EVM chains must define these variables during configuration.
- BlockScout currently supports Erigon, Geth, Nethermind, Hyperledger Besu, and Anvil clients. Define the node variant using the
ETHEREUM_JSONRPC_VARIANTenvironment variable. More information
L2 -> L1 JSON RPC Methods
- Find information on JSON RPC method use with different L2 types.