Compartir a través de


IConversations.ReplyToActivityWithHttpMessagesAsync Método

Definición

Sobrecargas

ReplyToActivityWithHttpMessagesAsync(String, String, Activity, Dictionary<String,List<String>>, CancellationToken)

ReplyToActivity.

ReplyToActivityWithHttpMessagesAsync(String, String, Activity, Dictionary<String,List<String>>, CancellationToken)

ReplyToActivityWithHttpMessagesAsync(String, String, Activity, Dictionary<String,List<String>>, CancellationToken)

ReplyToActivity.

public System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Bot.Schema.ResourceResponse>> ReplyToActivityWithHttpMessagesAsync (string conversationId, string activityId, Microsoft.Bot.Schema.Activity activity, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = default, System.Threading.CancellationToken cancellationToken = default);
abstract member ReplyToActivityWithHttpMessagesAsync : string * string * Microsoft.Bot.Schema.Activity * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Bot.Schema.ResourceResponse>>
Public Function ReplyToActivityWithHttpMessagesAsync (conversationId As String, activityId As String, activity As Activity, Optional customHeaders As Dictionary(Of String, List(Of String)) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of HttpOperationResponse(Of ResourceResponse))

Parámetros

conversationId
String

Identificador de conversación.

activityId
String

activityId a la respuesta es (OPCIONAL).

activity
Activity

Actividad que se va a enviar.

customHeaders
Dictionary<String,List<String>>

Encabezados que se agregarán a la solicitud.

cancellationToken
CancellationToken

Token de cancelación.

Devoluciones

Task<Microsoft.Rest.HttpOperationResponse<ResourceResponse>>

Tarea que representa .Microsoft.Rest.HttpOperationResponse

Excepciones

Se produce cuando la operación devolvió un código de estado no válido.

Microsoft.Rest.SerializationException

Se produce cuando no se puede deserializar la respuesta.

Microsoft.Rest.ValidationException

Se produce cuando un parámetro obligatorio es NULL.

Comentarios

Este método permite responder a una actividad.

Esto es ligeramente diferente de SendToConversation(). * SendToConversation(conversationId): anexará la actividad al final de la conversación según la marca de tiempo o la semántica del canal. * ReplyToActivity(conversationId,ActivityId): agrega la actividad como respuesta a otra actividad, si el canal lo admite. Si el canal no admite respuestas anidadas, ReplyToActivity vuelve a SendToConversation.

Use ReplyToActivity al responder a una actividad específica de la conversación.

Use SendToConversation en todos los demás casos.

Se aplica a

ReplyToActivityWithHttpMessagesAsync(String, String, Activity, Dictionary<String,List<String>>, CancellationToken)

public System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Bot.Connector.ResourceResponse>> ReplyToActivityWithHttpMessagesAsync (string conversationId, string activityId, Microsoft.Bot.Connector.Activity activity, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = default, System.Threading.CancellationToken cancellationToken = default);
abstract member ReplyToActivityWithHttpMessagesAsync : string * string * Microsoft.Bot.Connector.Activity * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Bot.Connector.ResourceResponse>>
Public Function ReplyToActivityWithHttpMessagesAsync (conversationId As String, activityId As String, activity As Activity, Optional customHeaders As Dictionary(Of String, List(Of String)) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of HttpOperationResponse(Of ResourceResponse))

Parámetros

conversationId
String
activityId
String
activity
Activity
customHeaders
Dictionary<String,List<String>>
cancellationToken
CancellationToken

Devoluciones

Task<Microsoft.Rest.HttpOperationResponse<ResourceResponse>>

Se aplica a