Table of Contents

Method UploadFileAsync

Namespace
DisCatSharp.Experimental.Entities
Assembly
DisCatSharp.Experimental.dll

UploadFileAsync(DiscordChannel, string, Stream, string?)

Uploads a file to the channel for later use in a DiscordMessageBuilder.

public static Task<GcpAttachmentUploadInformation> UploadFileAsync(this DiscordChannel channel, string name, Stream stream, string? description = null)

Parameters

channel DiscordChannel

The channel to upload the file to.

name string

The name of the file to upload.

stream Stream

The stream of the file to upload.

description string

The description of the file to upload.

Returns

Task<GcpAttachmentUploadInformation>

The upload information.