An account key pair (public and secret keys).

Deprecated

since v1.10.0, please use Keypair instead.

Constructors

Accessors

Constructors

  • Create a new Account object

    If the secretKey parameter is not provided a new key pair is randomly created for the account

    Parameters

    • Optional secretKey: number[] | Uint8Array

      Secret key for the account

    Returns Account

Accessors

  • get publicKey(): PublicKey
  • The public key for this account

    Returns PublicKey

  • get secretKey(): Buffer
  • The unencrypted secret key for this account. The first 32 bytes is the private scalar and the last 32 bytes is the public key. Read more: https://blog.mozilla.org/warner/2011/11/29/ed25519-keys/

    Returns Buffer