StoreSku
StoreSku
StoreSku
StoreSku
Class
Definition
Provides info for a SKU of a product in the Windows Store.
public : sealed class StoreSku : IStoreSkupublic sealed class StoreSku : IStoreSkuPublic NotInheritable Class StoreSku Implements IStoreSku// You can use this class in JavaScript.
- Attributes
| Device family |
Windows 10 Anniversary Edition (introduced v10.0.14393.0)
|
| API contract |
Windows.Services.Store.StoreContract (introduced v1)
|
Remarks
Products in the Store are organized in a hierarcy of product, SKU, and availability objects. Products are represented by StoreProduct objects. The SKUs for each product are represented by StoreSku objects, and the availabilities for each SKU are represented by StoreAvailability objects. For more information, see In-app purchases and trials.
To access the SKUs for a product, use the Skus property of the StoreProduct for the product in which you are interested.
Properties
Availabilities Availabilities Availabilities Availabilities
Gets the availabilities for the current product SKU. Each product SKU can have one or more availabilities that have different prices.
public : IVectorView<StoreAvailability> Availabilities { get; }public IReadOnlyList<StoreAvailability> Availabilities { get; }Public ReadOnly Property Availabilities As IReadOnlyList<StoreAvailability>// You can use this property in JavaScript.
- Value
- IVectorView<StoreAvailability> IReadOnlyList<StoreAvailability> IReadOnlyList<StoreAvailability> IReadOnlyList<StoreAvailability>
A collection of StoreAvailability objects that represent the availabilities for the current product SKU.
BundledSkus BundledSkus BundledSkus BundledSkus
Gets the list of Store IDs for the apps or add-ons that are bundled with this product SKU.
public : IVectorView<string> BundledSkus { get; }public IReadOnlyList<string> BundledSkus { get; }Public ReadOnly Property BundledSkus As IReadOnlyList<string>// You can use this property in JavaScript.
- Value
- IVectorView<PlatForm::String> IReadOnlyList<string> IReadOnlyList<string> IReadOnlyList<string>
The list of Store IDs for the apps or add-ons that are bundled with this product SKU.
CollectionData CollectionData CollectionData CollectionData
Gets additional data for the current product SKU, if the user has an entitlement to use the SKU.
public : StoreCollectionData CollectionData { get; }public StoreCollectionData CollectionData { get; }Public ReadOnly Property CollectionData As StoreCollectionData// You can use this property in JavaScript.
An object that provides additional data for the current product SKU, if the user has an entitlement to use the SKU.
CustomDeveloperData CustomDeveloperData CustomDeveloperData CustomDeveloperData
Gets the custom developer data string (also called a tag) that contains custom information about the add-on that this product SKU represents. This string corresponds to the value of the Custom developer data field in the properties page for the add-on in the Windows Dev Center dashboard.
public : PlatForm::String CustomDeveloperData { get; }public string CustomDeveloperData { get; }Public ReadOnly Property CustomDeveloperData As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The custom developer data for the add-on.
Remarks
The custom developer data provides a way for developers to associate custom contextual information with an add-on. For more information about setting this value for an add-on, see Enter add-on properties.
Description Description Description Description
Gets the product SKU description from the Windows Store listing.
public : PlatForm::String Description { get; }public string Description { get; }Public ReadOnly Property Description As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The product SKU description from the Windows Store listing.
ExtendedJsonData ExtendedJsonData ExtendedJsonData ExtendedJsonData
Gets complete data for the current product SKU from the Store in JSON format.
public : PlatForm::String ExtendedJsonData { get; }public string ExtendedJsonData { get; }Public ReadOnly Property ExtendedJsonData As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
A JSON-formatted string that contains complete data for the current product SKU from the Store.
Remarks
Use the ExtendedJsonData property to access the complete data for the StoreSku object as a JSON-formatted string in your code. For more information about the structure of the data, see Data schemas for Store products.
- See Also
Images Images Images Images
Gets the images from the Windows Store listing for the product SKU.
public : IVectorView<StoreImage> Images { get; }public IReadOnlyList<StoreImage> Images { get; }Public ReadOnly Property Images As IReadOnlyList<StoreImage>// You can use this property in JavaScript.
- Value
- IVectorView<StoreImage> IReadOnlyList<StoreImage> IReadOnlyList<StoreImage> IReadOnlyList<StoreImage>
A collection of StoreImage objects that represent the images from the Windows Store listing for the product SKU.
IsInUserCollection IsInUserCollection IsInUserCollection IsInUserCollection
Gets a value that indicates whether the current user has an entitlement to use the current product SKU.
public : PlatForm::Boolean IsInUserCollection { get; }public bool IsInUserCollection { get; }Public ReadOnly Property IsInUserCollection As bool// You can use this property in JavaScript.
- Value
- PlatForm::Boolean bool bool bool
True if the current user has an entitlement to use the current product SKU; otherwise, false.
IsSubscription IsSubscription IsSubscription IsSubscription
Gets a value that indicates whether the current product SKU is a subscription with recurring billing. For more information about the subscription, see the SubscriptionInfo property.
Important
Currently, the ability to create subscription add-ons is only available to developers who are participating in an early adoption program. We will make subscription add-ons available to all developer accounts in the future. For more information, see Enable subscription add-ons for your app.
public : PlatForm::Boolean IsSubscription { get; }public bool IsSubscription { get; }Public ReadOnly Property IsSubscription As bool// You can use this property in JavaScript.
- Value
- PlatForm::Boolean bool bool bool
True if the current product SKU is a recurring billing subscription; otherwise, false.
- See Also
IsTrial IsTrial IsTrial IsTrial
Gets a value that indicates whether the current product SKU is a trial SKU.
public : PlatForm::Boolean IsTrial { get; }public bool IsTrial { get; }Public ReadOnly Property IsTrial As bool// You can use this property in JavaScript.
- Value
- PlatForm::Boolean bool bool bool
True if the current product SKU is a trial SKU; otherwise, false.
Language Language Language Language
Gets the language for the data in the Windows Store listing for the product SKU.
public : PlatForm::String Language { get; }public string Language { get; }Public ReadOnly Property Language As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The data in the Windows Store listing for the product SKU.
Price Price Price Price
Gets the price of the default availability for this product SKU.
public : StorePrice Price { get; }public StorePrice Price { get; }Public ReadOnly Property Price As StorePrice// You can use this property in JavaScript.
The price of the default availability for this product SKU.
StoreId StoreId StoreId StoreId
Gets the Store ID of this product SKU.
public : PlatForm::String StoreId { get; }public string StoreId { get; }Public ReadOnly Property StoreId As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The Store ID of this product SKU.
Remarks
The Store ID returned by this property has the format <product Store ID>/<SKU Store ID>, where:
- <product Store ID> is a 12-character alpha-numeric string, such as 9NBLGGH69M0B. This Store ID is available in the Windows Dev Center dashboard page for the app or add-on, and it is returned by the StoreId property of the related StoreProduct object.
- <SKU Store ID> is a 4-character alpha-numeric string that identifies the SKU. An example complete Store ID returned by this property is 9NBLGGH69M0B/000N.
SubscriptionInfo SubscriptionInfo SubscriptionInfo SubscriptionInfo
Gets subscription information for this product SKU, if this product SKU is a subscription with recurring billing. To determine whether this product SKU is a subscription, use the IsSubscription property.
Important
Currently, the ability to create subscription add-ons is only available to developers who are participating in an early adoption program. We will make subscription add-ons available to all developer accounts in the future. For more information, see Enable subscription add-ons for your app.
public : StoreSubscriptionInfo SubscriptionInfo { get; }public StoreSubscriptionInfo SubscriptionInfo { get; }Public ReadOnly Property SubscriptionInfo As StoreSubscriptionInfo// You can use this property in JavaScript.
An object that contains subscription information for this product SKU. If this product SKU is not a recurring billing subscription, this property returns null.
- See Also
Title Title Title Title
Gets the product SKU title from the Windows Store listing.
public : PlatForm::String Title { get; }public string Title { get; }Public ReadOnly Property Title As string// You can use this property in JavaScript.
- Value
- PlatForm::String string string string
The product SKU title from the Windows Store listing.
Videos Videos Videos Videos
Gets the videos from the Windows Store listing for the product SKU.
public : IVectorView<StoreVideo> Videos { get; }public IReadOnlyList<StoreVideo> Videos { get; }Public ReadOnly Property Videos As IReadOnlyList<StoreVideo>// You can use this property in JavaScript.
- Value
- IVectorView<StoreVideo> IReadOnlyList<StoreVideo> IReadOnlyList<StoreVideo> IReadOnlyList<StoreVideo>
A collection of StoreVideo objects that represent the videos from the Windows Store listing for the product SKU.
Methods
GetIsInstalledAsync() GetIsInstalledAsync() GetIsInstalledAsync() GetIsInstalledAsync()
Indicates whether this product SKU is installed on the current device.
public : IAsyncOperation<PlatForm::Boolean> GetIsInstalledAsync()public IAsyncOperation<bool> GetIsInstalledAsync()Public Function GetIsInstalledAsync() As IAsyncOperation( Of bool )// You can use this method in JavaScript.
An asynchronous operation that, on successful completion, returns true if this product SKU is installed on the current device; otherwise, false.
RequestPurchaseAsync() RequestPurchaseAsync() RequestPurchaseAsync() RequestPurchaseAsync()
Requests the purchase of the product SKU and displays the UI that is used to complete the transaction via the Windows Store.
Important
This method must be called on the UI thread.
public : IAsyncOperation<StorePurchaseResult> RequestPurchaseAsync()public IAsyncOperation<StorePurchaseResult> RequestPurchaseAsync()Public Function RequestPurchaseAsync() As IAsyncOperation( Of StorePurchaseResult )// You can use this method in JavaScript.
An asynchronous operation that, on successful completion, returns a StorePurchaseResult object that provides status and error info about the purchase.
If the ErrorCode property of the exception has the value 0x80070578 (ERROR_INVALID_WINDOW_HANDLE), this indicates that the method was not called on the UI thread. If you are calling this method in a desktop application that uses the Desktop Bridge, this can also indicate that you did not configure the StoreContext object to specify which application window is the owner window for modal dialogs shown by this method. For more information, see this article.
- See Also
RequestPurchaseAsync(StorePurchaseProperties) RequestPurchaseAsync(StorePurchaseProperties) RequestPurchaseAsync(StorePurchaseProperties) RequestPurchaseAsync(StorePurchaseProperties)
Requests the purchase of the product SKU and displays the UI that is used to complete the transaction via the Windows Store. This method provides the option to specify additional details for a specific offer within a large catalog of products that are represented by a single listing in the Windows Store, including the product name to display to the user during the purchase.
Important
This method must be called on the UI thread.
public : IAsyncOperation<StorePurchaseResult> RequestPurchaseAsync(StorePurchaseProperties storePurchaseProperties)public IAsyncOperation<StorePurchaseResult> RequestPurchaseAsync(StorePurchaseProperties storePurchaseProperties)Public Function RequestPurchaseAsync(storePurchaseProperties As StorePurchaseProperties) As IAsyncOperation( Of StorePurchaseResult )// You can use this method in JavaScript.
- storePurchaseProperties
- StorePurchaseProperties StorePurchaseProperties StorePurchaseProperties StorePurchaseProperties
An object that specifies additional info for the purchase request, including the product name to display to the user during the purchase.
An asynchronous operation that, on successful completion, returns a StorePurchaseResult object that provides status and error info about the purchase.
If the ErrorCode property of the exception has the value 0x80070578 (ERROR_INVALID_WINDOW_HANDLE), this indicates that the method was not called on the UI thread. If you are calling this method in a desktop application that uses the Desktop Bridge, this can also indicate that you did not configure the StoreContext object to specify which application window is the owner window for modal dialogs shown by this method. For more information, see this article.
- See Also