diff --git a/include/dpp/appcommand.h b/include/dpp/appcommand.h index b5979241fc..184978954e 100644 --- a/include/dpp/appcommand.h +++ b/include/dpp/appcommand.h @@ -19,6 +19,7 @@ * ************************************************************************************/ #pragma once +#include #include #include #include @@ -972,10 +973,16 @@ class DPP_EXPORT interaction : public managed, public json_interface authorizing_integration_owners; + /** * @brief Context where the interaction was triggered from */ std::optional context; + /** * @brief ID of the application this interaction is for. */ diff --git a/src/dpp/slashcommand.cpp b/src/dpp/slashcommand.cpp index ee1d88f5c4..86a97fbbc5 100644 --- a/src/dpp/slashcommand.cpp +++ b/src/dpp/slashcommand.cpp @@ -755,6 +755,10 @@ void from_json(const nlohmann::json& j, interaction& i) { i.context = static_cast(*it); } + if (auto it = j.find("authorizing_integration_owners"); it != j.end()) { + it->get_to(i.authorizing_integration_owners); + } + if(j.contains("entitlements")) { for (auto& entitle : j["entitlements"]) { i.entitlements.emplace_back(entitlement().fill_from_json(const_cast(&entitle)));