interface JsonRpcGroupOptions {
    fixedVersion?: JsonRpcGroupVersion;
    prefix: string;
    rpcMethods?: string[];
    supportedVersions?: JsonRpcGroupVersion[];
}

Properties

fixedVersion?: JsonRpcGroupVersion

By default, the version is automatically detected from the available rpc-methods. If a fixed version is provided, it will be forced to use instead.

prefix: string

Prefix of the json-rpc group. E.g: chainHead, chainSpec, archive, etc.

According to JSON-RPC v2 Spec: https://paritytech.github.io/json-rpc-interface-spec/grouping-functions-and-node-capabilities.html#grouping-functions-and-node-capabilities

Note: The prefix should not contain any _ character.

rpcMethods?: string[]

List of rpc-methods to use for version detection. If not provided, the list will be fetched from the node/server. This is helpful when the node does not support rpc_methods method Or if we want to share the same rpc-methods list across multiple groups.

supportedVersions?: JsonRpcGroupVersion[]

List of supported versions. If provided, the detected version must be in this list else an error will be thrown. This is helpful when we want to verify behaviour of new version before using/support it. If not provided, any detected version will be used.