Skip to main content

Overview

The eth namespace provides Ethereum-compatible methods for querying blockchain data, managing accounts, and submitting transactions.

Blockchain Queries

eth_blockNumber

Returns the number of the most recent block.
curl -X POST -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}' \
  https://rpc.viction.xyz
result
string
The current block number as a hexadecimal string
Example Response:
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0x4b7"
}

eth_getBlockByNumber

Returns information about a block by block number.
curl -X POST -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["0x4b7",true],"id":1}' \
  https://rpc.viction.xyz
params[0]
string
required
Block number (hex) or “latest”, “earliest”, “pending”
params[1]
boolean
required
If true, returns full transaction objects; if false, returns only transaction hashes
result
object
Block object or null if block not found

eth_getBlockByHash

Returns information about a block by block hash.
params[0]
string
required
32-byte block hash
params[1]
boolean
required
If true, returns full transaction objects; if false, returns only transaction hashes

eth_getBalance

Returns the balance of an account at a given block.
curl -X POST -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_getBalance","params":["0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb","latest"],"id":1}' \
  https://rpc.viction.xyz
params[0]
string
required
20-byte account address
params[1]
string
required
Block number (hex) or “latest”, “earliest”, “pending”
result
string
Balance in wei (hex)

eth_getStorageAt

Returns the value from a storage position at a given address.
params[0]
string
required
20-byte account address
params[1]
string
required
Storage position (hex)
params[2]
string
required
Block number (hex) or “latest”, “earliest”, “pending”

eth_getCode

Returns code at a given address.
params[0]
string
required
20-byte account address
params[1]
string
required
Block number (hex) or “latest”, “earliest”, “pending”
result
string
Contract bytecode (hex) or “0x” if account has no code

Transactions

eth_getTransactionCount

Returns the number of transactions sent from an address (nonce).
curl -X POST -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_getTransactionCount","params":["0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb","latest"],"id":1}' \
  https://rpc.viction.xyz
params[0]
string
required
20-byte account address
params[1]
string
required
Block number (hex) or “latest”, “earliest”, “pending”
result
string
Transaction count (hex)

eth_getTransactionByHash

Returns information about a transaction by transaction hash.
params[0]
string
required
32-byte transaction hash
result
object
Transaction object or null if not found

eth_getTransactionReceipt

Returns the receipt of a transaction by transaction hash.
params[0]
string
required
32-byte transaction hash
result
object
Receipt object or null if not found

eth_sendRawTransaction

Submits a signed transaction to the network.
curl -X POST -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_sendRawTransaction","params":["0xf86c..."],"id":1}' \
  https://rpc.viction.xyz
params[0]
string
required
Signed transaction data (hex)
result
string
32-byte transaction hash

Call and Estimation

eth_call

Executes a new message call immediately without creating a transaction.
params[0]
object
required
Transaction call object
params[1]
string
required
Block number (hex) or “latest”, “earliest”, “pending”
result
string
Return value of executed contract (hex)

eth_estimateGas

Generates and returns an estimate of gas needed to complete the transaction.
params[0]
object
required
Transaction call object (same as eth_call)
result
string
Estimated gas amount (hex)

Network and Protocol

eth_chainId

Returns the chain ID of the network.
curl -X POST -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1}' \
  https://rpc.viction.xyz
result
string
Chain ID (hex): “0x58” for mainnet, “0x59” for testnet

eth_syncing

Returns an object with sync status data or false.
result
object|boolean
Sync status object or false if not syncing

eth_gasPrice

Returns the current gas price in wei.
result
string
Gas price in wei (hex)

eth_protocolVersion

Returns the current Ethereum protocol version.
result
string
Protocol version (hex)

Viction-Specific Methods

eth_getOwnerByCoinbase

Returns the masternode owner address for a given coinbase address.
params[0]
string
required
Coinbase address
params[1]
string
required
Block number (hex) or “latest”
result
string
Owner address

eth_getRewardByHash

Returns the reward information for a block by hash.
params[0]
string
required
Block hash
result
object
Reward details organized by type and recipient

Build docs developers (and LLMs) love