← Robinhood Chain overview
Robinhood Chain · eth
eth_chainId
Returns the chain ID of the current network.
cURL
Endpoint: https://rh-mainnet.eu1.azxa.io/<api-key> — replace <api-key> with your API key from the Azxa app .
Terminal
curl -X POST https://rh-mainnet.eu1.azxa.io/<api-key> \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"eth_chainId","params":[]}'Example request
JSON-RPC
{
"jsonrpc": "2.0",
"id": 1,
"method": "eth_chainId",
"params": []
}Result
Chain ID
Example response
{
"jsonrpc": "2.0",
"id": 1,
"result": "0x1237"
}Schema
{
"type": "string",
"title": "hex encoded unsigned integer",
"pattern": "^0x(0|[1-9a-f][0-9a-f]*)$"
}Test fixture
Fixture: get-chain-id
Request
{
"jsonrpc": "2.0",
"id": 1,
"method": "eth_chainId"
}Response
{
"jsonrpc": "2.0",
"id": 1,
"result": "0xc72dd9d5e883e"
}