Skip to main content
Question

Regarding payment status after purchase or subscribe

  • 1 October 2024
  • 1 reply
  • 20 views

Forum|alt.badge.img

I am using RevenueCat for in-app purchases in my Ionic Capacitor React app. I have a question regarding the scenario when a user purchases or subscribes to a plan. If the payment enters a pending state, how can I check whether the payment was eventually successful or failed?

And also how i am check if the user are not cancel their subscription after plan purchase.

This post has been closed for comments

1 reply

joan-cardona
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • 187 replies
  • October 3, 2024

Hi @nishi,

The payment shouldn’t enter a pending state - it’s only successful when the funds have been retrieved correctly. Our SDK throws error messages in case anything goes wrong during the transaction so make sure to handle those cases.

If you set up our webhooks, you can get notified of every single change in the subscription state. You can also always check in the SDK if a user has an active subscription or not.
 

if (Object.entries(customerInfo.entitlements.active).length) {
  //user has access to some entitlement
}

Best,


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings