Storekit 2
Generated on 8/6/2024
3 searches
StoreKit 2 introduces several new features and improvements for handling in-app purchases. Here are some key points:
-
Core API Enhancements:
- StoreKit 2 uses modern language features like the Swift Async/Await pattern to perform tasks such as fetching product metadata, purchasing, and retrieving customer transaction history.
- The transaction history APIs now include finished transactions for consumables, starting from iOS 18.
- The original API for in-app purchases is deprecated starting with iOS 18, and developers are encouraged to update their apps to use StoreKit 2 for better performance and new features.
-
Merchandising Using SwiftUI:
- StoreKit 2 provides tools to easily merchandise in-app purchases, including new features for the subscription store view.
- Developers can create custom control styles for subscription stores, using the same primitives that StoreKit uses to create standard styles.
-
Testing in Xcode:
- StoreKit testing in Xcode has been enhanced to make testing in-app purchase flows easier. Developers can now test privacy policies and license agreements locally using the StoreKit configuration in Xcode 16.
-
Updates to Offers:
- New view modifiers like
subscriptionPromotionalOffer
allow developers to show promotional offers in the UI of a subscription store view. - The StoreKit Message API can be used to show win-back offers to customers, providing options to build great merchandising UI and display subscription details along with any offers.
- New view modifiers like
For more detailed information, you can refer to the following sessions from WWDC 2024:
- What’s new in StoreKit and In-App Purchase (21:06)
- Implement App Store Offers (02:47)
Session Chapter Markers
What’s new in StoreKit and In-App Purchase
- Introduction
- Core API enhancements
- Merchandise using SwiftUI
- Test in Xcode
- Update to StoreKit 2
Implement App Store Offers
- Introduction
- Updates to offers
- Introducing win-back offers
- Configure win-back offers
- Support win-back offers
- Streamlined purchasing
What’s new in StoreKit and In-App Purchase
Learn how to build and deliver even better purchase experiences using the App Store In-App Purchase system. We’ll demo new StoreKit views control styles and new APIs to improve your subscription customization, discuss new fields for transaction-level information, and explore new testability in Xcode. We’ll also review an important StoreKit deprecation.
Implement App Store Offers
Learn how to engage customers with App Store Offers using App Store Connect, as well as the latest StoreKit features and APIs. Discover how you can set up win-back offers (a new way to re-engage previous subscribers) and generate offer codes for Mac apps. And find out how to test offers in sandbox and Xcode to make sure they work smoothly.