public static async Task <DiscordDefaultWebhook> CreateWebhookAsync(this DiscordClient client, ulong channelId, DiscordWebhookProperties properties) { properties.ChannelId = channelId; DiscordDefaultWebhook hook = (await client.HttpClient.PostAsync($"/channels/{channelId}/webhooks", properties)).Deserialize <DiscordDefaultWebhook>().SetClient(client); hook.Modify(properties); return(hook); }
private void Update(DiscordDefaultWebhook hook) { Token = hook.Token; base.Update(hook); }