All Classes Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Types | Public Member Functions | Public Attributes | List of all members
aegis::gateway::objects::channel Struct Reference

Represents a guild or DM channel within Discord. More...

#include <channel.hpp>

Public Types

enum  channel_type {
  Text = 0, DirectMessage = 1, Voice = 2, GroupDirectMessage = 3,
  Category = 4
 Enumeration of the channel types. More...

Public Member Functions

 channel (const std::string &_json, aegis::core *bot) noexcept
 channel (const nlohmann::json &_json, aegis::core *bot) noexcept
 channel (aegis::core *bot) noexcept

Public Attributes

snowflake id
snowflake channel_id
channel_type type = Text
snowflake guild_id = 0
int position = 0
< objects::permission_overwrite
std::string name
std::string topic
bool nsfw = false
snowflake last_message_id = 0
int bitrate = 0
int userlimit = 0
std::vector< objects::userrecipients
std::string icon
snowflake owner_id
snowflake application_id
snowflake parent_id

Detailed Description

Represents a guild or DM channel within Discord.

Member Enumeration Documentation

Enumeration of the channel types.


Text channel within a guild


Direct message channel between a pair of users


Voice channel within a guild


Direct message channel between a group of users


Category containing channels

Member Data Documentation

snowflake aegis::gateway::objects::channel::application_id

Application ID of the DM creator (if the creator is a bot)

int aegis::gateway::objects::channel::bitrate = 0

Bitrate (in bits), if this is a voice channel

snowflake aegis::gateway::objects::channel::channel_id
snowflake aegis::gateway::objects::channel::guild_id = 0

Snowflake if channel belongs to a guild (not a DM)

std::string aegis::gateway::objects::channel::icon

Icon hash

snowflake aegis::gateway::objects::channel::id


snowflake aegis::gateway::objects::channel::last_message_id = 0

Snowflake of the last message sent in the channel (message may be non-existent)

std::string aegis::gateway::objects::channel::name

Name of the channel (must be 2-100 characters)

bool aegis::gateway::objects::channel::nsfw = false

Whether the channel is NSFW

snowflake aegis::gateway::objects::channel::owner_id

Snowflake of the DM creator (if the creator is a user)

snowflake aegis::gateway::objects::channel::parent_id

Snowflake of the parent category

std::vector<objects::permission_overwrite> aegis::gateway::objects::channel::permission_overwrites

Explicit permission overwrites for members and roles

int aegis::gateway::objects::channel::position = 0

Sorting position of the channel

std::vector<objects::user> aegis::gateway::objects::channel::recipients

Channel message recipients, if this is a DM

std::string aegis::gateway::objects::channel::topic

Topic of the channel (up to 1024 characters)

channel_type aegis::gateway::objects::channel::type = Text

Channel type - Text | DirectMessage | Voice | GroupDirectMessage | Category

int aegis::gateway::objects::channel::userlimit = 0

User limit, if this is a voice channel

The documentation for this struct was generated from the following file: