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

# PFAccountManagementClientLinkTwitchAsync

> Links the Twitch account associated with the token to the user's PlayFab account.

Links the Twitch account associated with the token to the user's PlayFab account.

## Syntax

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

### Parameters

**`entityHandle`**   PFEntityHandle

PFEntityHandle to use for authentication.

**`request`**   [PFAccountManagementLinkTwitchAccountRequest\*](/services/playfab/api-references/c/pfaccountmanagementtypes/structs/pfaccountmanagementlinktwitchaccountrequest)

Populated request object.

**`async`**   XAsyncBlock\*<br />*Inout*

XAsyncBlock for the async operation.

### Return value

Type: HRESULT

Result code for this API operation.

## Remarks

This API is available on Win32, Linux, and macOS. See also ClientLoginWithTwitchAsync, ClientUnlinkTwitchAsync. Call XAsyncGetStatus to get the status of the operation. If the service call is unsuccessful, the async result will be E\_PF\_ACCOUNT\_ALREADY\_LINKED, E\_PF\_FEATURE\_NOT\_CONFIGURED\_FOR\_TITLE, E\_PF\_INVALID\_TWITCH\_TOKEN, E\_PF\_LINKED\_ACCOUNT\_ALREADY\_CLAIMED, E\_PF\_TWITCH\_RESPONSE\_ERROR or any of the global PlayFab Service errors. See doc page "Handling PlayFab Errors" for more details on error handling.

## Requirements

**Header:** PFAccountManagement.h

## See also

[PFAccountManagement members](/services/playfab/api-references/c/pfaccountmanagement/pfaccountmanagement_members)
