summaryrefslogtreecommitdiff
path: root/discord/discord.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'discord/discord.cpp')
-rw-r--r--discord/discord.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/discord/discord.cpp b/discord/discord.cpp
index 7d0ca23..481e193 100644
--- a/discord/discord.cpp
+++ b/discord/discord.cpp
@@ -159,6 +159,11 @@ void DiscordClient::SendChatMessage(std::string content, Snowflake channel) {
m_http.MakePOST("/channels/" + std::to_string(channel) + "/messages", j.dump(), [](auto) {});
}
+void DiscordClient::DeleteMessage(Snowflake channel_id, Snowflake id) {
+ std::string path = "/channels/" + std::to_string(channel_id) + "/messages/" + std::to_string(id);
+ m_http.MakeDELETE(path, [](auto) {});
+}
+
void DiscordClient::UpdateToken(std::string token) {
m_token = token;
m_http.SetAuth(token);