PFTransaction

Objective-C

@interface PFTransaction : NSObject

Swift

class PFTransaction : NSObject

Contains information about transaction that takes place after purchase.

  • id

    Identifier for the tracked transaction.

    Declaration

    Objective-C

    @property (readonly) NSString *_Nonnull id;

    Swift

    var id: String { get }
  • The product that has been purchased.

    Declaration

    Objective-C

    @property (readonly) PFProduct *_Nonnull product;

    Swift

    var product: PFProduct { get }
  • For subscription purchase, it’s the group the product belongs to.

    Declaration

    Objective-C

    @property (readonly) PFGroup *_Nonnull group;

    Swift

    var group: PFGroup { get }
  • For subscription purchase, it’s the package the product belongs to.

    Declaration

    Objective-C

    @property (readonly) PFPackageInfo *_Nonnull package;

    Swift

    var package: PFPackageInfo { get }
  • For subscription purchase, if it’s a trial purchase.

    Declaration

    Objective-C

    @property (readonly) Boolean *_Nonnull trial;

    Swift

    var trial: UnsafeMutablePointer<DarwinBoolean> { get }
  • The environment that the purchase took place. Possible values are in PFEnvironment.

    Declaration

    Objective-C

    @property (readonly) PFEnvironment environment;

    Swift

    var environment: PFEnvironment { get }
  • The date time when the purchase took place.

    Declaration

    Objective-C

    @property (readonly) NSDate *_Nonnull purchasedAt;

    Swift

    var purchasedAt: Date { get }