Method AddGcpAttachment
- Namespace
- DisCatSharp.Experimental.Entities
- Assembly
- DisCatSharp.Experimental.dll
AddGcpAttachment(DiscordMessageBuilder, GcpAttachmentUploadInformation, bool, Stream?)
Adds a GcpAttachment to the DiscordMessageBuilder.
public static DiscordMessageBuilder AddGcpAttachment(this DiscordMessageBuilder builder, GcpAttachmentUploadInformation gcpAttachment, bool isVoice = false, Stream? originalStream = null)
Parameters
builder
DiscordMessageBuilderThe DiscordMessageBuilder to add the attachment to.
gcpAttachment
GcpAttachmentUploadInformationThe attachment to add.
isVoice
boolWhether this is a voice message attachment.
originalStream
StreamThe voice message's stream, required if
isVoice
is true.
Returns
- DiscordMessageBuilder
The chained DiscordMessageBuilder.
AddGcpAttachment(DiscordInteractionResponseBuilder, GcpAttachmentUploadInformation)
Adds a GcpAttachment to the DiscordInteractionResponseBuilder.
public static DiscordInteractionResponseBuilder AddGcpAttachment(this DiscordInteractionResponseBuilder builder, GcpAttachmentUploadInformation gcpAttachment)
Parameters
builder
DiscordInteractionResponseBuilderThe DiscordInteractionResponseBuilder to add the attachment to.
gcpAttachment
GcpAttachmentUploadInformationThe attachment to add.
Returns
AddGcpAttachment(DiscordWebhookBuilder, GcpAttachmentUploadInformation)
Adds a GcpAttachment to the DiscordWebhookBuilder.
public static DiscordWebhookBuilder AddGcpAttachment(this DiscordWebhookBuilder builder, GcpAttachmentUploadInformation gcpAttachment)
Parameters
builder
DiscordWebhookBuilderThe DiscordWebhookBuilder to add the attachment to.
gcpAttachment
GcpAttachmentUploadInformationThe attachment to add.
Returns
- DiscordWebhookBuilder
The chained DiscordWebhookBuilder.
AddGcpAttachment(DiscordFollowupMessageBuilder, GcpAttachmentUploadInformation)
Adds a GcpAttachment to the DiscordFollowupMessageBuilder.
public static DiscordFollowupMessageBuilder AddGcpAttachment(this DiscordFollowupMessageBuilder builder, GcpAttachmentUploadInformation gcpAttachment)
Parameters
builder
DiscordFollowupMessageBuilderThe DiscordFollowupMessageBuilder to add the attachment to.
gcpAttachment
GcpAttachmentUploadInformationThe attachment to add.