Skip to main content
Module

x/polkadot/mod.ts>api.Keyring

Package publishing for deno.land/x/polkadot
Go to Latest
class api.Keyring
implements KeyringInstance
Re-export
import { api } from "https://deno.land/x/polkadot@0.2.40/mod.ts";
const { Keyring } = api;

@polkadot/keyring

Overview

Constructors

new
Keyring(options?: KeyringOptions)

Properties

decodeAddress
encodeAddress: (address: Uint8Array | string, ss58Format?: number) => string
readonly
pairs: KeyringPair[]
readonly
publicKeys: Uint8Array[]
readonly
type: KeypairType

Methods

addFromAddress(
address: string | Uint8Array,
meta?: KeyringPair$Meta,
encoded?: Uint8Array | null,
type?: KeypairType,
ignoreChecksum?: boolean,
encType?: EncryptedJsonEncoding[],
): KeyringPair
addFromJson(json: KeyringPair$Json, ignoreChecksum?: boolean): KeyringPair
addFromMnemonic(
mnemonic: string,
meta?: KeyringPair$Meta,
type?: KeypairType,
): KeyringPair
addFromPair(
pair: Keypair,
meta?: KeyringPair$Meta,
type?: KeypairType,
): KeyringPair
addFromSeed(
seed: Uint8Array,
meta?: KeyringPair$Meta,
type?: KeypairType,
): KeyringPair
addFromUri(
suri: string,
meta?: KeyringPair$Meta,
type?: KeypairType,
): KeyringPair
addPair(pair: KeyringPair): KeyringPair
createFromJson(unnamed 0: KeyringPair$Json, ignoreChecksum?: boolean): KeyringPair
createFromPair(
pair: Keypair,
meta?: KeyringPair$Meta,
type?: KeypairType,
): KeyringPair
createFromUri(
_suri: string,
meta?: KeyringPair$Meta,
type?: KeypairType,
): KeyringPair
getPair(address: string | Uint8Array): KeyringPair
getPairs(): KeyringPair[]
getPublicKeys(): Uint8Array[]
removePair(address: string | Uint8Array): void
setSS58Format(ss58: number): void
toJson(address: string | Uint8Array, passphrase?: string): KeyringPair$Json