Method AddWebhookAsync
- Namespace
- DSharpPlus
- Assembly
- DSharpPlus.dll
AddWebhookAsync(ulong, string)
Registers a webhook with this client. This retrieves a webhook based on the ID and token supplied.
public Task<DiscordWebhook> AddWebhookAsync(ulong id, string token)
Parameters
Returns
- Task<DiscordWebhook>
The registered webhook.
AddWebhookAsync(Uri)
Registers a webhook with this client. This retrieves a webhook from webhook URL.
public Task<DiscordWebhook> AddWebhookAsync(Uri url)
Parameters
urlUriURL of the webhook to retrieve. This URL must contain both ID and token.
Returns
- Task<DiscordWebhook>
The registered webhook.
AddWebhookAsync(ulong, BaseDiscordClient)
Registers a webhook with this client. This retrieves a webhook using the supplied full discord client.
public Task<DiscordWebhook> AddWebhookAsync(ulong id, BaseDiscordClient client)
Parameters
idulongID of the webhook to register.
clientBaseDiscordClientDiscord client to which the webhook will belong.
Returns
- Task<DiscordWebhook>
The registered webhook.