in-app-purchase

Expo in-app-purchases: ReferenceError: Can't find variable: connectAsync

和自甴很熟 提交于 2021-01-29 09:22:31
问题 I'm trying to follow along with expo's in app purchases documentation.. I have the android developer account and set up my in-app-purchase on that account for the same app. I'm just trying to get started with the documentation and receive an error immediately. If you look at the documentation, I'm just trying to enter in what's in the first example. I call this function at the beginning of the render method of my app. import * as InAppPurchases from 'expo-in-app-purchases'; ... const

Google In App Billing differentiate user accounts

旧巷老猫 提交于 2021-01-29 06:12:13
问题 I'm developing an app that contains In App Billing non consumable product (Life time Subscription). User has one email associated with Play Store on his device. Scenario: User A create new account using user1@test.com and purchase Lifetime Subscription and logout. User B create new account using user2@test.com and trying to purchase. but he get response BillingClient.BillingResponse.ITEM_ALREADY_OWNED . How do i differ each user to buy item? I'm using 'com.android.billingclient:billing:2.2.1'

updatedTransactions(transactionState == .restored) vs paymentQueueRestoreCompletedTransactionsFinished

怎甘沉沦 提交于 2021-01-29 03:19:19
问题 As the title describes, what is the actual different? If I have this: func paymentQueue(_ queue: SKPaymentQueue, updatedTransactions transactions: [SKPaymentTransaction]) { for transaction in transactions { if transaction.transactionState == .purchased { } else if transaction.transactionState == .failed { } else if transaction.transactionState == .restored { // <- This one } } Do I still need to use this (if yes, what code to use here, and what code in transactionState == .restored ?: func

How to restore in-app purchases correctly?

半世苍凉 提交于 2021-01-27 14:23:16
问题 I have a few in-app purchases. However, I read I need to provide a way to restore them in case that they delete my application by accident. They are nonconsumable items, like skins and textures. I was reading a tutorial on this site: https://code.tutsplus.com/tutorials/in-app-purchase-tutorial-with-swift-3-ios-sdk--cms-27595 However, their explanation of restoring transactions confused me. They did this: @IBAction func restorePurchaseButt(_ sender: Any) { SKPaymentQueue.default().add(self)

Swift: IAP updatedTransactions not called on .Purchased

a 夏天 提交于 2021-01-27 04:55:28
问题 I have a problem with my code. The function updatedTransactions is only called once while the transaction is .Purchasing and is not called after the transaction has ben completed. func buyProduct(product: SKProduct) { let payment = SKPayment(product: product) SKPaymentQueue.defaultQueue().addTransactionObserver(self) SKPaymentQueue.defaultQueue().addPayment(payment) } func paymentQueue(queue: SKPaymentQueue, updatedTransactions transactions: [SKPaymentTransaction]) { for transaction in

SKProductsRequest does not return SKProductsResponse in Catalyst app

混江龙づ霸主 提交于 2021-01-25 07:06:28
问题 I have an existing iOS app that contains in-app purchases. I've done the following to port it to macoS, built in Xcode by adding Mac as a target. added a macOS platform to the existing app on App Store Connect. I did not upload a macOS version yet. completely log out of App Store. run app from Finder. I also tested running from the command line to see if there were any console messages that popped up. As you can imagine, I create an SKProductsRequest object and call start(). Whereas the iOS

Android - In App Purchase - you need to add the BILLING permission to your APK

笑着哭i 提交于 2021-01-20 14:39:48
问题 I have been facing a IN - App Purchase problem since long time. I need to integrate In-App functionality in my Android Application, but When I upload the APK file to the play store, it does not allow me to add SKU values. To add in-app products, you need to add the BILLING permission to your APK I have been added "com.android.vending.BILLING" permission in manifest file 1. I downloaded TRIVAL-DRIVER project. 2. Create a new library Project "BILLLING LIBRARY" with my Custom package name eg:

Android - In App Purchase - you need to add the BILLING permission to your APK

浪子不回头ぞ 提交于 2021-01-20 14:37:31
问题 I have been facing a IN - App Purchase problem since long time. I need to integrate In-App functionality in my Android Application, but When I upload the APK file to the play store, it does not allow me to add SKU values. To add in-app products, you need to add the BILLING permission to your APK I have been added "com.android.vending.BILLING" permission in manifest file 1. I downloaded TRIVAL-DRIVER project. 2. Create a new library Project "BILLLING LIBRARY" with my Custom package name eg:

Unable to display in app purchase product data in android

我的梦境 提交于 2021-01-07 06:58:05
问题 So far I'm able to receive my product information for an iOS device but not Android. Here is my code in the component module: registerProduct() { this.inAppPurchase.verbosity = this.inAppPurchase.DEBUG; this.inAppPurchase.register({ id: 'android.prod', type: this.inAppPurchase.NON_CONSUMABLE }); this.registerHandlersForPurchase('android.prod'); this.inAppPurchase.refresh(); } registerHandlersForPurchase(productId) { const self = this.inAppPurchase; this.inAppPurchase.when(productId).updated(

IOS:Auto renewable In App Purchase server to server notification parsing issue

懵懂的女人 提交于 2021-01-07 02:53:57
问题 I am unable to parse app store auto renewable purchase notification.I am only to get notification_type, but other fileds i am unable parse from server notification. my php code: <?php $input =json_decode(file_get_contents('php://input'), true); $responseBody = $input['unified_receipt']['latest_receipt_info'][0]->original_transaction_id; $notification_type = $input['notification_type']; $sql="INSERT INTO testAppServerNotification (notification_type,notification) VALUES('$notification_type','