> ## 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.

# XGameUiShowWebAuthenticationResultSize

> XGameUiShowWebAuthenticationResultSize

# XGameUiShowWebAuthenticationResultSize

Retrieves the size of the buffer needed to store a previously completed authentication request. This size is variable because the server response can contain an arbitrary amount of data.

## Syntax

```cpp theme={null}
HRESULT XGameUiShowWebAuthenticationResultSize(  
         XAsyncBlock* async,  
         size_t* bufferSize  
)  
```

### Parameters

*async*   \_Inout\_\
Type: [XAsyncBlock\*](/reference/system/xasync/structs/xasyncblock)

A pointer to the [XAsyncBlock](/reference/system/xasync/structs/xasyncblock) that was passed to [XGameUiShowWebAuthenticationAsync](/reference/system/xgameui/functions/xgameuishowwebauthenticationasync).

*bufferSize*   \_Out\_\
Type: size\_t\*

The size, in bytes, of the [XGameUiWebAuthenticationResultData](/reference/system/xgameui/structs/xgameuiwebauthenticationresultdata) returned from the [XGameUiShowWebAuthenticationAsync](/reference/system/xgameui/functions/xgameuishowwebauthenticationasync) call.

### Return value

Type: HRESULT

HRESULT success or error code.

## Remarks

Call this method inside the *AsyncBlock* callback or after the *AsyncBlock* is complete. You must call this method so that you can allocate a buffer of sufficient size to contain the result data returned in [XGameUiShowWebAuthenticationResult](/reference/system/xgameui/functions/xgameuishowwebauthenticationresult).

For an example of how to use this method, see the code example in [XGameUiShowWebAuthenticationAsync](/reference/system/xgameui/functions/xgameuishowwebauthenticationasync).

## Requirements

**Header:** XGameUI.h

**Library:** xgameruntime.lib

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

## See also

[XGameUI](/reference/system/xgameui/xgameui_members)\
[XGameUiShowWebAuthenticationAsync](/reference/system/xgameui/functions/xgameuishowwebauthenticationasync)\
[XGameUiShowWebAuthenticationResult](/reference/system/xgameui/functions/xgameuishowwebauthenticationresult)\
[XGameUiWebAuthenticationResultData](/reference/system/xgameui/structs/xgameuiwebauthenticationresultdata)\
[Asynchronous Programming Model](/build/core-features/common/async/async-programming-model)


## Related topics

- [XGameUiShowWebAuthenticationResult](/reference/system/xgameui/functions/xgameuishowwebauthenticationresult.md)
- [XGameUiShowWebAuthenticationAsync](/reference/system/xgameui/functions/xgameuishowwebauthenticationasync.md)
- [XGameUiShowWebAuthenticationWithOptionsAsync](/reference/system/xgameui/functions/xgameuishowwebauthenticationwithoptionsasync.md)
- [XGameUiWebAuthenticationResultData](/reference/system/xgameui/structs/xgameuiwebauthenticationresultdata.md)
- [XGameUiWebAuthenticationOptions](/reference/system/xgameui/enums/xgameuiwebauthenticationoptions.md)
