<!--
{
  "availability" : [
    "iOS: 15.0.0 - 26.0.0",
    "iPadOS: 15.0.0 - 26.0.0",
    "macOS: 12.0.0 - 26.0.0",
    "tvOS: 15.0.0 - 26.0.0",
    "visionOS: 1.0.0 - 26.0.0",
    "watchOS: 8.0.0 - 26.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "StoreKit",
  "identifier" : "/documentation/StoreKit/Product/PurchaseOption/promotionalOffer(offerID:keyID:nonce:signature:timestamp:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "StoreKit"
    ],
    "preciseIdentifier" : "s:8StoreKit7ProductV14PurchaseOptionV16promotionalOffer7offerID03keyI05nonce9signature9timestampAESS_SS10Foundation4UUIDVAL4DataVSitFZ"
  },
  "title" : "promotionalOffer(offerID:keyID:nonce:signature:timestamp:)"
}
-->

# promotionalOffer(offerID:keyID:nonce:signature:timestamp:)

Applies a promotional offer for an auto-renewable subscription.

```
static func promotionalOffer(offerID: String, keyID: String, nonce: UUID, signature: Data, timestamp: Int) -> Product.PurchaseOption
```

## Parameters

`offerID`

The subscription-offer identifier, [`id`](/documentation/StoreKit/Product/SubscriptionOffer/id).

`keyID`

The key ID of the subscription key.

`nonce`

The antireplay value used in the signature. Use lowercase.

`signature`

The cryptographic signature of the offer parameters, which you generate on your server.

`timestamp`

The UNIX time, in milliseconds, when you generate the signature.

## Return Value

An instance of [`Product.PurchaseOption`](/documentation/StoreKit/Product/PurchaseOption) to use in [`purchase(options:)`](/documentation/StoreKit/Product/purchase(options:)).

## Discussion

For information about `keyID`, `nonce`, `signature`, and `timestamp`, see [Generating a signature for promotional offers](/documentation/StoreKit/generating-a-signature-for-promotional-offers). If you’re providing an [`appAccountToken(_:)`](/documentation/StoreKit/Product/PurchaseOption/appAccountToken(_:)) in the purchase options, you must include that value when you generate the `signature`. Use lowercase for the UUID string representations of the app account token and the `nonce` in the signature.

You can offer a discounted or free period of service for auto-renewable subscriptions on iOS, iPadOS, macOS, and tvOS using promotional offers. Before you can provide promotional offers in your app, you must set up the offers in your App Store Connect account. To configure your offer, see [Set up promotional offers for auto-renewable subscriptions](https://developer.apple.com/help/app-store-connect/manage-subscriptions/set-up-promotional-offers-for-auto-renewable-subscriptions).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)