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

# PFAuthenticationServerLoginWithBattleNetAsync

> API de servidor que conecta um usuário com um token de identidade do Battle.net, autenticando a solicitação de serviço com uma chave secreta do título. Disponível no Windows.

Conecta o usuário com um token de identidade do Battle.net

## Sintaxe

```cpp theme={null}
HRESULT PFAuthenticationServerLoginWithBattleNetAsync(  
    PFServiceConfigHandle serviceConfigHandle,  
    const char* secretKey,  
    const PFAuthenticationServerLoginWithBattleNetRequest* request,  
    XAsyncBlock* async  
)  
```

### Parâmetros

**`serviceConfigHandle`**   PFServiceConfigHandle

PFServiceConfigHandle retornado pela chamada PFServiceConfigCreateHandle.

**`secretKey`**   char\*<br />*In\_z*

Chave secreta do título usada para autenticar a solicitação de serviço.

**`request`**   [PFAuthenticationServerLoginWithBattleNetRequest\*](/pt-BR/services/playfab/api-references/c/pfauthenticationtypes/structs/pfauthenticationserverloginwithbattlenetrequest)

Objeto de solicitação preenchido.

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

XAsyncBlock para a operação assíncrona.

### Valor de retorno

Tipo: HRESULT

Código de resultado desta operação de API.

## Comentários

Esta API está disponível no Windows. Veja também ServerLinkBattleNetAccountAsync, ServerUnlinkBattleNetAccountAsync. Quando a tarefa assíncrona for concluída, chame [PFAuthenticationServerLoginWithBattleNetGetResult](/pt-BR/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithbattlenetgetresult) para obter o resultado.

## Requisitos

**Cabeçalho:** PFAuthentication.h

## Confira também

[Membros de PFAuthentication](/pt-BR/services/playfab/api-references/c/pfauthentication/pfauthentication_members)


## Related topics

- [PFAuthenticationServerLoginWithBattleNetGetResultSize](/pt-BR/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithbattlenetgetresultsize.md)
- [PFAuthenticationServerLoginWithBattleNetGetResult](/pt-BR/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithbattlenetgetresult.md)
- [Visão geral da API C do Services - PFAuthentication.h](/pt-BR/services/playfab/api-references/c/pfauthentication/pfauthentication_members.md)
- [PFAuthenticationServerLoginWithBattleNetRequest](/pt-BR/services/playfab/api-references/c/pfauthenticationtypes/structs/pfauthenticationserverloginwithbattlenetrequest.md)
- [PFAuthenticationLoginWithBattleNetAsync](/pt-BR/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationloginwithbattlenetasync.md)
