Options
All
  • Public
  • Public/Protected
  • All
Menu

Account information at a given round. Definition: data/basics/userBalance.go : AccountData

Hierarchy

Index

Constructors

  • new Account(__namedParameters: { address: string; amount: number | bigint; amountWithoutPendingRewards: number | bigint; appsLocalState?: ApplicationLocalState[]; appsTotalExtraPages?: number | bigint; appsTotalSchema?: ApplicationStateSchema; assets?: AssetHolding[]; authAddr?: string; createdApps?: Application[]; createdAssets?: Asset[]; minBalance: number | bigint; participation?: AccountParticipation; pendingRewards: number | bigint; rewardBase?: number | bigint; rewards: number | bigint; round: number | bigint; sigType?: string; status: string; totalAppsOptedIn: number | bigint; totalAssetsOptedIn: number | bigint; totalCreatedApps: number | bigint; totalCreatedAssets: number | bigint }): modelsv2.Account
  • Creates a new Account object.

    Parameters

    • __namedParameters: { address: string; amount: number | bigint; amountWithoutPendingRewards: number | bigint; appsLocalState?: ApplicationLocalState[]; appsTotalExtraPages?: number | bigint; appsTotalSchema?: ApplicationStateSchema; assets?: AssetHolding[]; authAddr?: string; createdApps?: Application[]; createdAssets?: Asset[]; minBalance: number | bigint; participation?: AccountParticipation; pendingRewards: number | bigint; rewardBase?: number | bigint; rewards: number | bigint; round: number | bigint; sigType?: string; status: string; totalAppsOptedIn: number | bigint; totalAssetsOptedIn: number | bigint; totalCreatedApps: number | bigint; totalCreatedAssets: number | bigint }
      • address: string
      • amount: number | bigint
      • amountWithoutPendingRewards: number | bigint
      • Optional appsLocalState?: ApplicationLocalState[]
      • Optional appsTotalExtraPages?: number | bigint
      • Optional appsTotalSchema?: ApplicationStateSchema
      • Optional assets?: AssetHolding[]
      • Optional authAddr?: string
      • Optional createdApps?: Application[]
      • Optional createdAssets?: Asset[]
      • minBalance: number | bigint
      • Optional participation?: AccountParticipation
      • pendingRewards: number | bigint
      • Optional rewardBase?: number | bigint
      • rewards: number | bigint
      • round: number | bigint
      • Optional sigType?: string
      • status: string
      • totalAppsOptedIn: number | bigint
      • totalAssetsOptedIn: number | bigint
      • totalCreatedApps: number | bigint
      • totalCreatedAssets: number | bigint

    Returns modelsv2.Account

Properties

address: string

the account public key

amount: number | bigint

(algo) total number of MicroAlgos in the account

amountWithoutPendingRewards: number | bigint

specifies the amount of MicroAlgos in the account, without the pending rewards.

appsLocalState?: ApplicationLocalState[]

(appl) applications local data stored in this account. Note the raw object uses map[int] -> AppLocalState for this type.

appsTotalExtraPages?: number | bigint

(teap) the sum of all extra application program pages for this account.

appsTotalSchema?: ApplicationStateSchema

(tsch) stores the sum of all of the local schemas and global schemas in this account. Note: the raw account uses StateSchema for this type.

assets?: AssetHolding[]

(asset) assets held by this account. Note the raw object uses map[int] -> AssetHolding for this type.

attribute_map: Record<string, string>
authAddr?: string

(spend) the address against which signing should be checked. If empty, the address of the current account is used. This field can be updated in any transaction by setting the RekeyTo field.

createdApps?: Application[]

(appp) parameters of applications created by this account including app global data. Note: the raw account uses map[int] -> AppParams for this type.

createdAssets?: Asset[]

(apar) parameters of assets created by this account. Note: the raw account uses map[int] -> Asset for this type.

minBalance: number | bigint

MicroAlgo balance required by the account. The requirement grows based on asset and application usage.

participation?: AccountParticipation

AccountParticipation describes the parameters used by this account in consensus protocol.

pendingRewards: number | bigint

amount of MicroAlgos of pending rewards in this account.

rewardBase?: number | bigint

(ebase) used as part of the rewards computation. Only applicable to accounts which are participating.

rewards: number | bigint

(ern) total rewards of MicroAlgos the account has received, including pending rewards.

round: number | bigint

The round for which this information is relevant.

sigType?: string

Indicates what type of signature is used by this account, must be one of:

  • sig
  • msig
  • lsig
status: string

(onl) delegation status of the account's MicroAlgos

  • Offline - indicates that the associated account is delegated.
  • Online - indicates that the associated account used as part of the delegation pool.
  • NotParticipating - indicates that the associated account is neither a delegator nor a delegate.
totalAppsOptedIn: number | bigint

The count of all applications that have been opted in, equivalent to the count of application local data (AppLocalState objects) stored in this account.

totalAssetsOptedIn: number | bigint

The count of all assets that have been opted in, equivalent to the count of AssetHolding objects held by this account.

totalCreatedApps: number | bigint

The count of all apps (AppParams objects) created by this account.

totalCreatedAssets: number | bigint

The count of all assets (AssetParams objects) created by this account.

Methods

  • get_obj_for_encoding(binary?: boolean): Record<string, any>
  • Get an object ready for encoding to either JSON or msgpack.

    Parameters

    • binary: boolean = false

      Use true to indicate that the encoding can handle raw binary objects (Uint8Arrays). Use false to indicate that raw binary objects should be converted to base64 strings. True should be used for objects that will be encoded with msgpack, and false should be used for objects that will be encoded with JSON.

    Returns Record<string, any>

Generated using TypeDoc