tgbotxx  1.1.6.9
Telegram Bot C++ Library
tgbotxx::ReplyParameters Struct Reference

Describes reply parameters for the message that is being sent. https://core.telegram.org/bots/api#replyparameters. More...

#include <ReplyParameters.hpp>

Public Member Functions

 ReplyParameters ()=default
 
 ReplyParameters (const nl::json &json)
 
nl::json toJson () const
 Serializes this object to JSON. More...
 
void fromJson (const nl::json &json)
 Deserializes this object from JSON. More...
 

Public Attributes

std::int32_t messageId {}
 Identifier of the message that will be replied to in the current chat, or in the chat chat_id if it is specified. More...
 
std::int64_t chatId {}
 Optional. If the message to be replied to is from a different chat, unique identifier for the chat or username of the channel (in the format @channelusername) More...
 
bool allowSendingWithoutReply {}
 Optional. Pass True if the message should be sent even if the specified message to be replied to is not found; can be used only for replies in the same chat and forum topic. More...
 
std::string quote
 Optional. Quoted part of the message to be replied to; 0-1024 characters after entities parsing. The quote must be an exact substring of the message to be replied to, including bold, italic, underline, strikethrough, spoiler, and custom_emoji entities. The message will fail to send if the quote isn't found in the original message. More...
 
std::string quoteParseMode
 Optional. Mode for parsing entities in the quote. See formatting options for more details. More...
 
std::vector< Ptr< MessageEntity > > quoteEntities
 Optional. A JSON-serialized list of special entities that appear in the quote. It can be specified instead of quote_parse_mode. More...
 
std::int32_t quotePosition {}
 Optional. Position of the quote in the original message in UTF-16 code units. More...
 

Detailed Description

Describes reply parameters for the message that is being sent. https://core.telegram.org/bots/api#replyparameters.

Definition at line 8 of file ReplyParameters.hpp.

Constructor & Destructor Documentation

◆ ReplyParameters() [1/2]

tgbotxx::ReplyParameters::ReplyParameters ( )
default

◆ ReplyParameters() [2/2]

tgbotxx::ReplyParameters::ReplyParameters ( const nl::json &  json)
inlineexplicit

Definition at line 10 of file ReplyParameters.hpp.

Member Function Documentation

◆ fromJson()

void tgbotxx::ReplyParameters::fromJson ( const nl::json &  json)
inline

Deserializes this object from JSON.

Definition at line 56 of file ReplyParameters.hpp.

◆ toJson()

nl::json tgbotxx::ReplyParameters::toJson ( ) const
inline

Serializes this object to JSON.

Returns
JSON representation of this object

Definition at line 43 of file ReplyParameters.hpp.

Member Data Documentation

◆ allowSendingWithoutReply

bool tgbotxx::ReplyParameters::allowSendingWithoutReply {}

Optional. Pass True if the message should be sent even if the specified message to be replied to is not found; can be used only for replies in the same chat and forum topic.

Definition at line 23 of file ReplyParameters.hpp.

◆ chatId

std::int64_t tgbotxx::ReplyParameters::chatId {}

Optional. If the message to be replied to is from a different chat, unique identifier for the chat or username of the channel (in the format @channelusername)

Definition at line 19 of file ReplyParameters.hpp.

◆ messageId

std::int32_t tgbotxx::ReplyParameters::messageId {}

Identifier of the message that will be replied to in the current chat, or in the chat chat_id if it is specified.

Definition at line 15 of file ReplyParameters.hpp.

◆ quote

std::string tgbotxx::ReplyParameters::quote

Optional. Quoted part of the message to be replied to; 0-1024 characters after entities parsing. The quote must be an exact substring of the message to be replied to, including bold, italic, underline, strikethrough, spoiler, and custom_emoji entities. The message will fail to send if the quote isn't found in the original message.

Definition at line 28 of file ReplyParameters.hpp.

◆ quoteEntities

std::vector<Ptr<MessageEntity> > tgbotxx::ReplyParameters::quoteEntities

Optional. A JSON-serialized list of special entities that appear in the quote. It can be specified instead of quote_parse_mode.

Definition at line 35 of file ReplyParameters.hpp.

◆ quoteParseMode

std::string tgbotxx::ReplyParameters::quoteParseMode

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

Definition at line 32 of file ReplyParameters.hpp.

◆ quotePosition

std::int32_t tgbotxx::ReplyParameters::quotePosition {}

Optional. Position of the quote in the original message in UTF-16 code units.

Definition at line 38 of file ReplyParameters.hpp.


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