Skip to content

Allow users to add account address to the keyring by providing private key instead of mnemonic phrase #1690

Open
@ltfschoen

Description

@ltfschoen

I want to add functionality to secretcli, so that users can add a specific account to the keyring on Secret localhost by providing the private key associated with that account. for example, i'd like to be able to do this:

secretcli keys add --recover-privatekey secret-4
  > Enter your bip39 mnemonic
  <ENTER_MNEMONIC_PHRASE>

Where secretcli keys add --help would be updated to include:

--recover-privatekey    Provide private key hex value to recover existing key instead of creating

At the moment it only allows users to provide the mnemonic seed phrase, as shown below, but that doesn't add the correct account address to the keyring. e.g.

secretcli keys add --recover secret-4
  > Enter your bip39 mnemonic
  <ENTER_MNEMONIC_PHRASE>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions