UNPKG

@polkadot-labs/hdkd

Version:

Hierarchical deterministic (HD) account derivation library compatible with the Polkadot and Substrate ecosystems, supporting the sr25519, ed25519, and ecdsa signature schemes.

21 lines (14 loc) 739 B
import * as _polkadot_labs_hdkd_helpers from '@polkadot-labs/hdkd-helpers'; import { Hex, KeyPair } from '@polkadot-labs/hdkd-helpers'; type CreateDeriveFn = (seed: Hex) => (path: string) => KeyPair; declare const ecdsaCreateDerive: CreateDeriveFn; declare const ed25519CreateDerive: CreateDeriveFn; declare const sr25519CreateDerive: CreateDeriveFn; declare const withNetworkAccount: (keyPair: KeyPair, prefix?: number) => { accountId: Uint8Array<ArrayBufferLike>; ss58Address: string; ss58PublicKey: string; publicKey: Uint8Array; sign: (message: _polkadot_labs_hdkd_helpers.Hex) => Uint8Array; }; export { type CreateDeriveFn, ecdsaCreateDerive, ed25519CreateDerive, sr25519CreateDerive, withNetworkAccount };