TevmJsonRpcRequestHandler
TevmJsonRpcRequestHandler: <
TRequest
>(request
) =>Promise
<JsonRpcReturnTypeFromMethod
<TRequest
["method"
]>>
Typesafe request handler for JSON-RPC requests. Most users will want to use the higher level
and more feature-rich actions
api
Example
tevm_* methods
tevm_call
request - CallJsonRpcRequest response - CallJsonRpcResponse
tevm_script
request - ScriptJsonRpcRequest response - ScriptJsonRpcResponse
tevm_getAccount
request - GetAccountJsonRpcRequest response - GetAccountJsonRpcResponse
tevm_setAccount
request - SetAccountJsonRpcRequest response - SetAccountJsonRpcResponse
debug_* methods
debug_traceCall
request - DebugTraceCallJsonRpcRequest response - DebugTraceCallJsonRpcResponse
eth_* methods
eth_blockNumber
request - EthBlockNumberJsonRpcRequest response - EthBlockNumberJsonRpcResponse
eth_chainId
request - EthChainIdJsonRpcRequest response - EthChainIdJsonRpcResponse
eth_getCode
request - EthGetCodeJsonRpcRequest response - EthGetCodeJsonRpcResponse
eth_getStorageAt
request - EthGetStorageAtJsonRpcRequest response - EthGetStorageAtJsonRpcResponse
eth_gasPrice
request - EthGasPriceJsonRpcRequest response - EthGasPriceJsonRpcResponse
eth_getBalance
request - EthGetBalanceJsonRpcRequest response - EthGetBalanceJsonRpcResponse
Type parameters
• TRequest extends TevmJsonRpcRequest
| EthJsonRpcRequest
| AnvilJsonRpcRequest
| DebugJsonRpcRequest
Parameters
• request: TRequest
Returns
Promise
<JsonRpcReturnTypeFromMethod
<TRequest
["method"
]>>
Source
procedures/src/tevm-request-handler/TevmJsonRpcRequestHandler.ts:95