JSON-RPC
Armchain exposes a standard Ethereum-compatible JSON-RPC API over HTTP and WebSocket. If you've used Ethereum's JSON-RPC before, everything works the same way: same method names, same parameters, same response format.
Endpoint
HTTP: http://localhost:18545 (or https://www.armchain.org/devnet for devnet)
WebSocket: ws://localhost:18546 (or wss://www.armchain.org/devnet for devnet)Request Format
curl -X POST <RPC_URL> \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"method": "<METHOD>",
"params": [<PARAMS>],
"id": 1
}'eth Namespace
eth_blockNumber
Returns the latest block number.
Response:
eth_getBalance
Returns the balance of an address in wei.
Parameters:
address: 20-byte addressblockTag: Block number or"latest","earliest","pending"
Response:
eth_getTransactionCount
Returns the number of transactions sent from an address (nonce).
Parameters:
address: 20-byte addressblockTag: Block number or tag
eth_sendRawTransaction
Submits a signed transaction for broadcast.
Parameters:
data: Signed transaction data (hex). Must be a Type 3 PQC transaction.
Response:
eth_call
Executes a call without creating a transaction (read-only).
Parameters:
transaction: Transaction call objectblockTag: Block number or tag
eth_estimateGas
Estimates gas for a transaction.
Parameters:
transaction: Transaction call object
eth_getBlockByNumber
Returns block information by block number.
Parameters:
blockNumber: Block number (hex) or tagfullTransactions: Iftrue, returns full transaction objects
eth_getTransactionByHash
Returns transaction details by hash.
Parameters:
transactionHash: 32-byte transaction hash
Response (Type 3 PQC Transaction):
eth_getTransactionReceipt
Returns the receipt of a mined transaction.
Parameters:
transactionHash: 32-byte transaction hash
eth_getLogs
Returns logs matching a filter.
Parameters:
filter: Filter object withfromBlock,toBlock,address,topics
eth_chainId
Returns the chain ID.
Response:
eth_gasPrice
Returns the current gas price.
eth_getCode
Returns the code at a given address (for contracts).
Parameters:
address: Contract addressblockTag: Block number or tag
Other Standard Methods
eth_accounts
Returns list of owned addresses
eth_sign
Signs data with account key
eth_signTransaction
Signs a transaction without sending
eth_getBlockByHash
Get block by hash
eth_getTransactionByBlockHashAndIndex
Get tx by block hash and index
eth_getTransactionByBlockNumberAndIndex
Get tx by block number and index
eth_getStorageAt
Get storage value at position
eth_syncing
Returns sync status
eth_mining
Returns whether node is mining/validating
eth_coinbase
Returns validator address
net Namespace
net_version
Returns network ID
net_listening
Whether node is listening for connections
net_peerCount
Number of connected peers
web3 Namespace
web3_clientVersion
Returns client version string
web3_sha3
Returns Keccak-256 of input
txpool Namespace
txpool_status
Returns pending and queued tx counts
txpool_content
Returns all pending and queued txs
txpool_inspect
Returns textual summary of pool
personal Namespace
Warning: Only use on local/private nodes. Never expose on public endpoints.
personal_newAccount
Create a new account
personal_unlockAccount
Unlock an account for signing
personal_lockAccount
Lock an account
personal_listAccounts
List all accounts
personal_sendTransaction
Sign and send a transaction
admin Namespace
admin_nodeInfo
Returns node information
admin_peers
Returns connected peers
admin_addPeer
Add a peer by enode URL
admin_removePeer
Remove a peer
admin_datadir
Returns the data directory path
WebSocket Subscriptions
Subscribe to New Blocks
Subscribe to Logs
Subscribe to Pending Transactions
Unsubscribe
Rate Limits
Public RPC endpoints may enforce rate limits.
Further Reading
Armchain-Specific APIs: DAG and PQC-specific endpoints
Network Configuration: Endpoints and chain details
Last updated