summaryrefslogtreecommitdiff
path: root/discord/webhook.hpp
diff options
context:
space:
mode:
authorouwou <26526779+ouwou@users.noreply.github.com>2021-01-24 22:24:03 -0500
committerouwou <26526779+ouwou@users.noreply.github.com>2021-01-24 22:24:03 -0500
commit3923acd0dd7adef1710bfa039eb22454d9d551dd (patch)
treec81f9dd18f4bb6b0822b1fee21b34a87a4039eb1 /discord/webhook.hpp
parentcfa6607fc88b25fa74969e5407d4467ea9900444 (diff)
downloadabaddon-portaudio-3923acd0dd7adef1710bfa039eb22454d9d551dd.tar.gz
abaddon-portaudio-3923acd0dd7adef1710bfa039eb22454d9d551dd.zip
add viewing audit log
Diffstat (limited to 'discord/webhook.hpp')
-rw-r--r--discord/webhook.hpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/discord/webhook.hpp b/discord/webhook.hpp
new file mode 100644
index 0000000..f0214df
--- /dev/null
+++ b/discord/webhook.hpp
@@ -0,0 +1,24 @@
+#pragma once
+#include <optional>
+#include "json.hpp"
+#include "snowflake.hpp"
+#include "user.hpp"
+
+enum class WebhookType {
+ Incoming = 1,
+ ChannelFollower = 2,
+};
+
+struct WebhookData {
+ Snowflake ID;
+ WebhookType Type;
+ std::optional<Snowflake> GuildID;
+ Snowflake ChannelID;
+ std::optional<UserData> User;
+ std::string Name; // null
+ std::string Avatar; // null
+ std::optional<std::string> Token;
+ Snowflake ApplicationID; // null
+
+ friend void from_json(const nlohmann::json &j, WebhookData &m);
+};