Reputation: 1959
I am developing a iPhone app. For that i have successfully add the In App Purchase functionality. It is working perfectly for a single item purchase. My problem is that How can i do this for multiple item purchase with single purchase request to App Store? Can anybody help me for this?
Upvotes: 2
Views: 1230
Reputation: 5117
You can use quantity property in SKPayment... Read how many items you want from user then pass this value to payment.quantity(By default it is 1).
SKPayment *payment = [SKPayment paymentWithProductIdentifier:inProductID];
payment.quantity = mNoOfItemsYouWant;
[[SKPaymentQueue defaultQueue]addTransactionObserver:mTransactionObserver];
[[SKPaymentQueue defaultQueue] addPayment:payment];
Upvotes: 2
Reputation: 39029
Each purchase needs authorization from the user, so I don't think you can do what you want to.
However, you can make a single in-app purchase which is priced and behaves like multiple items clubbed together. For instance:
Upvotes: 0