简体   繁体   中英

How to get a unique userid in Microsoft Store API

I use the Microsoft Store API (henceforth "API) for enable user for in-app purchases (Addons).

For example...

public StoreContext storeContext = StoreContext.GetDefault();
GetAppLicenseAsync();
GetAssociatedStoreProductsAsync

...etc...

I have two questions:

  1. Is there an API that lets us identify the unique user; preferably the email id or GUID used by the Store to uniquely identify the user?

  2. The API allows determination of user's currently owned Addons. Is there a way to determine a users past history of Addon ownership?

I have found GetUserCollectionAsync() but it only reflects user's current active purchased Addons. Expired Addons do not appear in this list.

Thank you for your advice.

Is there an API that lets us identify the unique user; preferably the email id or GUID used by the Store to uniquely identify the user?

No, UWP doesn't have APIs to do this.

The API allows determination of user's currently owned Addons. Is there a way to determine a users past history of Addon ownership?

No, the StoreContext class does not provide methods that could check user history of addons.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM