Documentation ¶
Overview ¶
Package rpc contains RPC handler methods, namespaces and utilities to start Ethermint's Web3-compatible JSON-RPC server.
The list of available namespaces are:
* `rpc/namespaces/eth`: `eth` namespace. Exposes the `PublicEthereumAPI` and the `PublicFilterAPI`. * `rpc/namespaces/personal`: `personal` namespace. Exposes the `PrivateAccountAPI`. * `rpc/namespaces/net`: `net` namespace. Exposes the `PublicNetAPI`. * `rpc/namespaces/web3`: `web3` namespace. Exposes the `PublicWeb3API`
Index ¶
Constants ¶
const ( Web3Namespace = "web3" EthNamespace = "eth" PersonalNamespace = "personal" NetNamespace = "net" TxpoolNamespace = "txpool" )
RPC namespaces and API version
const ( FlagPersonalAPI = "personal-api" FlagRateLimitAPI = "rpc.rate-limit-api" FlagRateLimitCount = "rpc.rate-limit-count" FlagRateLimitBurst = "rpc.rate-limit-burst" FlagEnableMonitor = "rpc.enable-monitor" FlagDisableAPI = "rpc.disable-api" FlagKafkaAddr = "pendingtx.kafka-addr" FlagKafkaTopic = "pendingtx.kafka-topic" MetricsNamespace = "x" // MetricsSubsystem is a subsystem shared by all metrics exposed by this package. MetricsSubsystem = "rpc" MetricsFieldName = "Metrics" )
Variables ¶
This section is empty.
Functions ¶
func CloseEthBackend ¶ added in v0.19.9
func CloseEthBackend()
func GetAPIs ¶
func GetAPIs(clientCtx context.CLIContext, log log.Logger, keys ...ethsecp256k1.PrivKey) []rpc.API
GetAPIs returns the list of all APIs from the Ethereum namespaces
func RegisterRoutes ¶
func RegisterRoutes(rs *lcd.RestServer)
RegisterRoutes creates a new server and registers the `/rpc` endpoint. Rpc calls are enabled based on their associated module (eg. "eth").
Types ¶
This section is empty.