Class

SKPaymentTransaction

An object in the payment queue.

Declaration

class SKPaymentTransaction : NSObject

Overview

A payment transaction is created whenever a payment is added to the payment queue. Transactions are delivered to your app when the App Store has finished processing the payment. Completed transactions provide a receipt and transaction identifier that your app can use to save a permanent record of the processed payment.

Topics

Getting Transaction Information

var payment: SKPayment

The payment for the transaction.

var transactionIdentifier: String?

A string that uniquely identifies a successful payment transaction.

var transactionDate: Date?

The date the transaction was added to the App Store’s payment queue.

var original: SKPaymentTransaction?

The transaction that was restored by the App Store.

var error: Error?

An object describing the error that occurred while processing the transaction.

Getting Downloads

var downloads: [SKDownload]

An array of download objects representing the downloadable content associated with the transaction.

Getting Transaction State

var transactionState: SKPaymentTransactionState

The current state of the transaction.

enum SKPaymentTransactionState

Values representing the state of a transaction.

Relationships

Inherits From

Conforms To

See Also

Delivering Content

Processing a Transaction

Register a transaction queue observer to get and handle transaction updates from the App Store.

class SKDownload

Downloadable content associated with a product.

class SKReceiptRefreshRequest

A request to refresh the receipt, which represents the user's transactions with your app.

class SKRequest

An abstract class that represents a request to the App Store.

func SKTerminateForInvalidReceipt()

Terminates an app if the license to use the app has expired.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software