Response

Response

As a response to your request you can expect a object that looks like this:

{
    "jsonrpc": "2.0",
    "id": "15ab1a33-2991-4992-9eda-dca939f99709",
    "result": {
        "dna": {
            "seq": "TGGCTTACGAGCTAC"
        }
    },
    "error": null
}
result

Result of the method call. This will be formatted according to the response schema of the method. See method documentation and Models

error

Will be null if method call did not raise any errors. Otherwise, this filed will contain an error object.

Errors

All errors in JSON-RPC follow the same model. See an example below.

{
    "code": 0,
    "message": "APIBlocks Exception",
    "data": {
        ...
    }
}
code

Is an unique error code.

message

A short message describing what kind of error it is.

data

Additional data of the error.

There are several standard errors that APIBlock can raise. We will have a look at them next.

In addition, each method might have extra errors. You can find them in the exception section of the method documentation.