Partilhar via


ConversationsExtensions.UploadAttachmentAsync Método

Definição

Sobrecargas

UploadAttachmentAsync(IConversations, String, AttachmentData, CancellationToken)
UploadAttachmentAsync(IConversations, String, AttachmentData, CancellationToken)

UploadAttachment.

UploadAttachmentAsync(IConversations, String, AttachmentData, CancellationToken)

public static System.Threading.Tasks.Task<Microsoft.Bot.Connector.ResourceResponse> UploadAttachmentAsync (this Microsoft.Bot.Connector.IConversations operations, string conversationId, Microsoft.Bot.Connector.AttachmentData attachmentUpload, System.Threading.CancellationToken cancellationToken = default);
static member UploadAttachmentAsync : Microsoft.Bot.Connector.IConversations * string * Microsoft.Bot.Connector.AttachmentData * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Bot.Connector.ResourceResponse>
<Extension()>
Public Function UploadAttachmentAsync (operations As IConversations, conversationId As String, attachmentUpload As AttachmentData, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ResourceResponse)

Parâmetros

operations
IConversations
conversationId
String
attachmentUpload
AttachmentData
cancellationToken
CancellationToken

Devoluções

Aplica-se a

UploadAttachmentAsync(IConversations, String, AttachmentData, CancellationToken)

UploadAttachment.

public static System.Threading.Tasks.Task<Microsoft.Bot.Schema.ResourceResponse> UploadAttachmentAsync (this Microsoft.Bot.Connector.IConversations operations, string conversationId, Microsoft.Bot.Schema.AttachmentData attachmentUpload, System.Threading.CancellationToken cancellationToken = default);
static member UploadAttachmentAsync : Microsoft.Bot.Connector.IConversations * string * Microsoft.Bot.Schema.AttachmentData * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Bot.Schema.ResourceResponse>
<Extension()>
Public Function UploadAttachmentAsync (operations As IConversations, conversationId As String, attachmentUpload As AttachmentData, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ResourceResponse)

Parâmetros

operations
IConversations

O grupo de operações para este método de extensão.

conversationId
String

ID de Conversação.

attachmentUpload
AttachmentData

Dados de anexo.

cancellationToken
CancellationToken

O token de cancelamento.

Devoluções

O campo ResourceResponse.

Observações

Carregue um anexo diretamente para o armazenamento de blobs de um canal.

Isto é útil porque lhe permite armazenar dados num arquivo compatível ao lidar com empresas.

A resposta é um ResourceResponse que contém um AttachmentId que é adequado para utilizar com a API de anexos.

Aplica-se a