Class

SKProductDiscount

The details of a discount offer for a subscription product.

Declaration

class SKProductDiscount : NSObject

Overview

You set up discount offers in App Store Connect, as described in App Store Connect Developer Help. SKProductDiscount contains the offer information as retrieved from the App Store.

Topics

Identifying the Discount

var identifier: String?

A string used to uniquely identify a discount offer for a product.

var type: SKProductDiscount.`Type`

The type of discount offer.

enum SKProductDiscount.Type

Values representing the types of discount offers an app can present.

Getting Price and Payment Mode

var price: NSDecimalNumber

The discount price of the product in the local currency.

var priceLocale: Locale

The locale used to format the discount price of the product.

var paymentMode: SKProductDiscount.PaymentMode

The payment mode for this product discount.

enum SKProductDiscount.PaymentMode

Values representing the payment modes for a product discount.

Getting the Discount Duration

var numberOfPeriods: Int

An integer that indicates the number of periods the product discount is available.

var subscriptionPeriod: SKProductSubscriptionPeriod

An object that defines the period for the product discount.

Relationships

Inherits From

Conforms To

See Also

Introductory Offers

Implementing Introductory Offers in Your App

Offer introductory pricing for auto-renewable subscriptions to eligible users.

Testing Introductory Offers

Test your introductory pricing in a variety of user scenarios.