📘

You must provide a request id to get a response

According to the JSON RPC specification, a response is only returned when the "id" field is set in the request. If unset, the request is considered a "notification". Notifications are simply RPC Requests where a response is not expected.

type: object

Properties

Name

Type

Precense

Description

jsonrpc

string("2.0")

Always

Will always be "2.0"

id

any

Always

The client-side ID used for the request.

result

Result

On success

The result of a successful method call. In Clarify, the return type is always an object. The exact structure of the object depend on the method that was called.

error

Error

On failure

The result of a failed RPC method. In Clarify, we define our own structure for the error data field.

{
    "jsonrpc": "2.0",
    "id": 1,
    "result": {...}
}
{
    "jsonrpc": "2.0",
    "id": 1,
    "error": {
        "code": -32602,
        "message": "Invalid params",
        "data": {
            "trace": "00000000000000000000",
            "params": {
                "integration": ["required"]
            }
        }
    }
}