Skip to main content

Interface: SimpleKeypairLike

Methods​

publicKey()​

publicKey(): PublicKeyLike;

Returns​

PublicKeyLike


scheme()​

scheme(): SignatureScheme;

Returns​

SignatureScheme


signPersonalMessage()​

signPersonalMessage(message): UserSignatureLike;

Sign a personal message and return a UserSignature.

Parameters​

message​

PersonalMessageLike

Returns​

UserSignatureLike


signTransaction()​

signTransaction(transaction): UserSignatureLike;

Sign a transaction and return a UserSignature.

Parameters​

transaction​

TransactionLike

Returns​

UserSignatureLike


toBech32()​

toBech32(): string;

Encode a SimpleKeypair as flag || privkey in Bech32 starting with "iotaprivkey" to a string. Note that the pubkey is not encoded.

Returns​

string


toBytes()​

toBytes(): ArrayBuffer;

Encode a SimpleKeypair as flag || privkey in bytes

Returns​

ArrayBuffer


toDer()​

toDer(): ArrayBuffer;

Serialize this private key as DER-encoded PKCS#8

Returns​

ArrayBuffer


toPem()​

toPem(): string;

Serialize this private key as DER-encoded PKCS#8

Returns​

string


trySign()​

trySign(message): SimpleSignatureLike;

Parameters​

message​

ArrayBuffer

Returns​

SimpleSignatureLike


trySignUser()​

trySignUser(message): UserSignatureLike;

Parameters​

message​

ArrayBuffer

Returns​

UserSignatureLike


verifyingKey()​

verifyingKey(): SimpleVerifyingKeyLike;

Returns​

SimpleVerifyingKeyLike