qonversion/unity-sdk

CheckEntitlements returns past already consumed purchases

Opened this issue · 11 comments

In our app we offer only consumable purchases.

At the start of the app once the purchases/products are loaded we call Qonversion.GetSharedInstance().CheckEntitlements() since this is what is in the documentation:
You need to call the checkEntitlements() method at the start of your app to check if a user has the required entitlement. This method will check the user's receipt and return current entitlements.
This returns already consumed purchases and their entitlements.

Note that I did not verify the boolean value of IsActive of the returned entitlement.

As far as I know consumable purchase support is still in progress, correct?

@SpertsyanKM tagging you here since you were able to help me before, apologies if this is someone elses territory.

Hello, @WiseKodama.

If you are selling only consumable products, what entitlements do you check in your app? Entitlements are intended for subscriptions and non-consumable in-apps. Can you explain your use-case please?

Hello @SpertsyanKM, great to hear from you again :)

Basically entitlements are cross linked with our products in the dashboard for easier identification after a purchase has completed.

We also needed to use qonversionInstance.UpdatedEntitlementsReceived += OnEntitlementsUpdated; in order to handle pending purchases.

As for the issue at hand we are unsure why it would return already consumed entitlements?
It shows that there is support for consumable purchases: https://hub.qonversion.io/roadmap/consumable-in-apps-support-from-the-sdk

Basically our use cases are:

  • Handle purchase
  • Handle pending purchase(app in background)
  • Handle pending purchase(app killed) -> Purchase should be rewarded upon start if purchase has completed outside app

Currently there is no option to mark a product as consumable in the dashboard.

I'm discussing your case with the team and will return soon

Sorry for the late reply.

While we support consumable in-app purchases, we don't support pending purchases for that type of products. This means you can't identify such a purchase with an updated entitlements listener, cause it doesn't actually grant an entitlement (or the entitlement should also be consumable, but that is not so for now).

In a couple of days, we'll discuss with the team the priority of this feature. As soon as I have any news, I'll share them here.

If you link your in-app product to some entitlement, we will grant a lifetime entitlement for the purchase of that product (no matter it is consumable or not) - that is the expected behavior for now. That is why you receive an entitlement for the consumed purchase

Apologies for the slow response @SpertsyanKM

Are there any plans to make Qonversion work with Consumable purchases that will also cover pending/out-of-app purchases?

Yes, we plan to implement this feature by the end of this year.

Hey @SpertsyanKM 👋
Any chance there is an issue/task tracker for non-subscription purchases support?

Hi @WiseKodama,

I think, you can follow this feature request in our hub.

Hey @SpertsyanKM

I see that the feature is still marked as Under consideration.
Will it make it to release this year?