How to configure in-app purchases for your Twixl app.
1. Adding in-app purchases in AppStore Connect
In your app, contain may be offered for free, or some or all content may be available as an in-app purchase.
- If your app offers only free content, there's nothing else to configure but adding your content to the Twixl platform.
- If you want to make collections or PDF content items available as an in-app purchase, you will need to create a separate in-app purchase entry in AppStore Connect for each of the collections you want to offer. Note that the in-app purchase type for collections needs to be 'Non-Consumable'.
- Enter a reference name (that will be used for reporting purposes only), e.g. October 2020
- In the Product ID field, enter a unique identifier that will be used for reporting. It can be composed of letters and numbers. Usually this will also be a reverse DNS name like the app identifier: e.g.
com.casablancapublishing.rickscafe.oct2020
- Set pricing for the collection by selecting a price tier
- Provide in-app purchase information for at least one language.
2. Adding In-App Purchases
You can either add Collections or PDF Content Items as in-app purchases. For each of the in-app purchases defined in AppStore Connect, you also need to add a collection or PDF on the Twixl platform, and add the same identifier under 'Purchase Info' for your collection/PDF.
You can also add the title and extra info that will be displayed in the paywall.
IMPORTANT:
Make sure the product identifier in the Twixl platform matches exactly with the one you defined in AppStore Connect.
3. In-app purchase testing
In order to test in-app purchases with an Ad Hoc build of your app, Apple provides a sandboxing environment. To do this:
- Build and install an Ad Hoc version of your app.
- Create a test user in AppStore Connect.
- Logout from the App Store for your regular account.
- Try to make a purchase and login with the test user you created.
- You should be able to make the test purchase in the testing ('sandbox') environment.
4. Adding subscriptions in your app
For more info about this, see Working with subscriptions for iOS & Android