UserTokenClient.ExchangeTokenAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Exchanges a token for another token.
public virtual System.Threading.Tasks.Task<Microsoft.Teams.Core.GetTokenResult> ExchangeTokenAsync(string userId, string connectionName, string channelId, string? exchangeToken, Microsoft.Teams.Core.Http.BotRequestContext? requestContext = default, System.Threading.CancellationToken cancellationToken = default);
abstract member ExchangeTokenAsync : string * string * string * string * Microsoft.Teams.Core.Http.BotRequestContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Teams.Core.GetTokenResult>
override this.ExchangeTokenAsync : string * string * string * string * Microsoft.Teams.Core.Http.BotRequestContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Teams.Core.GetTokenResult>
Public Overridable Function ExchangeTokenAsync (userId As String, connectionName As String, channelId As String, exchangeToken As String, Optional requestContext As BotRequestContext = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of GetTokenResult)
Parameters
- userId
- String
The user ID.
- connectionName
- String
The connection name.
- channelId
- String
The channel ID.
- exchangeToken
- String
The token to exchange.
- requestContext
- BotRequestContext
Optional per-request properties used for authentication.
- cancellationToken
- CancellationToken
The cancellation token.