get_version - Monero

Example code for the get_version JSON-RPC method. Complete guide on how to use get_version JSON-RPC in GetBlock Web3 documentation.

This method returns the version of the connected monerod instance. Use it for capability detection and logging.

Parameters

  • None

Request Example

curl --location --request POST 'https://go.getblock.io/<ACCESS-TOKEN>/' \
--header 'Content-Type: application/json' \
--data-raw '{
    "jsonrpc": "2.0",
    "method": "get_version",
    "params": {},
    "id": "getblock.io"
}'

Response Example

{
    "id": "getblock.io",
    "jsonrpc": "2.0",
    "result": {
        "release": true,
        "status": "OK",
        "untrusted": false,
        "version": 196616
    }
}

Response Parameters

Field
Type
Description

result.version

unsigned int

Encoded version number (major * 65536 + minor)

result.release

boolean

true if this is a release build, false for development

result.status

string

General RPC error code

Use Cases

  • Capability detection in client libraries

  • Logging and debugging in multi-provider environments

  • Compatibility checks between client and node

Error Handling

Status Code
Error Message
Cause

403

Forbidden

Missing or invalid <ACCESS-TOKEN>

429

Too Many Requests

Rate limit exceeded for your plan

SDK Integration

Last updated

Was this helpful?