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
7
8#include <cstdint>
9#include <memory>
10#include <string>
11#include <vector>
12
13namespace TgBot {
14
15class Message;
16
22class Chat {
23
24public:
25 typedef std::shared_ptr<Chat> Ptr;
26
30 enum class Type {
32 };
33
40 std::int64_t id;
41
46
50 std::string title;
51
55 std::string username;
56
60 std::string firstName;
61
65 std::string lastName;
66
70 bool isForum;
71
78
84 std::vector<std::string> activeUsernames;
85
92
98 std::string bio;
99
106
113
120
127
133 std::string description;
134
140 std::string inviteLink;
141
147 std::shared_ptr<Message> pinnedMessage;
148
155
161 std::int32_t slowModeDelay;
162
169
177
184
191
197 std::string stickerSetName;
198
205
213 std::int64_t linkedChatId;
214
221};
222}
223
224#endif //TGBOT_CHAT_H
This object represents a chat.
Definition Chat.h:22
std::string stickerSetName
Optional. For supergroups, name of group sticker set.
Definition Chat.h:197
bool isForum
Optional. True, if the supergroup chat is a forum (has topics enabled)
Definition Chat.h:70
std::string title
Optional. Title, for supergroups, channels and group chats.
Definition Chat.h:50
std::string bio
Optional. Bio of the other party in a private chat.
Definition Chat.h:98
std::int64_t id
Unique identifier for this chat.
Definition Chat.h:40
bool joinByRequest
Optional. True, if all users directly joining the supergroup need to be approved by supergroup admini...
Definition Chat.h:126
bool hasHiddenMembers
Optional. True, if non-administrators can only get the list of bots and administrators in the chat.
Definition Chat.h:183
std::string inviteLink
Optional. Primary invite link, for groups, supergroups and channel chats.
Definition Chat.h:140
std::string emojiStatusCustomEmojiId
Optional. Custom emoji identifier of emoji status of the other party in a private chat.
Definition Chat.h:91
bool hasPrivateForwards
Optional. True, if privacy settings of the other party in the private chat allows to use tg://user?...
Definition Chat.h:105
bool hasRestrictedVoiceAndVideoMessages
Optional. True, if the privacy settings of the other party restrict sending voice and video note mess...
Definition Chat.h:112
bool canSetStickerSet
Optional. True, if the bot can change the group sticker set.
Definition Chat.h:204
bool hasAggressiveAntiSpamEnabled
Optional. True, if aggressive anti-spam checks are enabled in the supergroup.
Definition Chat.h:176
bool hasProtectedContent
Optional. True, if messages from the chat can't be forwarded to other chats.
Definition Chat.h:190
Type type
Type of chat, can be either “private”, “group”, “supergroup” or “channel”
Definition Chat.h:45
std::string firstName
Optional. First name of the other party in a private chat.
Definition Chat.h:60
std::int32_t messageAutoDeleteTime
Optional. The time after which all messages sent to the chat will be automatically deleted; in second...
Definition Chat.h:168
std::string description
Optional. Description, for groups, supergroups and channel chats.
Definition Chat.h:133
Type
Enum of possible types of a chat.
Definition Chat.h:30
std::shared_ptr< Chat > Ptr
Definition Chat.h:25
bool joinToSendMessages
Optional. True, if users need to join the supergroup before they can send messages.
Definition Chat.h:119
ChatLocation::Ptr location
Optional. For supergroups, the location to which the supergroup is connected.
Definition Chat.h:220
std::int64_t linkedChatId
Optional. Unique identifier for the linked chat, i.e. the discussion group identifier for a channel a...
Definition Chat.h:213
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:84
ChatPhoto::Ptr photo
Optional. Chat photo.
Definition Chat.h:77
ChatPermissions::Ptr permissions
Optional. Default chat member permissions, for groups and supergroups.
Definition Chat.h:154
std::string lastName
Optional. Last name of the other party in a private chat.
Definition Chat.h:65
std::shared_ptr< Message > pinnedMessage
Optional. The most recent pinned message (by sending date).
Definition Chat.h:147
std::int32_t slowModeDelay
Optional. For supergroups, the minimum allowed delay between consecutive messages sent by each unpriv...
Definition Chat.h:161
std::string username
Optional. Username, for private chats, supergroups and channels if available.
Definition Chat.h:55
std::shared_ptr< ChatLocation > Ptr
std::shared_ptr< ChatPermissions > Ptr
std::shared_ptr< ChatPhoto > Ptr
Definition ChatPhoto.h:17
Definition Api.h:39