PublicKey

types/public_keyDocs


near-sdk-js v2.0.0 / types/public_key / PublicKey

Class: PublicKey

A abstraction on top of the NEAR public key string.

Constructors

new PublicKey()

new PublicKey(data): PublicKey

Parameters

data: Uint8Array

The string you want to create a PublicKey from.

Returns

PublicKey

Defined in

packages/near-sdk-js/src/types/public_key.ts:91

Properties

data

data: Uint8Array

The actual value of the public key.

Defined in

packages/near-sdk-js/src/types/public_key.ts:85

Methods

curveType()

curveType(): CurveType

The curve type of the public key.

Returns

CurveType

Defined in

packages/near-sdk-js/src/types/public_key.ts:105


fromString()

static fromString(publicKeyString): PublicKey

Create a public key from a public key string.

Parameters

publicKeyString: string

The public key string you want to create a PublicKey from.

Returns

PublicKey

Defined in

packages/near-sdk-js/src/types/public_key.ts:114

Last updated

Was this helpful?