react-native-iap icon indicating copy to clipboard operation
react-native-iap copied to clipboard

Subscription Upgrade Issue- CHARGE_PRORATED_PRICE Not Working.

Open Nikhil-MathBud opened this issue 11 months ago • 4 comments

Description I am trying to implement an upgrade subscription plan in my app using CHARGE_PRORATED_PRICE. However, when I attempt to upgrade, the Google payment modal does not open. Instead, I get the following error message:

"Something went wrong on our end. Please try again."

Interestingly, if I use replacementModeAndroid: 3 //(WITHOUT_PRORATION), it works fine and deducts the full amount instead of a prorated price.

When logging the error in the catch block, I see: "Google is indicating that we have some issue connecting to payment."

Expected Behavior The user should get a modal from google play console, that will show the payment details.

Screenshots Image

Environment:

  • react-native-iap": "12.16.2", -react-native": "0.75.3",
  • Platforms :-Real Android device(Android version :- 14)

Additional Context

  • My app is in Internal Testing on Google Play Console.
  • I am logged in as a Test User on Google Play Console and using the same account for test payments.

Nikhil-MathBud avatar Apr 02 '25 12:04 Nikhil-MathBud

Hello, I'm also having same issue at the moment. Have you fixed the issue? It seems like for me this is not a issue caused by code but play console set-up.

blissful-y0 avatar Apr 10 '25 07:04 blissful-y0

I solved the issue by setting the subscription items with different group in Play console. If you want to use replacement mode, the subscription must be in different group.

For example, If you are using Plan A with Group A, and want to use replacement mode and change to Plan B with Group A, the replacement mode is not working. However, if you are using Plan A with Group A and want to change to Plan B with Group B, the replacement mode (proration, etc) will work.

Hope this helps.

blissful-y0 avatar Apr 15 '25 04:04 blissful-y0

ms with different group in Play console. Thanks a lot @blissful-y0 !! Just to clarify — by different group, do you mean creating an entirely new plan under a different subscription group in the Play Console?

Nikhil-MathBud avatar Apr 15 '25 05:04 Nikhil-MathBud

ms with different group in Play console. Thanks a lot @blissful-y0 !! Just to clarify — by different group, do you mean creating an entirely new plan under a different subscription group in the Play Console?

yes, you are correct let me know if you need further help

blissful-y0 avatar Apr 15 '25 06:04 blissful-y0

Hey @blissful-y0, Could you please clarify something? I created different subscriptions, but I have a doubt about the purchaseTokenAndroid field. Should I set the purchaseToken or the product_id? Right now, when I add the product_id, it shows the error: “Something went wrong on our end. Please try again.”

andhac avatar Sep 26 '25 06:09 andhac

Hey @blissful-y0, Could you please clarify something? I created different subscriptions, but I have a doubt about the purchaseTokenAndroid field. Should I set the purchaseToken or the product_id? Right now, when I add the product_id, it shows the error: “Something went wrong on our end. Please try again.”

Hello @andhac, You would set purchaseToken and groupId for purchase

blissful-y0 avatar Sep 30 '25 03:09 blissful-y0

I’m closing all issues reported in versions below 14, as the library now supports the new architecture with NitroModules and has been completely revamped.

hyochan avatar Sep 30 '25 03:09 hyochan