> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XStoreGameLicense

> XStoreGameLicense

# XStoreGameLicense

Describes a game license.

## Syntax

```cpp theme={null}
typedef struct XStoreGameLicense {  
    char skuStoreId[STORE_SKU_ID_SIZE];  
    bool isActive;  
    bool isTrialOwnedByThisUser;  
    bool isDiscLicense;  
    bool isTrial;  
    uint32_t trialTimeRemainingInSeconds;  
    char trialUniqueId[TRIAL_UNIQUE_ID_MAX_SIZE];  
    time_t expirationDate;  
} XStoreGameLicense  
```

### Members

*skuStoreId*\
Type: char\[STORE\_SKU\_ID\_SIZE]

The store ID.

*isActive*\
Type: bool

Indicates whether the license is active.

*isTrialOwnedByThisUser*\
Type: bool

Indicates whether the trial is owned by the user associated to the XStoreContext. If on PC, this will be the currently signed in user to the Microsoft Store App.

*isDiscLicense*\
Type: bool

Indicates whether the license is a disc license.

*isTrial*\
Type: bool

Indicates whether the license is a trial license.

*trialTimeRemainingInSeconds*\
Type: uint32\_t

Amount of time remaining for the trial license.

*trialUniqueId*\
Type: char\[TRIAL\_UNIQUE\_ID\_MAX\_SIZE]

The unique ID for the trial.

*expirationDate*\
Type: time\_t

Expiration date of the license.

## Remarks

To acquire the game license call [XStoreQueryGameLicenseAsync](/reference/system/xstore/functions/xstorequerygamelicenseasync). You will find the license returned in its result function [XStoreQueryGameLicenseResult](/reference/system/xstore/functions/xstorequerygamelicenseresult). **XStoreGameLicense** is an output parameter of [XStoreQueryGameLicenseResult](/reference/system/xstore/functions/xstorequerygamelicenseresult).

## Requirements

**Header:** XStore.h (included in XGameRuntime.h)

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

## Conceptual documentation

* [Implementing Trials for your game](/publishing/xstore-commerce/xstore-trials)

## See also

[XStore](/reference/system/xstore/xstore_members)\
[XStoreQueryGameLicenseAsync](/reference/system/xstore/functions/xstorequerygamelicenseasync)\
[XStoreQueryGameLicenseResult](/reference/system/xstore/functions/xstorequerygamelicenseresult)


## Related topics

- [XStoreQueryGameLicenseResult](/reference/system/xstore/functions/xstorequerygamelicenseresult.md)
- [XStore](/reference/system/xstore/xstore_members.md)
- [Implementing Trials for your game](/publishing/xstore-commerce/xstore-trials.md)
- [Basic DRM and license checks](/publishing/xstore-commerce/xstore-basic-drm.md)
- [Detect XBOX Game Pass subscription access from your service](/publishing/xstore-commerce/xstore-detecting-game-pass.md)
