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

# PFAuthenticationServerLoginWithCustomIDAsync

> タイトルによって生成されたカスタムの一意識別子を使用してユーザーをサインインさせ、認証済みユーザーを必要とする以降の API 呼び出しで使用できるセッション識別子を返します

タイトルによって生成されたカスタムの一意識別子を使用してユーザーをサインインさせ、認証済みユーザーを必要とする以降の API 呼び出しで使用できるセッション識別子を返します

## 構文

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

### パラメーター

**`serviceConfigHandle`**   PFServiceConfigHandle

PFServiceConfigCreateHandle 呼び出しから返される PFServiceConfigHandle。

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

サービス リクエストの認証に使用するタイトル シークレット キー。

**`request`**   [PFAuthenticationServerLoginWithCustomIDRequest\*](/ja-jp/services/playfab/api-references/c/pfauthenticationtypes/structs/pfauthenticationserverloginwithcustomidrequest)

値が設定されたリクエスト オブジェクト。

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

非同期操作用の XAsyncBlock。

### 戻り値

型: HRESULT

この API 操作の結果コード。

## 解説

この API は Windows で利用できます。開発者は、顧客が別の顧客によって既に使用されている ID を生成する可能性が極めて低くなるようにすることを強くお勧めします。ユーザーがこの Custom ID で初めてサインインし、CreateAccount が true に設定されている場合は、新しい PlayFab アカウントが作成され、Custom ID にリンクされます。この場合、PlayFab アカウントにはメールアドレスやユーザー名は関連付けられません。それ以外の場合、Custom ID に PlayFab アカウントがリンクされていなければ、そのことを示すエラーが返されるため、タイトルはユーザーに PlayFab アカウントの作成を案内できます。非同期タスクが完了したら、[PFAuthenticationServerLoginWithCustomIDGetResult](/ja-jp/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithcustomidgetresult) を呼び出して結果を取得します。

## 要件

**ヘッダー:** PFAuthentication.h

## 関連項目

[PFAuthentication のメンバー](/ja-jp/services/playfab/api-references/c/pfauthentication/pfauthentication_members)


## Related topics

- [PFAuthenticationServerLoginWithCustomIDGetResultSize](/ja-jp/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithcustomidgetresultsize.md)
- [PFAuthenticationServerLoginWithCustomIDGetResult](/ja-jp/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithcustomidgetresult.md)
- [PFAuthenticationServerLoginWithServerCustomIdAsync](/ja-jp/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithservercustomidasync.md)
- [PFAuthenticationServerLoginWithServerCustomIdGetResult](/ja-jp/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithservercustomidgetresult.md)
- [PFAuthenticationServerLoginWithServerCustomIdGetResultSize](/ja-jp/services/playfab/api-references/c/pfauthentication/functions/pfauthenticationserverloginwithservercustomidgetresultsize.md)
