I've already done my test on development signed app locally, all in-app purchase runs well with sandbox tester Apple ID.
Errors happens when make a purchase in distribution app from TestFlight.
Detail Info:
in Apple Store connect , make app available to China
Electron project, packaging by electron builder using distribution sign
upload to TestFlight, invite myself to test
using my Apple ID(not the sandbox tester) to login and purchase
dialog appears and said "Account not in this store"
VPN is off
Apple Store shows Chinese language and Chinese apps, not llikely to be u.s. store
I'm suspecting that:
Maybe shouldn't use my developer Apple ID to run TestFlight test?
TestFlight locked app to be in u.s. store ?
In-App Purchase
RSS for tagOffer extra content, digital goods, and features directly within your app using in-app purchases.
Posts under In-App Purchase tag
200 Posts
Sort by:
Post
Replies
Boosts
Views
Activity
I cannot find the in app purchase key in the integrations tab, I have signed the paid apps agreement. I can see the connect store api but not the In app purchase api key.
StoreKit2 is being tested in a Sandbox environment for the purchase of consumable items.
The code being implemented is below.
let result = try? await product.purchase()
switch result {
case let .success(verification):
switch verification {
case let .verified(transaction):
let jws = verification.jwsRepresentation
let success = await purchaseItem(of: itemId, with: jws)
if success {
await transaction.finish()
return (success: true, error: nil)
} else {
return (success: false, error: .serverError)
}
case .unverified:
return (success: false, error: .unverified)
}
Assume that the verification was successful, but a server error occurred. in let success = await purchaseItem(of: itemId, with: jws), success = false
When tested in Sandbox and local environment, the first alert of purchase completion is displayed. After that, a purchase failure alert is displayed. (The purchase failure alert is displayed by the result of return (success: false, error: .serverError))
Is it proper behavior to display purchase completion once?
Is it appropriate behavior for the purchase completion to be displayed once in the production environment?
Is the billing actually occurring at this time?
Thank you in advance for your answers!
Hi there, I'm implementing in app purchase in Electron following docs here: https://www.electronjs.org/zh/docs/latest/tutorial/in-app-purchases
But :
getProducts returns []
calls to purchaseProduct, nothing happend(no dialog, no login)
calls to restoreCompletedTransactions , a login dialog appears, and I can login my sandbox tester account. The account even appears int the Apple Store.
More info list as follow.
Packaging using electron builder, configuration is :
"masDev": {
"type":"development",
"identity": "York Chan",
"hardenedRuntime": false,
"gatekeeperAssess": false,
"entitlements": "./build/entitlements.mas.plist",
"entitlementsInherit": "./build/entitlements.mas.inherit.plist",
"provisioningProfile": './build/provisionloginsight.provisionprofile', //development的描述文件,确保系统描述文件里已经安装好
},
"mas": {
"type": "distribution",
"identity": "York Chan",
"hardenedRuntime": false,
"entitlements": "./build/entitlements.mas.plist",
"entitlementsInherit": "./build/entitlements.mas.inherit.plist",
"entitlementsLoginHelper": "./build/entitlements.mas.loginhelper.plist", //如果需要testflight则该项必须
"provisioningProfile": './build/provisionloginsightappstore.provisionprofile', //distribution描述文件
},
"mac": {
"artifactName": "${productName}_${version}.${ext}",
"identity":null,
"type": "development", //mas - distribution; mas-dev - development,
"icon": "./icons/icon512.icns",
"target": [
{
"target": "mas-dev",//mas
"arch": [
"universal"
],
}
],
"extendInfo":{
}
},
I wrap StoreKit API into 'Platform' class, and call from render process to main process using ipcRender.invoke
If I create a Xcode project, and set bundler identifier to the same one, configure the storekit in schema, I can successfully 'purchase', and seeing [Enviroment: Xcode].
Someone can help me please ?
Hello, I tried to create an subscription for my app but I receive this error every time, what should I do?
When the full version of the app was purchased before the IAP was implemented, the original purchase is not restored and there is no feedback/notification. Ideally, this should also allow a restoration of the purchase.
Hello everyone,
I am trying to implementing the In-App Purchase in one of my iOS App and I am getting the following error when I test it into iPhone, but when I test the same app into the iPad I didn't get any error and it works properly.
Error Domain=SKErrorDomain Code=0 "An unknown error occurred" UserInfo={NSLocalizedDescription=An unknown error occurred, NSUnderlyingError=0x282da9860 {Error Domain=ASDErrorDomain Code=500 "(null)" UserInfo={NSUnderlyingError=0x282d02940 {Error Domain=AMSErrorDomain Code=203 "Bag Load Failed" UserInfo={NSLocalizedFailureReason=Unable to retrieve p2-product-offers-batch-limit because we failed to load the bag., NSLocalizedDescription=Bag Load Failed, NSUnderlyingError=0x282d02af0 {Error Domain=AMSErrorDomain Code=203 "Bag Load Failed" UserInfo=0x2836ca380 (not displayed)}}}}}}
Apple has deprecated the https://buy.itunes.apple.com/verifyReceipt API and encourages users to migrate to the new https://api.storekit.itunes.apple.com/inApps/v1/transactions/{transactionId} API. However, during the migration, a problem was discovered. Previously, with the verifyReceipt API, the 21007 status code could be used to distinguish between the sandbox and production environments. Now, with the new API, if the {transactionId} is from the sandbox environment, it will directly return {"errorCode":4040010,"errorMessage":"Transaction id not found."}.
How can I distinguish whether a {transactionId} is generated in the sandbox environment or the production environment?
Hi,
Our application offers 3 non-renewing subscriptions. I have integrated the necessary code, and our App Store Account Paid Agreement status is Active. Transactions are successfully completed in the sandbox environment.
However, I am facing difficulties with server-side validation. The /verifyReceipt API is deprecated, and I need an alternative method for server-side validation. The Apple documentation is quite confusing, and I couldn't find any articles related to the new approach for server-side validation.
I would greatly appreciate it if you could provide a detailed guide on how to perform server-side validation with the new method.
Thank you in advance.
I have yearly auto renew subscription. in ASC I generate a promo code. giving user free subscription.
At the end of the year are they
[A ] renewed automatically for free so promo code continues?
[B ] renewed automatically at the actual subscription price
[ C] not renewed so effectively get to choose to start a subscription at the current price
[D ] none of the above
I'm having problems creating an in-app purchase apple store connect
it got error cannot create while my account is in admin role
Error message: "An error has occurred. Try again later."
Has anyone had the same problem and solution
Thank!
{
"errors" : [ {
"id" : "9627df33-29f3-4764-9b77-cc6f1fd14129",
"status" : "409",
"code" : "ENTITY_ERROR.IAP_CREATION_NOT_ALLOWED",
"title" : "You cannot create new in-app purchase.",
"source" : {
"pointer" : "/data/id"
}
} ]
}
We are a small startup and in process of launching our product. For now we have digital services (user can add and see data as they entered only be subscribed), but later we would have value added services - including hardware ( devices e.g. Glucometer).
Current payment workflow we have uses Razorpay as payment gateway. We have two options:
We can either make a web page for the payments to be collected via Razorpay. this will have less impact on the code and implementation. (like there's for Netflix and Spotify where they redirect to browser for payment than in-app purchase)
We can add the apple payment gateway for the payments.
Questions:
What would be the charges in both the scenarios ? E.g. If we take 100rs payment from patient then how much would go to apple in scenario 1 and 2.
Is there any support for small startups where apple provides some discount with respect to the payments collected ?
Hello, I'm using 'App Store Server Notifications V2'.
I have a question about 'CONSUMPTION_REQUEST' notification in 'notificationType'.
I was wondering if there would be any impact on refunds if I received this notification and didn't respond. (Always refund etc..)
Hi,
I am trying to determine if an in-app purchase will be required within the app we are developing.
We provide a web platform where the user can sign in and offer/search services correlated to entertainment world (showman, catering, DJ, live food lesson, etc.). The web app has 2 target: consumer users and business user.
Consumer users can search services that tay want and chat business users owner of that services.
Business users can create their ownpages in order to be visible to the consumer users in the community. Business users can also access too specified premium features for visibility.
We are now designing a mobile app with only few features:
Register login section
Search business pages
The users are the same and there is no differences in the mobile features (no hide premium functionalities). For these small features we have to implement the in-app purchase? The idea is to provide initially a small "companion" app to search business pages.
Fo the next releases, where we want to provide more features, premium functionalities for business user we will integrate in-app and we already have plans to implement it.
Thanks in advance!
Is it possible - in appstore - to create a subscriptions model similar to what microsoft teams and google workspace has for team memberships?
We want to have a subscription price per user per month (or year).
Administrator should be able to add additional users (and add a subscription for the new users) - It doesn't seem to be possible - only option is to have prefix subscriptions with 5 users, 10user, 15 users etc.
(we've also looked into consumables - but the lack the option to be reoccurring payments)
Thanks in advance?
I also still getting the same error from sandbox
"x": "Invalid response: Client error: GET https://api.storekit-sandbox.itunes.apple.com/inApps/v1/transactions/2000000632845273 resulted in a 401 Unauthorized response",
while for production url
"x": "Invalid response: Client error: GET https://api.storekit.itunes.apple.com/inApps/v1/transactions/2000000632845273 resulted in a 404 Not Found response:\n{"errorCode":4040010,"errorMessage":"Transaction id not found."}\n",
My app is currently in review (review completed).
I'm using the Get Transaction info API with a sandbox purchase transaction ID. "x": "Invalid response: Client error: GET https://api.storekit-sandbox.itunes.apple.com/inApps/v1/transactions/2000000632750685 resulted in a 401 Unauthorized response",
However, when using the production url
"Invalid response: Client error: GET https://api.storekit.itunes.apple.com/inApps/v1/transactions/2000000632750685 resulted in a 404 Not Found response:\n{"errorCode":4040010,"errorMessage":"Transaction id not found."}\n",
Should I generate my JWT differently for sandbox vs production? If not, what else could cause this issue?
Is there any missing congigration?
Hello everyone!
By the guidelines we have to use IAP because actual service happens in the application itself: it is an app for scheduling actions. The business problem is that IAP does not allow the refund functionality which is important in-app in case the actual scheduled action will not happen.
Is there a way to use Stripe still exactly cos we need to implement refunds in the app?
Hello,
I am encountering an issue where I receive an App Store Server Notification V2 upon the purchase of a consumable item.
I have configured the App Store Server Notification V2 endpoint to handle notifications related to subscription products.
However, I did not expect to receive notifications for consumable purchases.
The notification includes the following signedPayload decoded into the ResponseBodyV2DecodedPayload object with the following values:
notificationUUID: 3cd6410b-0c89-4247-aba5-20710e79895e
notificationType: null
subtype: null
The transaction information decoded from the ResponseBodyV2DecodedPayload object is as follows:
transactionId: 2000000633622618
webOrderLineItemId: null
productId: heart_2
To debug, I called the Get Notification History API of the App Store Server API, and the mentioned notification for the consumable product purchase is not included in the history. Only notifications related to subscription product purchases are retrieved.
According to the notification type documentation, there is no explanation for cases where both notificationType and subtype are null, nor is there any mention of receiving notifications for consumable purchases. Therefore, I am uncertain how to interpret and handle this notification.
Could you please provide an explanation or guidance on this issue?
Thank you.
References:
https://developer.apple.com/forums/thread/737592
https://developer.apple.com/documentation/appstoreservernotifications/notificationtype