Tradehub.Wallet.address_from_mnemonic

You're seeing just the function address_from_mnemonic, go back to Tradehub.Wallet module for more information.
Link to this function

address_from_mnemonic(mnemonic, network \\ :testnet)

View Source

Specs

address_from_mnemonic(String.t(), atom()) ::
  {:ok, String.t()} | {:error, String.t()}

Look for the wallet address based on the given mnemonic phrase within a network.

Examples

iex> Tradehub.Wallet.address_from_mnemonic("wrist coyote fuel wet evil tag shoot yellow morning history visit mosquito")
{:ok, "tswth174cz08dmgluavwcz2suztvydlptp4a8f8t5h4t"}

iex> Tradehub.Wallet.address_from_mnemonic("wrist coyote fuel wet evil tag shoot yellow morning history visit mosquito", :mainnet)
{:ok, "swth174cz08dmgluavwcz2suztvydlptp4a8fru98vw"}

iex> Tradehub.Wallet.address_from_mnemonic("wrost coyote fuel wet evil tag shoot yellow morning history visit mosquito")
{:error, "Invalid mnemonic"}