Class

NodeKey

NodeKey

Node key

The node key is used to authenticate the node in the Nillion network. The key can be generated from a seed or from a base58 string.

View Source nillion_client_wasm.js, line 1209

Example
const key = new NodeKey.from_seed("my_seed");

Methods

# static from_base58(contents) → {NodeKey}

Decodes a private key from a string encoded in Base58.

Parameters:
Name Type Description
contents string

A base58 string

View Source nillion_client_wasm.js, line 1256

An instance of NodeKey matching the string provided

NodeKey
Example
const key = new NodeKey.from_base58(<base 58 encoded data>);

# static from_seed(seed) → {NodeKey}

Generates a private key using a seed.

Parameters:
Name Type Description
seed string

The seed that will be used to generate the NodeKey

View Source nillion_client_wasm.js, line 1240

A NodeKey

NodeKey
Example
const key = new NodeKey.from_seed("my_seed");