Uses the given mnemonic phrase and hd path to re-generate a wallet.
import { generateWallet, restoreWallet } from "@sei-js/cosmjs";const restoredWallet = await restoreWallet(SEED_PHRASE); // has optional parameter for account indexconsole.log('restored mnemonic', restoredWallet.mnemonic); Copy
import { generateWallet, restoreWallet } from "@sei-js/cosmjs";const restoredWallet = await restoreWallet(SEED_PHRASE); // has optional parameter for account indexconsole.log('restored mnemonic', restoredWallet.mnemonic);
The mnemonic phrase created with the wallet
Optional
hdPath for the wallet you want to restore.
A DirectSecp256k1HdWallet object representing an existing wallet.
Uses the given mnemonic phrase and hd path to re-generate a wallet.
Example