Account
Last updated
Was this helpful?
Last updated
Was this helpful?
Represents an account in the Polymesh blockchain. Accounts can hold POLYX, control Identities and vote on proposals (among other things)
‹UniqueIdentifiers, string›
↳ Account
• address: string
Polymesh-specific address of the account. Serves as an identifier
Protected
context• key: string
public key of the account. This is a hex representation of the address that is transversal to any Substrate chain
• uuid: string
▸ exists(): Promise‹boolean›
Determine whether this Account exists on chain
Returns: Promise‹boolean›
Get the free/locked POLYX balance of the account
note
can be subscribed to
Parameters:
callback
Retrieve the Identity associated to this Account (null if there is none)
▸ getPermissions(): Promise‹Permissions›
Retrieve the Permissions this Signer has as a Signing Key for its corresponding Identity
Returns: Promise‹Permissions›
Get the subsidized balance of this Account and the subsidizer Account. If this Account isn't being subsidized, return null
note
can be subscribed to
Parameters:
callback
Retrieve a list of transactions signed by this account. Can be filtered using parameters
note
uses the middleware
Parameters:
â–ªDefault value
filters: object= {}
blockNumber?
BigNumber
-
orderBy?
TransactionOrderByInput
-
size?
undefined | number
page size
start?
undefined | number
page offset
success?
undefined | false | true
whether the transaction was successful or not
tag?
TxTag
tag associated with the transaction
Check if this Account possesses certain Permissions for its corresponding Identity
Parameters:
permissions
Returns: Promise‹boolean›
Determine whether this Entity is the same as another one
Parameters:
entity
Returns: boolean
▸ isFrozen(): Promise‹boolean›
Check whether this Account is frozen. If frozen, it cannot perform any action until the primary key of the Identity unfreezes all secondary keys
Returns: Promise‹boolean›
Leave the Account's Identity. This operation can only be done if the Account is a secondary key for the Identity
Parameters:
args
void
opts?
â–¸ toJson(): string
Return the Account's address
Returns: string
Static
generateUuid▸ generateUuid‹Identifiers›(identifiers
: Identifiers): string
Generate the Entity's UUID from its identifying properties
Type parameters:
â–ª Identifiers
Parameters:
identifiers
Identifiers
Returns: string
Static
unserialize▸ unserialize‹Identifiers›(serialized
: string): Identifiers
Unserialize a UUID into its Unique Identifiers
Type parameters:
â–ª Identifiers
Parameters:
serialized
string
UUID to unserialize
Returns: Identifiers
Defined in
• authorizations: ‹›
Defined in
• context:
Inherited from .
Defined in
Defined in
Inherited from .
Defined in
Overrides .
Defined in
▸ getBalance(): Promise‹›
Defined in
Returns: Promise‹›
â–¸ getBalance(callback
: ‹›): Promise‹›
Defined in
‹›
Returns: Promise‹›
▸ getIdentity(): Promise‹ | null›
Defined in
Returns: Promise‹ | null›
Defined in
▸ getSubsidy(): Promise‹Omit‹, "beneficiary"› | null›
Defined in
Returns: Promise‹Omit‹, "beneficiary"› | null›
â–¸ getSubsidy(callback
: ‹Omit‹, "beneficiary"› | null›): Promise‹›
Defined in
‹Omit‹, "beneficiary"› | null›
Returns: Promise‹›
â–¸ getTransactionHistory(filters
: object): Promise‹‹››
Defined in
Returns: Promise‹‹››
â–¸ hasPermissions(permissions
: ): Promise‹boolean›
Defined in
â–¸ isEqual(entity
: ‹unknown, unknown›): boolean
Inherited from .
Defined in
‹unknown, unknown›
Defined in
â–¸ leaveIdentity(args
: void, opts?
: ): Promise‹‹void››
Defined in
note
this method is of type , which means you can call leaveIdentity.checkAuthorization
on it to see whether the Current Account has the required permissions to run it
Returns: Promise‹‹void››
Overrides .
Defined in
Inherited from .
Defined in
Inherited from .
Defined in