TzKTAccount

public struct TzKTAccount : Codable, Equatable

Model mapping to TzKT.io’s Account object

  • The address XTZ balance in RPC format

    Declaration

    Swift

    public let balance: Decimal?
  • The address staked (locked) XTZ balance in RPC format

    Declaration

    Swift

    public let stakedBalance: Decimal?
  • The address unstaked (pending unlock) XTZ balance in RPC format

    Declaration

    Swift

    public let unstakedBalance: Decimal?
  • type of account e.g. “user” or “empty”

    Declaration

    Swift

    public let type: String
  • tz1/2/3 kt1 address

    Declaration

    Swift

    public let address: String
  • prefixed public key

    Declaration

    Swift

    public let publicKey: String?
  • whether or not the account has performed a reveal operation

    Declaration

    Swift

    public let revealed: Bool?
  • The addresses delegation status

    Declaration

    Swift

    public let delegate: TzKTAccountDelegate?
  • The block level the delegate address was set

    Declaration

    Swift

    public let delegationLevel: Decimal?
  • Declaration

    Swift

    public let activeTokensCount: Decimal?
  • Declaration

    Swift

    public let tokenBalancesCount: Decimal?
  • Helper method to convert the RPC balance into an XTZAmount

    Declaration

    Swift

    public var xtzBalance: XTZAmount { get }
  • Helper method to convert the RPC balance into an XTZAmount

    Declaration

    Swift

    public var xtzStakedBalance: XTZAmount { get }
  • Helper method to convert the RPC balance into an XTZAmount

    Declaration

    Swift

    public var xtzUnstakedBalance: XTZAmount { get }
  • Helper method to to return the available or spendable balance

    Declaration

    Swift

    public var xtzAvailableBalance: XTZAmount { get }
  • Generic init

    Declaration

    Swift

    public init(balance: Decimal?, stakedBalance: Decimal?, unstakedBalance: Decimal?, type: String, address: String, publicKey: String, revealed: Bool, delegate: TzKTAccountDelegate?, delegationLevel: Decimal?, activeTokensCount: Decimal?, tokenBalancesCount: Decimal?)