Get Purchase History / Restore Purchases
Get Purchase History
You must be able to restore your users purchases at the click of a button. This is an iOS App Store policy.


A quick note on the blocks above. users have asked where the individualPurchaes variable comes from.
Get purchase history step-by-step
First show the hider to block user interaction, then call Get Purchase History

List of Purchase info
will output a list of objects that are formatted like this:
[{
purchaseTime:234234234234, //this will be Epoch time in miliseconds
originalPurchaseTime:23423423423423, //this value is formatted as above
purchaseState: 2,
orderId:"adsfasfdf",
originalOrderId:"232adfa",
acknowledged: true,
productId:"YOUR_PRODUCT_IDs_WILL_BE_HERE",
transactionReceipt:"THIS_IS_A_VERY_LONG_STRING"
}]
[{
purchaseTime:234234234234, //this will be Epoch time in miliseconds
originalPurchaseTime:23423423423423, //this value is formatted as above
purchaseState: 2,
orderId:"adsfasfdf",
originalOrderId:"232adfa",
acknowledged: true,
productId:"YOUR_PRODUCT_IDs_WILL_BE_HERE",
transactionReceipt:"THIS_IS_A_VERY_LONG_STRING"
}]
Last updated
Was this helpful?