Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EthWallet

Hierarchy

  • EthWallet

Index

Methods

  • getAccounts(): { address: string; algo: string; pubkey: Uint8Array }[]
  • sendTransaction(transaction: TransactionRequest): Promise<TransactionResponse>
  • Parameters

    • transaction: TransactionRequest

    Returns Promise<TransactionResponse>

  • setProvider(provider: Provider): void
  • sign(signerAddress: string, signBytes: string | Uint8Array): Signature
  • Parameters

    • signerAddress: string
    • signBytes: string | Uint8Array

    Returns Signature

  • signDirect(signerAddress: string, signDoc: SignDoc): Promise<{ signature: StdSignature; signed: SignDoc }>
  • signMessage(signerAddress: string, message: Uint8Array): Promise<string>
  • Parameters

    • signerAddress: string
    • message: Uint8Array

    Returns Promise<string>

  • signTransaction(signerAddress: string, transaction: any): Promise<string>
  • Generates a wallet from a mnemonic. Returns an EthWallet object.

    Parameters

    • mnemonic: string

      The mnemonic to generate a wallet from

    • options: WalletOptions

      WalletOptions object

    Returns EthWallet

  • Generates a wallet from a private key.

    Parameters

    • pvtKey: string

      The private key to generate the wallet from.

    • options: WalletOptions

      The options for the wallet.

    Returns EthWallet

    A wallet object.