Class DiscordWebhookBuilder
- Namespace
- DSharpPlus.Entities
- Assembly
- DSharpPlus.dll
Constructs ready-to-send webhook requests.
public sealed class DiscordWebhookBuilder : BaseDiscordMessageBuilder<DiscordWebhookBuilder>, IDiscordMessageBuilder
- Inheritance
-
objectDiscordWebhookBuilder
- Implements
- Inherited Members
Constructors
- DiscordWebhookBuilder()
Constructs a new empty webhook request builder.
- DiscordWebhookBuilder(DiscordWebhookBuilder)
Constructs a new webhook request builder based on a previous message builder
- DiscordWebhookBuilder(IDiscordMessageBuilder)
Copies the common properties from the passed builder.
Properties
- AvatarUrl
Avatar url to use for this webhook request.
- ThreadId
Id of the thread to send the webhook request to.
- Username
Username to use for this webhook request.
Methods
- Clear()
Allows for clearing the Message Builder so that it can be used again to send a new message.
- ModifyAsync(DiscordWebhook, DiscordMessage)
Sends the modified webhook message.
- ModifyAsync(DiscordWebhook, ulong)
Sends the modified webhook message.
- SendAsync(DiscordWebhook)
Executes a webhook.
- WithAvatarUrl(string)
Sets the avatar of this webhook builder from its url.
- WithThreadId(ulong?)
Sets the id of the thread to execute the webhook on.
- WithUsername(string)
Sets the username for this webhook builder.