😟 API Errors and Troubleshooting

Troubleshooting the standard JSON-RPC errors.

Example Error Response

"code":-32602, // this is the reference error code
"message":"invalid argument 0: json: cannot unmarshal hex string of odd length into Go value of type common.Address"

A typical error message returned in JSON contains the following key fields.

  1. CODE : The JSON-RPC error code, see below for extended description.

  2. MESSAGE : An explanation of what went wrong, and how you can correct it.

JSON-RPC Error Codes


Return Message



Parse error

Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text.


Invalid Request

The JSON sent is not a valid Request object.


Method not found

The method does not exist / is not available.


Invalid params

Invalid method parameter(s).


Internal error

Internal JSON-RPC error.