go-ethereum/docs/xdc/rpc/rpc.md
wit765 8155a2ee7e
docs: refactor jsonrpc api document (#1462)
Co-authored-by: wit <wit765765346@gmail>
2025-09-10 11:56:28 +08:00

560 B

Module rpc

Method rpc_modules

The modules returns the list of RPC services with their version number.

Parameters:

None

Returns:

result: ojbect

Example:

Request:

curl -s -X POST -H "Content-Type: application/json" ${RPC} -d '{
  "jsonrpc": "2.0",
  "id": 1001,
  "method": "rpc_modules"
}' | jq

Response:

{
  "jsonrpc": "2.0",
  "id": 1001,
  "result": {
    "XDPoS": "1.0",
    "debug": "1.0",
    "eth": "1.0",
    "net": "1.0",
    "personal": "1.0",
    "rpc": "1.0",
    "txpool": "1.0",
    "web3": "1.0"
  }
}