@aleph-sdk/monorepo
    Preparing search index...

    Class BaseAccount

    BaseAccount implements the Account class for the Base protocol. It is used to represent a Base account when publishing a message on the Aleph network.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    address: string
    publicKey: undefined | string
    selectedRpcId?: RpcId

    Methods

    • Ask for a Provider Account a read Access to its encryption publicKey If the encryption public Key is already loaded, nothing happens

      This method will throw if:

      • The account was not instanced with a provider.
      • The user denied the encryption public key sharing.

      Returns Promise<void>

    • The Sign method provides a way to sign a given Aleph message using an ethereum account. The full message is not used as the payload, only fields of the BaseMessage type are.

      The signMessage method of the package 'ethers' is used as the signature method.

      Parameters

      • message: SignableMessage

        The Aleph message to sign, using some of its fields.

      Returns Promise<string>