Table of Contents

Method EditMessageAsync

Namespace
DisCatSharp.Entities
Assembly
DisCatSharp.dll

EditMessageAsync(ulong, DiscordWebhookBuilder, ulong?, ModifyMode)

Edits a previously-sent webhook message.

public Task<DiscordMessage> EditMessageAsync(ulong messageId, DiscordWebhookBuilder builder, ulong? threadId = null, ModifyMode modifyMode = ModifyMode.Update)

Parameters

messageId ulong

The id of the message to edit.

builder DiscordWebhookBuilder

The builder of the message to edit.

threadId ulong?

Target thread id (Optional). Defaults to null.

modifyMode ModifyMode

The mode of modification.

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.