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

# PFInventoryPurchaseInventoryItemsAsync

> Purchase an item or bundle. Up to 10,000 stacks of items can be added to a single inventory collection. Stack size is uncapped.

Purchase an item or bundle. Up to 10,000 stacks of items can be added to a single inventory collection. Stack size is uncapped.

## Syntax

```cpp theme={null}
HRESULT PFInventoryPurchaseInventoryItemsAsync(  
    PFEntityHandle entityHandle,  
    const PFInventoryPurchaseInventoryItemsRequest* request,  
    XAsyncBlock* async  
)  
```

### Parameters

**`entityHandle`**   PFEntityHandle

PFEntityHandle to use for authentication.

**`request`**   [PFInventoryPurchaseInventoryItemsRequest\*](https://docs.xbox.com/services/playfab/api-references/c/pfinventorytypes/structs/pfinventorypurchaseinventoryitemsrequest.md)

Populated request object.

**`async`**   XAsyncBlock\*\
*Inout*

XAsyncBlock for the async operation.

### Return value

Type: HRESULT

Result code for this API operation.

## Remarks

This API is available on all platforms. Purchase a single item or bundle, paying the associated price. When the asynchronous task is complete, call [PFInventoryPurchaseInventoryItemsGetResultSize](https://docs.xbox.com/services/playfab/api-references/c/pfinventory/functions/pfinventorypurchaseinventoryitemsgetresultsize.md) and [PFInventoryPurchaseInventoryItemsGetResult](https://docs.xbox.com/services/playfab/api-references/c/pfinventory/functions/pfinventorypurchaseinventoryitemsgetresult.md) to get the result.

## Requirements

**Header:** PFInventory.h

## See also

[PFInventory members](https://docs.xbox.com/services/playfab/api-references/c/pfinventory/pfinventory_members.md)


## Related topics

- [PFInventoryPurchaseInventoryItemsGetResult](https://docs.xbox.com/services/playfab/api-references/c/pfinventory/functions/pfinventorypurchaseinventoryitemsgetresult.md)
- [Services C API overview - PFInventory.h](https://docs.xbox.com/services/playfab/api-references/c/pfinventory/pfinventory_members.md)
- [Purchase Inventory Items](https://docs.xbox.com/services/playfab/api-references/rest/economy/inventory/purchase-inventory-items.md)
- [PFInventoryPurchaseInventoryItemsRequest](https://docs.xbox.com/services/playfab/api-references/c/pfinventorytypes/structs/pfinventorypurchaseinventoryitemsrequest.md)
- [PFInventoryPurchaseInventoryItemsOperation](https://docs.xbox.com/services/playfab/api-references/c/pfinventorytypes/structs/pfinventorypurchaseinventoryitemsoperation.md)
