net_version

Retrieves the current network ID the Ethereum client is connected to

Request
Examples
curl https://rpc.xone.org \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","method":"net_version","params":[],"id":67}'
'
Response
200 OK
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": "0xb1770efb14906e509893b6190359658208ae64d0c56e22f748a1b0869885559e"
}

Request params

NameTypeDescription
idintegerRequest identifier
jsonrpcstringJSON-RPC version
methodstringAPI method name
ParametersThis method does not accept any parameters. 

Response

200
The network ID as a string, representing the specific network the client is connected to.
NameTypeDescription
Parametersobject 
idinteger
jsonrpcstring
resultstring