eth_getCode

Is essential for developers to inspect and verify contract code deployed on the Ethereum blockchain

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

Request params

NameTypeDescription
idintegerRequest identifier
jsonrpcstringJSON-RPC version
methodstringAPI method name
Parametersarray of strings 
addressstring
blockNumberstringThe block number or tag ("latest", "earliest", "pending") at which to get the balance.

Response

200
The smart contract code (EVM bytecode) stored at the specified address, returned as a hexadecimal string.
NameTypeDescription
Parametersobject 
idinteger
jsonrpcstring
resultstring