ReadonlyaccountAccount address associated with the account
ReadonlypublicPublic key associated with the account
Sign the given message using the available signing capabilities.
in HexInput format
Signature
ReadonlysigningSigning scheme used to sign transactions
Sign the given transaction using the available signing capabilities.
the transaction to be signed
Signature
Sign a transaction using the available signing capabilities.
the raw transaction
the AccountAuthenticator containing the signature of the transaction, together with the account's public key
Sign a message using the available signing capabilities.
the signing message, as binary input
the AccountAuthenticator containing the signature, together with the account's public key
Verify the given message and signature with the public key. This function helps ensure the integrity and authenticity of a message by validating its signature.
The arguments for verifying the signature.
Represents the arguments required to verify a digital signature.
A boolean indicating whether the signature is valid.
Verify the given message and signature with the public key. It fetches any on chain state if needed for verification.
The arguments for verifying the signature.
The configuration object for connecting to the Aptos network
Raw message data in HexInput format.
Signed message signature.
A boolean indicating whether the signature is valid.
StaticauthRetrieve the authentication key for the associated account using the provided public key. This key enables account owners to rotate their private key(s) associated with the account without changing the address that hosts their account. See here for more info: https://aptos.dev/concepts/accounts#single-signer-authentication
The arguments for retrieving the authentication key.
The public key of the account.
The authentication key for the associated account.
StaticfromGenerates an account from a specified derivation path and mnemonic. This function allows you to create an account using different signing schemes based on the provided arguments.
The arguments for generating the account.
Arguments for generating an Ed25519 account, specifying the signing scheme and legacy option.
Optionallegacy?: trueOptionalscheme?: Ed25519Arguments for deriving a private key using a mnemonic phrase and a specified BIP44 path.
Generates an account from a specified derivation path and mnemonic. This function allows you to create an account using different signing schemes based on the provided arguments.
The arguments for generating the account.
Arguments for generating a SingleKeyAccount with an underlying Ed25519PrivateKey.
The legacy argument must be set to false to ensure an Ed25519SingleKeyAccount is returned.
Optionalscheme?: Ed25519Arguments for deriving a private key using a mnemonic phrase and a specified BIP44 path.
Generates an account from a specified derivation path and mnemonic. This function allows you to create an account using different signing schemes based on the provided arguments.
The arguments for generating the account.
Arguments for generating a SingleKeyAccount using a supported private key other than Ed25519PrivateKey.
The legacy argument is optional and defaults to false, and cannot be set to true.
Optionallegacy?: falseArguments for deriving a private key using a mnemonic phrase and a specified BIP44 path.
Generates an account from a specified derivation path and mnemonic. This function allows you to create an account using different signing schemes based on the provided arguments.
The arguments for generating the account.
Arguments for generating an opaque Account when the input signature scheme is unknown at compile time.
Optionallegacy?: booleanOptionalscheme?: SigningSchemeInputArguments for deriving a private key using a mnemonic phrase and a specified BIP44 path.
StaticfromCreates an account from a given private key and address. This function allows you to instantiate an account based on the provided private key, and it can differentiate between legacy and non-legacy accounts.
The arguments for creating the account.
Arguments for creating an Ed25519Account from an Ed25519PrivateKey.
To use the SingleKey authentication scheme, set legacy to false.
Optionaladdress?: AccountAddressInputOptionallegacy?: trueAn instance of either Ed25519Account or SingleKeyAccount based on the provided private key.
Creates an account from a given private key and address. This function allows you to instantiate an account based on the provided private key, and it can differentiate between legacy and non-legacy accounts.
The arguments for creating the account.
Arguments for creating a SingleKeyAccount from a supported private key, excluding Ed25519PrivateKey.
The legacy argument is always false and cannot be set to true.
Optionaladdress?: AccountAddressInputOptionallegacy?: falseAn instance of either Ed25519Account or SingleKeyAccount based on the provided private key.
Creates an account from a given private key and address. This function allows you to instantiate an account based on the provided private key, and it can differentiate between legacy and non-legacy accounts.
The arguments for creating the account.
Arguments for creating an Account from a private key when the key type is unknown at compile time.
Optionaladdress?: AccountAddressInputOptionallegacy?: booleanAn instance of either Ed25519Account or SingleKeyAccount based on the provided private key.
StaticfromThe arguments required to create an account from a private key.
Arguments for creating an Account from a private key when the key type is unknown at compile time.
Optionaladdress?: AccountAddressInputOptionallegacy?: booleanAccount
StaticgenerateGenerates a new account based on the specified signing scheme and legacy option. This function allows you to create an account with either the Ed25519 signing scheme or a different scheme as specified.
Optionalargs: GenerateEd25519AccountArgsThe arguments for generating the account.
Arguments for generating an Ed25519 account, specifying the signing scheme and legacy option.
Optionallegacy?: trueOptionalscheme?: Ed25519Generates a new account based on the specified signing scheme and legacy option. This function allows you to create an account with either the Ed25519 signing scheme or a different scheme as specified.
The arguments for generating the account.
Arguments for generating a SingleKeyAccount with an underlying Ed25519PrivateKey.
The legacy argument must be set to false to ensure an Ed25519SingleKeyAccount is returned.
Optionalscheme?: Ed25519Generates a new account based on the specified signing scheme and legacy option. This function allows you to create an account with either the Ed25519 signing scheme or a different scheme as specified.
The arguments for generating the account.
Arguments for generating a SingleKeyAccount using a supported private key other than Ed25519PrivateKey.
The legacy argument is optional and defaults to false, and cannot be set to true.
Optionallegacy?: falseGenerates a new account based on the specified signing scheme and legacy option. This function allows you to create an account with either the Ed25519 signing scheme or a different scheme as specified.
The arguments for generating the account.
Arguments for generating an opaque Account when the input signature scheme is unknown at compile time.
Optionallegacy?: booleanOptionalscheme?: SigningSchemeInputStaticcomputeCompute the account address of the DAA The DAA account address is computed by hashing the function info and the account identity and appending the domain separator (5)
The authentication function
The account identity
The account address
StaticfromCreates an AbstractedAccount from an Ed25519Account that has a permissioned signer function and
using the 0x1::permissioned_delegation::authenticate function to verify the signature.
The Ed25519Account that can be used to sign permissioned transactions.
The AbstractedAccount
StaticgenerateReadonlyabstractThe abstract public key that is used to identify the account. Depends on the use cases, most of the time it is the public key of the source wallet
ReadonlyauthenticationStatic ReadonlyADDRESS_The domain separator used to calculate the DAA account address.
Abstract class representing a generic Aptos account.
This class serves as a single entry point for account generation, allowing accounts to be created either through
Account.generate()orAccount.fromDerivationPath. Although it is defined as an abstract class, it should be treated as an interface and enforced using theimplementskeyword.Note: Generating an account instance does not create the account on-chain.