Skip to content

Wallets

To create a wallet using a mnemonic, three functions are available

Wallet From Mnemonic

WalletFromMnemonic returns the first wallet generated by the mnemonic

account, err := txbuilder.WalletFromMnemonic(mnemonic)

Wallet From Mnemonic with Account ID

WalletFromMnemonicWithAccountID returns the wallet with id=accountID, always using the main path of derivation

account, err := txbuilder.WalletFromMnemonicWithAccountID(mnemonic, accountID)

Wallet From Mnemonic with Path

WalletFromMnemonicWithPath requires the complete mnemonic path to generate the wallet

account, err := WalletFromMnemonicWithPath(mnemonic, mnemonicPath)