IExtendedUserTokenProvider.GetAadTokensAsync メソッド

定義

カスタマイズされた AppCredentials を使用して、構成された接続上の特定のリソースの Azure Active Directory トークンを取得します。

public System.Threading.Tasks.Task<System.Collections.Generic.Dictionary<string,Microsoft.Bot.Schema.TokenResponse>> GetAadTokensAsync (Microsoft.Bot.Builder.ITurnContext context, Microsoft.Bot.Connector.Authentication.AppCredentials oAuthAppCredentials, string connectionName, string[] resourceUrls, string userId = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAadTokensAsync : Microsoft.Bot.Builder.ITurnContext * Microsoft.Bot.Connector.Authentication.AppCredentials * string * string[] * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.Dictionary<string, Microsoft.Bot.Schema.TokenResponse>>
Public Function GetAadTokensAsync (context As ITurnContext, oAuthAppCredentials As AppCredentials, connectionName As String, resourceUrls As String(), Optional userId As String = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Dictionary(Of String, TokenResponse))

パラメーター

context
ITurnContext

ユーザーとの会話の現在のターンのコンテキスト。

oAuthAppCredentials
AppCredentials

OAuth の AppCredentials。

connectionName
String

このボットで構成された Azure Active Directory 接続の名前。

resourceUrls
String[]

トークンを取得するリソース URL の一覧。

userId
String

トークンを取得するユーザー ID。 null を渡す場合、userId は ITurnContext のアクティビティから取得されます。

cancellationToken
CancellationToken

キャンセル通知を受け取るために他のオブジェクトまたはスレッドで使用できるキャンセル トークン。

戻り値

対応する TokenResponse への resourceUrl の Dictionary。

適用対象