In order to retrieve a list of purchases the user has made use the
getPurchases function. This call will query the store for any purchases the user has made and any valid license information.
This call will return a complete or an error event:
PurchaseEvent.GET_PURCHASES_COMPLETE: Dispatched when successfully retrieve the purchases, the event will contain an array of
Purchaseobjects each describing a user's purchase;
PurchaseEvent.GET_PURCHASES_ERROR: Dispatched when an error occurred.
This appears to only return store managed purchases, such as durable products. Developer managed consumables may not be returned through the
Purchases that relate to a subscription product will have additional information in the
active flag will indicate whether the subscription is currently active. This should always be
true for purchases queried through the
getPurchases() functionality as this only retrieves active purchases.
Additionally for subscription purchases there will be a valid
expirationDate property on the object, indicating when the current billing period for the subscription will end.