Skip to main content
This page is a placeholder. All examples on this page are currently AI-generated and are not correct. This documentation will be completed in the future with accurate, tested examples.

Network Methods

Network information methods for detecting chain ID, checking sync status, and querying node/account state.

Overview

Methods

eth_chainId

Get the chain ID.
Returns: Chain ID as hex quantity (e.g., 0x1 for Ethereum mainnet) Usage:

eth_syncing

Get sync status (false if not syncing).
Returns:
  • false if node is fully synced
  • SyncStatus object if syncing:
    • startingBlock: Quantity - Block where sync started
    • currentBlock: Quantity - Current synced block
    • highestBlock: Quantity - Highest known block
Usage:

eth_coinbase

Get the coinbase address (miner/validator).
Returns: Address that receives mining/validation rewards Usage:
Returns null or zero address if not mining/validating

eth_accounts

List available accounts (if wallet is connected).
Returns: Array of available account addresses Usage:
Most public RPC nodes return empty array. Only works with personal/wallet connections.

Common Patterns

Network Detection

Check Node Readiness

Verify Connection

See Also