语言

ChannelServiceHandlerBase.OnGetConversationMemberAsync 方法

定义

技能 API 获取 GetConversationMember()

protected virtual System.Threading.Tasks.Task<Microsoft.Bot.Schema.ChannelAccount> OnGetConversationMemberAsync(System.Security.Claims.ClaimsIdentity claimsIdentity, string userId, string conversationId, System.Threading.CancellationToken cancellationToken = default);
abstract member OnGetConversationMemberAsync : System.Security.Claims.ClaimsIdentity * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Bot.Schema.ChannelAccount>
override this.OnGetConversationMemberAsync : System.Security.Claims.ClaimsIdentity * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Bot.Schema.ChannelAccount>
Protected Overridable Function OnGetConversationMemberAsync (claimsIdentity As ClaimsIdentity, userId As String, conversationId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ChannelAccount)

参数

claimsIdentity
ClaimsIdentity

机器人的 claimsIdentity 应具有 AudienceClaim、AppIdClaim 和 ServiceUrlClaim。

userId
String

用户 ID。

conversationId
String

对话 ID。

cancellationToken
CancellationToken

取消令牌。

返回

响应的任务。

注解

覆盖此方法以获取单个对话成员的账户。

该 REST API 会接收 ConversationId 和 UserId,返回代表对话成员的 ChannelAccount 对象。

适用于