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

Represents the content of a message with an HTML widget to be sent as the result of an inline query. Currently, widgets can't be sent in response to inline queries in the production environment. More...

#include <Types.h>

Public Types

using Ptr = std::shared_ptr<InputWidgetMessageContent>

Public Attributes

std::string html { }
 HTML code of the widget, 1-32768 bytes. The code must not exceed 4096 bytes when compressed by zlib with the maximum compression level.
std::optional< std::uint32_t > width { }
 Optional. Width of the widget in logical pixels; omit if the widget must occupy the whole width of the message bubble. The width is clamped by the app to the range from 200 to the maximum width of the message bubble.
std::optional< std::uint32_t > height { }
 Optional. Height of the widget in logical pixels; omit if the height of the widget isn't fixed. The height is clamped by the app to the range 50-600.
std::optional< std::string > publicData { }
 Optional. Public data of the widget, 0-1024 bytes, which will be available wherever the widget is shown. If the widget is shared, then all messages with it will have the same public data.
std::optional< std::string > chatData { }
 Optional. Data of the widget, which is specific to the message, 0-1024 bytes.
std::optional< std::string > caption { }
 Optional. Widget caption, 0-1024 characters after entities parsing.
std::optional< std::string > parseMode { }
 Optional. Mode for parsing entities in the widget caption. See formatting options for more details.
std::optional< std::vector< std::shared_ptr< MessageEntity > > > captionEntities { }
 Optional. List of special entities that appear in the caption, which can be specified instead of parse_mode.
std::optional< bool > showCaptionAboveMedia { }
 Optional. Pass True if the caption must be shown above the widget.
std::optional< bool > allowQueries { }
 Optional. Pass True to allow the widget to send queries to the bot.
std::optional< bool > isShared { }
 Optional. Pass True to create a shared widget. Each message sent from the result creates a separate shared widget, whose identifier is received by the bot only in the field widget_id of queries from the widget. To send an existing shared widget in response to an inline query, use InputSharedWidgetMessageContent instead.

Detailed Description

Represents the content of a message with an HTML widget to be sent as the result of an inline query. Currently, widgets can't be sent in response to inline queries in the production environment.

Definition at line 7850 of file Types.h.

Member Typedef Documentation

◆ Ptr

Definition at line 7851 of file Types.h.

Member Data Documentation

◆ allowQueries

std::optional<bool> TgBot::InputWidgetMessageContent::allowQueries { }

Optional. Pass True to allow the widget to send queries to the bot.

Definition at line 7900 of file Types.h.

◆ caption

std::optional<std::string> TgBot::InputWidgetMessageContent::caption { }

Optional. Widget caption, 0-1024 characters after entities parsing.

Definition at line 7882 of file Types.h.

◆ captionEntities

std::optional<std::vector<std::shared_ptr<MessageEntity> > > TgBot::InputWidgetMessageContent::captionEntities { }

Optional. List of special entities that appear in the caption, which can be specified instead of parse_mode.

Definition at line 7892 of file Types.h.

◆ chatData

std::optional<std::string> TgBot::InputWidgetMessageContent::chatData { }

Optional. Data of the widget, which is specific to the message, 0-1024 bytes.

Definition at line 7878 of file Types.h.

◆ height

std::optional<std::uint32_t> TgBot::InputWidgetMessageContent::height { }

Optional. Height of the widget in logical pixels; omit if the height of the widget isn't fixed. The height is clamped by the app to the range 50-600.

Definition at line 7868 of file Types.h.

◆ html

std::string TgBot::InputWidgetMessageContent::html { }

HTML code of the widget, 1-32768 bytes. The code must not exceed 4096 bytes when compressed by zlib with the maximum compression level.

Definition at line 7857 of file Types.h.

◆ isShared

std::optional<bool> TgBot::InputWidgetMessageContent::isShared { }

Optional. Pass True to create a shared widget. Each message sent from the result creates a separate shared widget, whose identifier is received by the bot only in the field widget_id of queries from the widget. To send an existing shared widget in response to an inline query, use InputSharedWidgetMessageContent instead.

Definition at line 7907 of file Types.h.

◆ parseMode

std::optional<std::string> TgBot::InputWidgetMessageContent::parseMode { }

Optional. Mode for parsing entities in the widget caption. See formatting options for more details.

Definition at line 7887 of file Types.h.

◆ publicData

std::optional<std::string> TgBot::InputWidgetMessageContent::publicData { }

Optional. Public data of the widget, 0-1024 bytes, which will be available wherever the widget is shown. If the widget is shared, then all messages with it will have the same public data.

Definition at line 7874 of file Types.h.

◆ showCaptionAboveMedia

std::optional<bool> TgBot::InputWidgetMessageContent::showCaptionAboveMedia { }

Optional. Pass True if the caption must be shown above the widget.

Definition at line 7896 of file Types.h.

◆ width

std::optional<std::uint32_t> TgBot::InputWidgetMessageContent::width { }

Optional. Width of the widget in logical pixels; omit if the widget must occupy the whole width of the message bubble. The width is clamped by the app to the range from 200 to the maximum width of the message bubble.

Definition at line 7863 of file Types.h.


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