Freigeben über


RestUserTokenClient Class

Definition

Client for OAuth flow using the TokenAPI endpoints. This uses the Azure Bot Service Token Service to facilitate the token exchange.

public class RestUserTokenClient : Microsoft.Agents.Connector.RestClients.RestClientBase, IDisposable, Microsoft.Agents.Connector.IUserTokenClient
type RestUserTokenClient = class
    inherit RestClientBase
    interface IUserTokenClient
    interface IDisposable
Public Class RestUserTokenClient
Inherits RestClientBase
Implements IDisposable, IUserTokenClient
Inheritance
RestUserTokenClient
Implements

Constructors

RestUserTokenClient(String, Uri, IHttpClientFactory, Func<Task<String>>, String, ILogger)

Properties

BaseUri
Endpoint (Inherited from RestClientBase)

Methods

CreateTokenExchangeState(String, String, IActivity)

Helper function to create the base64 encoded token exchange state used in GetSignInResourceAsync calls.

Dispose()
ExchangeTokenAsync(String, String, ChannelId, TokenExchangeRequest, CancellationToken)

Performs a token exchange operation such as for single sign-on.

GetAadTokensAsync(String, String, String[], ChannelId, CancellationToken)

Retrieves Azure Active Directory tokens for particular resources on a configured connection.

GetHttpClientAsync() (Inherited from RestClientBase)
GetSignInResourceAsync(String, IActivity, String, CancellationToken)

Get the raw signin link to be sent to the user for signin for a connection name.

GetTokenOrSignInResourceAsync(String, IActivity, String, String, String, CancellationToken)

Get the token or sign in resource for a user.

GetTokenStatusAsync(String, ChannelId, String, CancellationToken)

Retrieves the token status for each configured connection for the given user.

GetUserTokenAsync(String, String, ChannelId, String, CancellationToken)

Attempts to retrieve the token for a user that's in a login flow.

SignOutUserAsync(String, String, ChannelId, CancellationToken)

Signs the user out with the token server.

Applies to