D++ (DPP)
C++ Discord API Bot Library
|
Represents stickers received in messages. More...
#include <message.h>
Public Member Functions | |
sticker () | |
Construct a new sticker object. More... | |
sticker & | fill_from_json (nlohmann::json *j) |
std::string | build_json (bool with_id=true) const |
sticker & | set_filename (const std::string &fn) |
Set the filename. More... | |
sticker & | set_file_content (const std::string &fc) |
Set the file content. More... | |
Public Attributes | |
snowflake | id |
The ID of the sticker. More... | |
snowflake | pack_id |
std::string | name |
std::string | description |
description of the sticker (may be empty) More... | |
std::string | tags |
std::string | asset |
Asset ID. More... | |
sticker_type | type |
sticker_format | format_type |
type of sticker format More... | |
bool | available |
Optional: whether this guild sticker can be used, may be false due to loss of Server Boosts. More... | |
snowflake | guild_id |
Optional: id of the guild that owns this sticker. More... | |
user | sticker_user |
Optional: the user that uploaded the guild sticker. More... | |
uint8_t | sort_value |
Optional: the standard sticker's sort order within its pack. More... | |
std::string | filename |
std::string | filecontent |
Represents stickers received in messages.
dpp::sticker::sticker | ( | ) |
Construct a new sticker object.
std::string dpp::sticker::build_json | ( | bool | with_id = true | ) | const |
Build JSON from this object.
with_id | True if the ID is to be set in the JSON structure |
sticker & dpp::sticker::fill_from_json | ( | nlohmann::json * | j | ) |
Read class values from json object
j | A json object to read from |
sticker & dpp::sticker::set_file_content | ( | const std::string & | fc | ) |
Set the file content.
fc | raw file content contained in std::string |
sticker & dpp::sticker::set_filename | ( | const std::string & | fn | ) |
Set the filename.
fn | filename |
std::string dpp::sticker::asset |
Asset ID.
bool dpp::sticker::available |
Optional: whether this guild sticker can be used, may be false due to loss of Server Boosts.
std::string dpp::sticker::description |
description of the sticker (may be empty)
std::string dpp::sticker::filecontent |
File content to upload (raw binary)
std::string dpp::sticker::filename |
Name of file to upload (when adding or editing a sticker)
sticker_format dpp::sticker::format_type |
type of sticker format
snowflake dpp::sticker::guild_id |
Optional: id of the guild that owns this sticker.
snowflake dpp::sticker::id |
The ID of the sticker.
std::string dpp::sticker::name |
The name of the sticker
snowflake dpp::sticker::pack_id |
Optional: for standard stickers, id of the pack the sticker is from
uint8_t dpp::sticker::sort_value |
Optional: the standard sticker's sort order within its pack.
user dpp::sticker::sticker_user |
Optional: the user that uploaded the guild sticker.
std::string dpp::sticker::tags |
for guild stickers, the Discord name of a unicode emoji representing the sticker's expression. for standard stickers, a comma-separated list of related expressions.
sticker_type dpp::sticker::type |
The type of sticker