Questions tagged [in-app-purchase]

In-app purchase (IAP) usually refers to the acquisition of a feature for an application from within the application itself or the buying of digital goods from within an application. Use this tag for questions about writing code for the buying process. Questions about app-store policies or about specific transactions are off-topic on Stack Overflow and should not be posted.

In-app purchases (IAP) are digital goods that, when bought from within an app, often either unlock new features, enable the user to skip mundane tasks, or provide additional content.
Such purchases were made popular by Apple's iOS SDK, iPhones, iPod Touches, and iPads, but are not limited in any way to these platforms.

Don't ask questions about the transaction process itself, except where it pertains to coding problems. Remember that Stack Overflow cannot answer questions specific to Customer Support

##How to Implement In-App Purchase:

##Libraries

9247 questions
65
votes
13 answers

Testing in-app billing: "The publisher cannot purchase this item"

My app seems ready to get a 'real life' test for an in-app purchase procedure on my device. However, I receive an "The publisher cannot purchase this item" error message in Play Store. Now, how am I supposed to test this? I don't want to lose my…
richey
  • 3,890
  • 9
  • 35
  • 49
62
votes
10 answers

Link to app manage subscriptions in app store

Currently with In app purchase the only way to cancel an auto-renewing subscription is to do the following with the device: Settings > Store > View my account > Manage my subscription Is it possible programmatically to link directly to the Manage…
62
votes
6 answers

How to set-up In App Purchase free trial period in iOS app

In Apple's AppStore Terms & Conditions, you may find the following statement in relation to Auto-renewable In App Purchases: "Certain paid In App Subscriptions may offer a free trial period prior to charging your Account." How does it work? I…
lef
  • 1,196
  • 1
  • 9
  • 18
61
votes
4 answers

Requesting an In App Purchase in iOS 13 fails

I use SwiftyStoreKit to request In App Purchases and get only this error with iOS 13: Error: Optional(Error Domain=ASDErrorDomain Code=507 "Error decoding object" UserInfo={NSLocalizedDescription=Error decoding object,…
Timothy C.
  • 639
  • 1
  • 5
  • 10
61
votes
3 answers

Submit in app purchase for review for first time

I am working on in app purchase. After submitting all the details in app purchase gives me status "Ready to Submit". But the "Submit For Review" button is disabled in my app's in app purchase. This is giving me this warning "Your first In-App…
Pradumna Patil
  • 2,180
  • 3
  • 17
  • 46
61
votes
16 answers

Reasons for SKProductsRequest returning 0 products?

I'm trying to set up IAP but after making a call to retrieve the products using SKProductsRequest the SKProductsResponse array within my delegate has a count of 0. Here's my checklist: Test product has been added to iTunes connect The product's…
Gruntcakes
  • 37,738
  • 44
  • 184
  • 378
59
votes
8 answers

Unable to log in with sandbox test users on device

Trying to do some In App Purchase testing, so I created a sandbox tester on itunesconnect... but when I attempt to log in as that user on my device I get an error: Itunes Account creation not allowed The Apple ID cannot be used with the iTunes…
Speckpgh
  • 3,332
  • 1
  • 28
  • 46
59
votes
6 answers

Convert existing iOS paid app to freemium model with in-app purchase

I currently have a paid app in the store. Apple have not allowed a 'lite' version to be submitted as well, so I have no choice but to update the current paid version to a freemium (with in app purchase) model. I have the problem of not loosing…
fringley
  • 591
  • 1
  • 5
  • 3
57
votes
10 answers

iOS 13 - How to login in in-app purchase Sandbox account?

In order to test my in-app purchases with iOS 13 I have to update one of my test devices to iOS 13.1 beta. On iOS 12 and before there was a special Sandbox login in Settings/iTunes & App Store/Sandbox Account: However, after the update to iOS 13…
Andrei Herford
  • 17,570
  • 19
  • 91
  • 225
56
votes
5 answers

Unable to change the Price tier in the In app Purchase

I'm unable to change the price of an in-app purchase. I added initially for testing purposes, but now that I'm submitting the app, I'd like to change it. Unfortunately, it doesn't seem to accept the change. It is showing me the same price tier not…
Purva
  • 1,291
  • 2
  • 15
  • 30
56
votes
7 answers

How does Apple notify iOS apps of refunds of in-app purchases (IAP)?

I have Apple iOS IAP successfully implemented in my app and tested in the sandbox. Works great. I'm concerned that users could buy something with IAP, download it into my app, then complain to Apple and get a refund. There's no obvious way that…
Craig
  • 3,253
  • 5
  • 29
  • 43
56
votes
14 answers

SKPaymentQueue addTransactionObserver asking for App Store password on startup after in-app purchase

My app is using in-app purchases, and most of my users can purchase just fine without any problems. For these folks, my app downloads the content after the purchase succeeds and they are happy. However, for a growing number of my users, once they…
montuno
  • 867
  • 1
  • 7
  • 15
56
votes
11 answers

Android In-App Billing: Purchase state stays "purchased" after order cancelation

I'm currently testing my InApp billing mechanism (using the InApp Billing version 3 API, therefore taking the TrivialDrive example as reference). I have one managed item, which is upgrade to premium version. Now, purchasing the item with my test…
Toni Kanoni
  • 2,265
  • 4
  • 23
  • 29
53
votes
9 answers

Implementing In App purchases in Android?

Edit: Android now supports in-app billing! Original question: It looks like Android won't natively support in-app purchases for a while, and when it does there might be a huge user base with devices that don't support them. What's the best way to…
hpique
  • 119,096
  • 131
  • 338
  • 476
51
votes
3 answers

When to use restoreCompletedTransactions for in-app purchases?

For a basic app with nonconsumable in-app purchases, has anyone figured out best practices for using SKPaymentQueue's restoreCompletedTransactions? Observations I know it's recommended to always register a transaction observer to receive pending…
otto
  • 2,230
  • 2
  • 26
  • 26