-
-
Notifications
You must be signed in to change notification settings - Fork 534
[IOS] Function to get the on-device receipt #1170
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
On-device parsing of the receipt payload is something I figure I now need and this plugin doesn't currently support. The plugin currently returns the app receipt (including the payload) as base64-encoded binary. However, as outlined in Apple's Restoring Purchased Products documentation, you may need to parse the receipt payload on the device to determine which products a user owns:
Since as stated in that document, you should not automatically invoke a restore operation to determine a user's owned products:
Particularly since this creates new transactions for each owned product:
Whereas refreshing the receipt does not:
Apple's example of parsing the receipt payload in the Receipt Validation Programming Guide is not great but I might try to figure it out and in which case make a PR to this plugin to return the decoded receipt payload back the to JS layer as JSON. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
My team is looking at migrating to this plugin from cordova-plugin-inapppurchase, as this one is still actively maintained and is compatible with Google's Billing Library v3.
One function that seems to be missing from this plugin however is the ability to get the local receipt on an iOS device. We use this functionality in our own app as part of verifying the user's identity, as we need to tie purchases to specific accounts and Apple doesn't easily provide us this information. It would be great if it could be included in this plugin as well!
I could have simply missed a way to do this as part of the existing plugin functionality though, in which case I'm open to suggestions.
The text was updated successfully, but these errors were encountered: