tgbot-cpp
Loading...
Searching...
No Matches
Chat.h
Go to the documentation of this file.
1#ifndef TGBOT_CHAT_H
2#define TGBOT_CHAT_H
3
9#include "tgbot/types/Chat.h"
13
14#include <cstdint>
15#include <memory>
16#include <string>
17#include <vector>
18
19namespace TgBot {
20
21class Message;
22
28class Chat {
29
30public:
31 typedef std::shared_ptr<Chat> Ptr;
32
36 enum class Type {
38 };
39
46 std::int64_t id;
47
52
56 std::string title;
57
61 std::string username;
62
66 std::string firstName;
67
71 std::string lastName;
72
76 bool isForum;
77
84
90 std::vector<std::string> activeUsernames;
91
98
105
112
119
126
133 std::vector<ReactionType::Ptr> availableReactions;
134
142 std::int32_t accentColorId;
143
150
158
165
172
179
185 std::string bio;
186
193
200
207
214
220 std::string description;
221
227 std::string inviteLink;
228
234 std::shared_ptr<Message> pinnedMessage;
235
242
248 std::int32_t slowModeDelay;
249
256
263
271
278
285
292
298 std::string stickerSetName;
299
306
314
322 std::int64_t linkedChatId;
323
330};
331}
332
333#endif //TGBOT_CHAT_H
std::shared_ptr< Birthdate > Ptr
Definition Birthdate.h:15
std::shared_ptr< BusinessIntro > Ptr
std::shared_ptr< BusinessLocation > Ptr
std::shared_ptr< BusinessOpeningHours > Ptr
This object represents a chat.
Definition Chat.h:28
std::string stickerSetName
Optional. For supergroups, name of group sticker set.
Definition Chat.h:298
bool isForum
Optional. True, if the supergroup chat is a forum (has topics enabled)
Definition Chat.h:76
std::string title
Optional. Title, for supergroups, channels and group chats.
Definition Chat.h:56
std::vector< ReactionType::Ptr > availableReactions
Optional. List of available reactions allowed in the chat.
Definition Chat.h:133
std::string bio
Optional. Bio of the other party in a private chat.
Definition Chat.h:185
std::string profileBackgroundCustomEmojiId
Optional. Custom emoji identifier of the emoji chosen by the chat for its profile background.
Definition Chat.h:164
std::int64_t id
Unique identifier for this chat.
Definition Chat.h:46
bool joinByRequest
Optional. True, if all users directly joining the supergroup need to be approved by supergroup admini...
Definition Chat.h:213
bool hasHiddenMembers
Optional. True, if non-administrators can only get the list of bots and administrators in the chat.
Definition Chat.h:277
std::string inviteLink
Optional. Primary invite link, for groups, supergroups and channel chats.
Definition Chat.h:227
std::string emojiStatusCustomEmojiId
Optional. Custom emoji identifier of the emoji status of the chat or the other party in a private cha...
Definition Chat.h:171
bool hasPrivateForwards
Optional. True, if privacy settings of the other party in the private chat allows to use tg://user?...
Definition Chat.h:192
std::string customEmojiStickerSetName
Optional. For supergroups, the name of the group's custom emoji sticker set.
Definition Chat.h:313
bool hasRestrictedVoiceAndVideoMessages
Optional. True, if the privacy settings of the other party restrict sending voice and video note mess...
Definition Chat.h:199
bool canSetStickerSet
Optional. True, if the bot can change the group sticker set.
Definition Chat.h:305
bool hasAggressiveAntiSpamEnabled
Optional. True, if aggressive anti-spam checks are enabled in the supergroup.
Definition Chat.h:270
BusinessOpeningHours::Ptr businessOpeningHours
Optional. For private chats with business accounts, the opening hours of the business.
Definition Chat.h:118
bool hasProtectedContent
Optional. True, if messages from the chat can't be forwarded to other chats.
Definition Chat.h:284
Type type
Type of chat, can be either “private”, “group”, “supergroup” or “channel”
Definition Chat.h:51
std::string firstName
Optional. First name of the other party in a private chat.
Definition Chat.h:66
std::int32_t messageAutoDeleteTime
Optional. The time after which all messages sent to the chat will be automatically deleted; in second...
Definition Chat.h:262
std::int32_t accentColorId
Optional. Identifier of the accent color for the chat name and backgrounds of the chat photo,...
Definition Chat.h:142
std::string description
Optional. Description, for groups, supergroups and channel chats.
Definition Chat.h:220
Type
Enum of possible types of a chat.
Definition Chat.h:36
std::shared_ptr< Chat > Ptr
Definition Chat.h:31
bool joinToSendMessages
Optional. True, if users need to join the supergroup before they can send messages.
Definition Chat.h:206
ChatLocation::Ptr location
Optional. For supergroups, the location to which the supergroup is connected.
Definition Chat.h:329
std::int32_t unrestrictBoostCount
Optional. For supergroups, the minimum number of boosts that a non-administrator user needs to add in...
Definition Chat.h:255
std::int64_t linkedChatId
Optional. Unique identifier for the linked chat, i.e. the discussion group identifier for a channel a...
Definition Chat.h:322
std::vector< std::string > activeUsernames
Optional. If non-empty, the list of all active chat usernames; for private chats, supergroups and cha...
Definition Chat.h:90
bool hasVisibleHistory
Optional. True, if new chat members will have access to old messages; available only to chat administ...
Definition Chat.h:291
ChatPhoto::Ptr photo
Optional. Chat photo.
Definition Chat.h:83
std::uint32_t emojiStatusExpirationDate
Optional. Expiration date of the emoji status of the chat or the other party in a private chat,...
Definition Chat.h:178
ChatPermissions::Ptr permissions
Optional. Default chat member permissions, for groups and supergroups.
Definition Chat.h:241
BusinessIntro::Ptr businessIntro
Optional. For private chats with business accounts, the intro of the business.
Definition Chat.h:104
std::string backgroundCustomEmojiId
Optional. Custom emoji identifier of emoji chosen by the chat for the reply header and link preview b...
Definition Chat.h:149
Chat::Ptr personalChat
Optional. For private chats, the personal channel of the user.
Definition Chat.h:125
std::string lastName
Optional. Last name of the other party in a private chat.
Definition Chat.h:71
BusinessLocation::Ptr businessLocation
Optional. For private chats with business accounts, the location of the business.
Definition Chat.h:111
std::shared_ptr< Message > pinnedMessage
Optional. The most recent pinned message (by sending date).
Definition Chat.h:234
std::int32_t slowModeDelay
Optional. For supergroups, the minimum allowed delay between consecutive messages sent by each unpriv...
Definition Chat.h:248
std::int32_t profileAccentColorId
Optional. Identifier of the accent color for the chat's profile background.
Definition Chat.h:157
std::string username
Optional. Username, for private chats, supergroups and channels if available.
Definition Chat.h:61
Birthdate::Ptr birthdate
Optional. For private chats, the date of birth of the user.
Definition Chat.h:97
std::shared_ptr< ChatLocation > Ptr
std::shared_ptr< ChatPermissions > Ptr
std::shared_ptr< ChatPhoto > Ptr
Definition ChatPhoto.h:17
Definition Api.h:40