DeviceCodeClient class

OAuth2.0 デバイス コード クライアント

Extends
@azure/msal-common.BaseClient

コンストラクター

DeviceCodeClient(ClientConfiguration)

継承されたプロパティ

authority
logger

メソッド

acquireToken(CommonDeviceCodeRequest)

デバイス コード エンドポイントからデバイス コードを取得し、デバイス コード応答で呼び出しを行い、トークン エンドポイントをポーリングしてデバイス コードをトークンと交換します

createExtraQueryParameters(CommonDeviceCodeRequest)

デバイス コード要求のクエリ文字列を作成します

継承されたメソッド

createTokenQueryParameters(BaseAuthRequest)

/token 要求のクエリ文字列を作成します

sendPostRequest<T>(RequestThumbprint, string, NetworkRequestOptions, string)

必要なプレフライトおよびポストフライト ロジックで sendPostRequestAsync をラップします

updateAuthority(string, string)

クライアントの authority オブジェクトを更新します。 エンドポイントの検出を完了する必要があります。

コンストラクターの詳細

DeviceCodeClient(ClientConfiguration)

new DeviceCodeClient(configuration: ClientConfiguration)

パラメーター

configuration
@azure/msal-common.ClientConfiguration

継承されたプロパティの詳細

authority

authority: Authority

プロパティ値

@azure/msal-common.Authority

Inherited From BaseClient.authority

logger

logger: Logger

プロパティ値

Inherited From BaseClient.logger

メソッドの詳細

acquireToken(CommonDeviceCodeRequest)

デバイス コード エンドポイントからデバイス コードを取得し、デバイス コード応答で呼び出しを行い、トークン エンドポイントをポーリングしてデバイス コードをトークンと交換します

function acquireToken(request: CommonDeviceCodeRequest): Promise<null | AuthenticationResult>

パラメーター

request
CommonDeviceCodeRequest

開発者が提供した CommonDeviceCodeRequest

返品

Promise<null | AuthenticationResult>

createExtraQueryParameters(CommonDeviceCodeRequest)

デバイス コード要求のクエリ文字列を作成します

function createExtraQueryParameters(request: CommonDeviceCodeRequest): string

パラメーター

request
CommonDeviceCodeRequest

開発者が提供した CommonDeviceCodeRequest

返品

string

継承済みメソッドの詳細

createTokenQueryParameters(BaseAuthRequest)

/token 要求のクエリ文字列を作成します

function createTokenQueryParameters(request: BaseAuthRequest): string

パラメーター

request
BaseAuthRequest

返品

string

Inherited From BaseClient.createTokenQueryParameters

sendPostRequest<T>(RequestThumbprint, string, NetworkRequestOptions, string)

必要なプレフライトおよびポストフライト ロジックで sendPostRequestAsync をラップします

function sendPostRequest<T>(thumbprint: RequestThumbprint, tokenEndpoint: string, options: NetworkRequestOptions, correlationId: string): Promise<NetworkResponse<T>>

パラメーター

thumbprint
RequestThumbprint

調整のために拇印を要求する

tokenEndpoint

string

POST を作成するエンドポイント

options
NetworkRequestOptions

POST 要求に含める本文とヘッダー

correlationId

string

テレメトリの CorrelationId

返品

Promise<NetworkResponse<T>>

Inherited From BaseClient.sendPostRequest

updateAuthority(string, string)

クライアントの authority オブジェクトを更新します。 エンドポイントの検出を完了する必要があります。

function updateAuthority(cloudInstanceHostname: string, correlationId: string): Promise<void>

パラメーター

cloudInstanceHostname

string

correlationId

string

返品

Promise<void>

Inherited From BaseClient.updateAuthority