Method EditMessageAsync
- Namespace
- DSharpPlus.Entities
- Assembly
- DSharpPlus.dll
EditMessageAsync(ulong, DiscordWebhookBuilder, IEnumerable<DiscordAttachment>)
Edits a previously-sent webhook message.
public Task<DiscordMessage> EditMessageAsync(ulong messageId, DiscordWebhookBuilder builder, IEnumerable<DiscordAttachment> attachments = null)
Parameters
messageId
ulongThe id of the message to edit.
builder
DiscordWebhookBuilderThe builder of the message to edit.
attachments
IEnumerable<DiscordAttachment>Attached files to keep.
Returns
- Task<DiscordMessage>
The modified DiscordMessage
Exceptions
- NotFoundException
Thrown when the webhook does not exist.
- BadRequestException
Thrown when an invalid parameter was provided.
- ServerErrorException
Thrown when Discord is unable to process the request.