tgbot-cpp
Loading...
Searching...
No Matches
TgBot::ChatShared Struct Reference

This object contains information about a chat that was shared with the bot using a KeyboardButtonRequestChat button. More...

#include <Types.h>

Public Types

using Ptr = std::shared_ptr<ChatShared>

Public Attributes

std::int32_t requestId { }
 Identifier of the request.
std::int64_t chatId { }
 Identifier of the shared chat. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier. The bot may not have access to the chat and could be unable to use this identifier, unless the chat is already known to the bot by some other means.
std::optional< std::string > title { }
 Optional. Title of the chat, if the title was requested by the bot.
std::optional< std::string > username { }
 Optional. Username of the chat, if the username was requested by the bot and available.
std::optional< std::vector< std::shared_ptr< PhotoSize > > > photo { }
 Optional. Available sizes of the chat photo, if the photo was requested by the bot.

Detailed Description

This object contains information about a chat that was shared with the bot using a KeyboardButtonRequestChat button.

Definition at line 2943 of file Types.h.

Member Typedef Documentation

◆ Ptr

using TgBot::ChatShared::Ptr = std::shared_ptr<ChatShared>

Definition at line 2944 of file Types.h.

Member Data Documentation

◆ chatId

std::int64_t TgBot::ChatShared::chatId { }

Identifier of the shared chat. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier. The bot may not have access to the chat and could be unable to use this identifier, unless the chat is already known to the bot by some other means.

Definition at line 2959 of file Types.h.

◆ photo

std::optional<std::vector<std::shared_ptr<PhotoSize> > > TgBot::ChatShared::photo { }

Optional. Available sizes of the chat photo, if the photo was requested by the bot.

Definition at line 2974 of file Types.h.

◆ requestId

std::int32_t TgBot::ChatShared::requestId { }

Identifier of the request.

Definition at line 2949 of file Types.h.

◆ title

std::optional<std::string> TgBot::ChatShared::title { }

Optional. Title of the chat, if the title was requested by the bot.

Definition at line 2964 of file Types.h.

◆ username

std::optional<std::string> TgBot::ChatShared::username { }

Optional. Username of the chat, if the username was requested by the bot and available.

Definition at line 2969 of file Types.h.


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