In-App Purchase

RSS for tag

Offer extra content, digital goods, and features directly within your app using in-app purchases.

In-App Purchase Documentation

Posts under In-App Purchase tag

549 Posts
Sort by:
Post not yet marked as solved
4 Replies
789 Views
Hi, I am creating an app which provides in-app purchases to users, currently I am in testing phase of the purchase functionality and facing an issue regarding refunds. On upgrading a product that I am subscribed to (all products are auto-renewable subscriptions), I am receiving the UPGRADE notification type but I haven't yet received a REFUND notification type as the documentation suggests. I am using app store server-to-server Notifications 2.0+ with node.js as backend, I am receiving all the types of notifications just not the REFUND notification type.
Posted
by
Post not yet marked as solved
3 Replies
2.8k Views
I want pay commissions to partners that promote our apps. So if they write a review on their website and a user clicks on the link to the App Store and buys a subscription, I want to know that it originated so I can pay them the commission. Are there any Affiliate Marketing Platforms that support App Store sales? Is this even possible to track the origin of a sale through the App Store? Is there another way to track sales originating from promotion partners?
Posted
by
Post not yet marked as solved
2 Replies
1.8k Views
The current state of testing promotional codes in IOS is not developer friendly in the slightest. I have been trying to implement and test promo codes for a couple months now, while having the store kit integration helps slightly to mimic offer code redemption there is no friendly way of testing offer codes in test flight. I have it implemented with presentCodeRedemptionSheet() it seems the easiest way to test the codes is release my app to production create a 3-day promo which is the minimum amount of days that can be set, then wait 3 days before I can test again in different ways. One of my colleagues who is not a developer also wanted to test this feature and it did not work for her. Unfortunately it was a month long promo code she had redeemed so will have to wait till September to see if this is fixed for her now. I have also must note the fact the code redemption sheet and setting up payments in apple all together is a buggy mess. Starting out I added my card via apple pay thinking this would be enough to go through the redeem code process. Then upon entering my code it would show the dialog to verify with touch ID along with my payment details and even a picture of my card. After verifying, it then kept showing a pop up that I must include payment information which I already had added via apple pay. In the end to fix this I had to remove the payment method restart the device, add the payment method again then restart the device again. Another issue I bumped into is when you press redeem the "redeem offer" button is disabled but nothing happens for a while until it appears to timeout and you have to try again until it eventually works. The final annoyance I experienced was creating the offer code for my subscription and immediately trying to redeem it apple said the offer expired even though i set it to the 31st of August and the date was the 2nd. Only way to fix this was once waited and keep trying banging your head against the wall until it eventually works. In summary, I hope apple have a review of their offer code redemption process and make it more developer friendly and implement a way of testing within test flight whether it use live offer through test flight or include a new section to add test offer codes for subscriptions.
Posted
by
Post not yet marked as solved
1 Replies
927 Views
My app is essentially a digital marketplace where users can set their prices and sell digital products to other users. I read the App Review policy and found out that I had to implement in-app purchases if I wanted to sell digital products on iOS. In the process of figuring out how this was going to be implemented, I realized that in-app purchase items have to be created ahead of time. This means dynamic pricing is not possible, so what do now? Is there not a way to programmatically create in-app purchases? If there is not a way to do this, and I cant use my own payment processor, what is the way forward?
Posted
by
Post marked as Apple Recommended
19k Views
Hi, I can't get into "manage" sandbox account. I either get to a screen to put my password in. Here there is no way to click "next" or "login". (I have tried pressing "enter" on my keyboard to no effect). Or I get directly into "Cannot Connect" page. I have tried this two days in a row. I have tried turning it off and on again. I have tried logging out and in. Device: iPhone 13 pro max, iOS: 16.0.3 (also tried the version before this)
Posted
by
Post marked as solved
6 Replies
2.6k Views
I'm following the example code that comes with SKDemo to understand where in the lifecycle of my app to detect the subscription has expired to block users from having access to functionality they shouldn't have access to anymore. This is pretty straight forward to implement and check on app launch. However, my app has a pretty low memory footprint so it's often not getting terminated over the course of several days. Still, I would like to check for a valid subscription whenever the app is foregrounded. Otherwise users might have access to subscriber-only features for numerous days before the app finally has to cold start again. Is there a way to listen to these kind of 'subscription-expired' updates or do I need to figure out myself to verify the subscription, for instance, by listening to UIApplication.willEnterForegroundNotification and then run some business logic on my end to confirm the user is still within the subscription period?
Posted
by
Post not yet marked as solved
2 Replies
686 Views
Hello, In our B2C app our business customers need to offer one or more premium content channels customers can subscribe to. Each with a monthly and a yearly payment option. Having to create a unique subscription group specific to every possible premium content channel is simply not feasible and unmaintainable. I recognize we can't programmatically add subscription groups/subscriptions, so I am trying to instead use generic subscription groups/subscriptions to represent the possible price points and then mapping transactions to the relevant content channel(s) on the backend. We presently have 7 levels of premium content pricing options available for businesses to offer, each with a monthly and a yearly pricing option. I was encouraged to see a response from an App Store Commerce Engineer to a very similar question where it was suggested that we can use generic subscription groups and subscriptions as a generic price point mechanism and not have to have a subscription group for each individual channel for each individual business (https://developer.apple.com/forums/thread/698168). As such, creating 7 subscription groups, each with a monthly and a yearly subscription option is an acceptable solution and tests fine in the sandbox but I am concerned that once we roll to production it will not work because of not allowing a user to subscribe to multiple subscriptions in the same group, perhaps even at the same monthly option or whatever and will say 'You are already subscribed' or similar. So for example, let's say business A wants to offer two separate premium content channels, each at the L1 subscription level. Even if we are mapping it on the backend on our own, I suspect that the app store will reject the 2nd subscription request by the customer as they have already subscribed to a subscription in that group. Same if business A offers one L2 subscription channel of premium content and then business B also wants to offer subscriptions to their different premium channel content as an L2 subscription, the user could only sub to one or the other, not both because technically in the same sub-group and same subscription IAP. So where the App Store Commerce Engineer in the other post said, "Or you can create generic groups that dynamically represent the business a customer subscribes to. So this requires mapping the purchase Original_transaction_ID to your business identifier - and our product_ID is effectively a generic price point to represent pricing offerings your businesses choose from." as much as I want this to work, I'm not confident at all that it will given what I am reading on subscription group restrictions. Looking for confirmation advice here. Thanks so much for any help. BTW I did try to respond to the original question at the link above but appears to be locked. Thank you again for your time and consideration.
Posted
by
Post not yet marked as solved
1 Replies
1.6k Views
I am using local receipt validation and the SKReceiptRefreshRequest API to restore purchases. When my iOS 16.1 users tap "restore purchase", the call fails. Notably, it does not ask the users to log into their iTunes account (it normally does) and my app logs the following error: <SKReceiptRefreshRequest: 0x281b0ad20>: Finished refreshing receipt with error: Error Domain=ASDErrorDomain Code=603 "Request throttled" UserInfo={NSLocalizedFailureReason=Unified receipt is valid and current, NSLocalizedDescription=Request throttled, AMSServerErrorCode=0} These errors started showing up after the release of 16.1 and appear to be limited to that specific version of iOS. The relevant code has not changed in years and I have iOS 15 and iOS 16.0 users who are currently able to restore purchases without issue. Also, I am not able to reproduce the issue in the sandbox but I am able to do so in production. I'm a bit at a loss. Why would my request be "throttled" and, further, why only on iOS 16.1 and only in production? Any thoughts on what could be happening here? Any help is much appreciated. Thank you!
Posted
by
Post not yet marked as solved
1 Replies
537 Views
The new guidelines say apps may use in-app purchases to sell NFTs and sell services related to them, such as minting, listing, and the transferring of these tokens. Apps can also allow users to browse NFT collections owned by others so long as the apps do “not include buttons, external links, or other calls to action that direct customers to purchasing mechanisms other than in-app purchase" Is it possible to do in-app purchases using crypto currency for minting? Or minting with crypto currency is not allowed and now they only allow to mint with FIAT currencies?
Posted
by
Post not yet marked as solved
2 Replies
517 Views
Hello, After submission of a new app, we got review feedback that the IAP doesn't work. Upon further investigation, one issue we found is that the IAP is not added to the app submission as mentioned in https://help.apple.com/app-store-connect/#/dev1986a0e5c (submit IAP for the first time section). However, in our app store connect we found that there is no button to add IAP purchase as shown in the above page. Is there a possible glitch in App Store Connect that does not show the add IAP section? Thanks.
Posted
by
Post not yet marked as solved
11 Replies
2.3k Views
Hi community: When I try to access subscription settings, after filling in my sandbox user's password, a message "cannot connect" appears, just like below. Does someone know about a workaround to cancel or reset the subscription from the iPhone? Thanks in advance
Posted
by
Post marked as solved
5 Replies
4k Views
Dear all, This is my first post in this forum - and, in fact, my first app, too! I'm glad to be here, and thanks in advance for your help. I'm looking to offer an app for a one-time payment. I'd also like people to be able to try the app for a week. It seems that the "Pricing and Availability" section in App Store Connect is not the right place to configure this kind of offer. It does allow me to set a one-time price, but I cannot find a trial-period there (or am I missing something?) Two different strategies seem possible here: Using in-app-purchases: make the actual app free, but ask users after a week to buy a non-consumable IAP. The problem with that: I need to verify that the app has been installed for seven days ... even if it has been uninstalled at some point. Using subscriptions: There is a "free trial" option for subscriptions. But after that free trial, subscriptions are being payed periodically. I'd rather have the user only pay once for lifetime-access. Some apps seem to use strategy 1 - I believe the "Lap swim" app does. But still it seems like a bit of a hack - is there a more elegant way to achieve this?
Posted
by
Post not yet marked as solved
11 Replies
6.1k Views
Hi, thanks for reading my question. I need help with some odd behaviour with product.purchase() not triggering a confirmation dialog after a subscription has expired and trying to purchase it again. Seeing this in iOS 16.2 and 15.7.2 (haven't tried any other versions) on actual devices, not in simulator. I'm using a sandbox user on the sandbox environment (not using the local store kit config file testing option). Using a newly created sandbox user, first subscription purchase goes through just fine, dialog box pops up, login with sandbox user, get confirmation of purchase and then Transaction.currentEntitlements has one item as expected. It auto renews for 12 times (each time Transaction.currentEntitlements contains the correct results) and then expires, as expected for sandbox. Transaction.currentEntitlements is then also empty, as expected. All good so far. Now I want to test purchasing it again...Call product.purchase() again to renew/start a new subscription and nothing happens, no confirm purchase dialog box pops up at all. The purchase function simply exits BUT returns success (as in the following gets called) but in self.updatePurchasedProducts(), Transaction.currentEntitlements is empty. case let .success(.verified(transaction)):      // Successful purchase       await transaction.finish()      await self.updatePurchasedProducts() if I instead go to Settings->App Store->Sandbox User-> Manage Subscriptions and renew the subscription there, instead of in my app, then Transaction.currentEntitlements has a new entry and all is good again. Alternatively, if I create yet another new sandbox user and logout of the old one I was using, I am once again able to purchase from within the app, so .purchase() once again works as normal. Is there something I am missing about expired subscriptions and trying to purchase them again in the app? Is this a sandbox issue and in production I'll have no problem? The sandbox user has purchasing enabled in Settings->App Store. I've also tried calling AppStore.sync() (which is in my "Restore Purchase" button) before calling product.purchase() after the subscription stops renewing, expires and this issue comes up, doesn't resolve it. Also have a less important question, the initial call to product.purchase(), the one that works as expected, has a bit of a delay before the confirmation dialog pops up, a few seconds, which will probably result in the user clicking the buy button again thinking it didn't work. Is a bit of a delay normal for sandbox? Will it be ok in production? When it fails, and I have to renew in Settings->AppStore->Sandbox user, there's also a bit of a delay after I return to my app, 5-15 or so seconds, before the transaction observer fires and currentEntitlements is checked again, is there a way to reduce this delay? Thank you! Colin @MainActor class IAPManager: NSObject, ObservableObject {  // removed other functions.....   func purchase(_ product: Product) async throws {    let result = try await product.purchase()     switch result {    case let .success(.verified(transaction)):      // Successful purchase       await transaction.finish()      await self.updatePurchasedProducts()    case let .success(.unverified(_, error)):       break     case .pending:       break     case .userCancelled:       break     @unknown default:       break   } }  func updatePurchasedProducts() async {     for await result in Transaction.currentEntitlements {       guard case .verified(let transaction) = result else {         continue       }       if transaction.revocationDate == nil {         self.purchasedProductIDs.insert(transaction.productID)       } else {         self.purchasedProductIDs.remove(transaction.productID)       }     }   } }
Posted
by
Post not yet marked as solved
4 Replies
1.4k Views
Hey, in our app we show post-purchase flow when a user purchases a subscription and its appearance should depend on the type of purchase: upgrade, downgrade or crossgrade. I found a way how to get this type on the backend side but can not figure out how to get this within the app. I see that Transaction has isUpgraded property but it is always false even if I move from a lower service plan to a higher one. So, I have two questions: Is this actually possible to know on the client when the user upgrades, downgrades or crossgrades? If yes, then how? Thanks
Posted
by
Post marked as solved
7 Replies
1.6k Views
Hi I'm using presentCodeRedemptionSheet() method to display a sheet that enables users to redeem subscription offer codes. When calling the SKPaymentQueue.default().presentCodeRedemptionSheet() method on real app store app it will present redemption sheet and after entering the offer code in it is displaying screen where Cancel and Redeem buttons do not work. As seen in the attached picture. What could be the reason for this and what solutions can be found to solve the problem? Please someone help it is really frustrating. Environment: iOS 16.3
Posted
by
Post not yet marked as solved
3 Replies
1.4k Views
Hi All, We are trying server-to-server notifications for in-app purchases. This is the first time we are configuring in-app purchases for the app, so configurations are still for test apps and in-app purchases being tested by sandbox accounts. For server-to-server notification, we configured the url as mentioned in the doc, but still, our server url is not being called after a successful in-app purchase. Could you please help if anything more is required for config?
Post not yet marked as solved
2 Replies
1.3k Views
The sample code provided in https://developer.apple.com/wwdc21/10114 doesn't appear to call finish() on unverified transactions, and I haven't been able to find any documentation regarding what to do with unfinished transactions. However, Apple has always emphasized the importance of finishing transactions, and since a transaction object is provided even with the unverified state, I'd love some guidance!
Posted
by
Post not yet marked as solved
1 Replies
1.4k Views
Hi team, I would to extract the order information of customer's in-app purchase on app store to match against sales revenue. Looking through the Apple API documentation, I am taking the following steps Get status and history for in-app purchase transactions through the App Store Server API by calling the Get Transaction History endpoint. This returns me the purchase date, transactionID, and quantity information. There is also a field called productID which was created in Apple Store Connect. However i would also need to extract price information such as currency and item unit price. I looked through Apple Store Connect API which contains in app purchase information. How should i retrieve these fields from the response from Get Transaction History endpoint. Should I use the productID and what are the subsequent API endpoints to query?
Posted
by