I just implemented this new iap api. I can now easily see the required ‘expires_date’ of my subscription.
I have one note!
When I buy a subscription and request the receipt, with store.receiptDecrypted(). I see in the recept’s field ‘in_app’ the complete history of all the subscriptions i bought in the past. In my case I see 60 entries (in the sanbox environment). The last entry is the one I need. I kind of expected just 1 entry in ‘in_app’ field.
But when I do a restore, I get all 60 transaction in restore state. All these 60 transaction again have 60 entries in the ‘in_app’ field, if I request the receipt. This seems a bit too much to me. But good usable. I just need the last entry in ‘in_app’ from the last transaction.
is this intended behavior?
I kind of remember from many years ago on x-code. I also saw much redundant data when working with receipts and restores. But I am not sure anymore.