Skip to main content

XStoreDownloadAndInstallPackagesAsync

Downloads and installs the specified store packages.

Syntax

Parameters

storeContextHandle   _In_
Type: XStoreContextHandle
The store context handle for the user returned by XStoreCreateContext. storeIds   _In_z_count_(storeIdsCount)
Type: char**
List of package identifier strings. A package identifier uniquely identifies a package from the Microsoft store. For more information about package identifiers, see Manage and license downloadable content (DLC). storeIdsCount   _In_
Type: size_t
The number of IDs in storeIds. async   _Inout_
Type: XAsyncBlock*
An XAsyncBlock defining the asynchronous work being done. The XAsyncBlock can be used to poll for the call’s status and retrieve call results. See XAsyncBlock for more information.

Return value

Type: HRESULT HRESULT success or error code.

Remarks

To retrieve the download and install result of this function call XStoreDownloadAndInstallPackagesResult after calling this function. To retrieve the number of items downloaded and installed call XStoreDownloadAndInstallPackagesResultCount after calling this function. The result count function is important as it will allow you to determine the appropriate size of array to pass to the result function. When this API is called from a running game, then the downloads will be considered high priority and they will go at the beginning of the queue in the order in which they are specified in the storeIds parameter of this API. The following code snippet shows an example of downloading and installing store packages.

Requirements

Header: XStore.h (included in XGameRuntime.h) Library: xgameruntime.lib Supported platforms: Windows, XBOX One family consoles and XBOX Series consoles

Conceptual documentation

See also

XStore
XStoreDownloadAndInstallPackagesResult
XStoreDownloadAndInstallPackagesResultCount
Last modified on August 20, 2026