export default class AddressImporter { /** * Import a wallet using a mnemonic phrase * * @param {string} mnemonic - The mnemonic words to import the wallet from * @param {string} [seedPassword] - (Optional) The password to use to secure the mnemonic * @returns {Wallet} - The wallet derived from the mnemonic phrase */ static fromMnemonic: (mnemonic: string, seedPassword?: string) => Wallet; /** * Import a legacy wallet using a mnemonic phrase * * @param {string} mnemonic - The mnemonic words to import the wallet from * @returns {Wallet} - The wallet derived from the mnemonic phrase */ static fromLegacyMnemonic: (mnemonic: string) => Wallet; /** * Validate mnemonic words * * @param mnemonic {string} mnemonic - The mnemonic words to validate */ static validateMnemonic: (mnemonic: string) => boolean; /** * Import a wallet using a seed * * @param {string} seed - The seed to import the wallet from * @param {number} [from] - (Optional) The start index of the private keys to derive from * @param {number} [to] - (Optional) The end index of the private keys to derive to * @returns {Wallet} The wallet derived from the mnemonic phrase */ static fromSeed: (seed: string, from?: number, to?: number) => Wallet; /** * Import a wallet using a legacy seed * * @param {string} seed - The seed to import the wallet from * @param {number} [from] - (Optional) The start index of the private keys to derive from * @param {number} [to] - (Optional) The end index of the private keys to derive to * @returns {Wallet} The wallet derived from the seed */ static fromLegacySeed: (seed: string, from?: number, to?: number, mnemonic?: string) => Wallet; /** * Derives BIP32 private keys * * @param {string} seed - The seed to use for private key derivation * @param {number} from - The start index of private keys to derive from * @param {number} to - The end index of private keys to derive to */ private static accounts; /** * Derives legacy private keys * * @param {string} seed - The seed to use for private key derivation * @param {number} from - The start index of private keys to derive from * @param {number} to - The end index of private keys to derive to */ private static legacyAccounts; } export interface Wallet { mnemonic: string; seed: string; accounts: Account[]; } export interface Account { accountIndex: number; privateKey: string; publicKey: string; address: string; }