tgbotxx 1.1.9.2
Telegram Bot C++ Library
Loading...
Searching...
No Matches
tgbotxx::UniqueGift Struct Reference

This object describes a unique gift that was upgraded from a regular gift. https://core.telegram.org/bots/api#uniquegift. More...

#include <UniqueGift.hpp>

Public Member Functions

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

Public Attributes

std::string baseName
 Human-readable name of the regular gift from which this unique gift was upgraded.
 
std::string name
 Unique name of the gift. This name can be used in https://t.me/nft/... links and story areas.
 
std::int32_t number {}
 Unique number of the upgraded gift among gifts upgraded from the same regular gift.
 
Ptr< UniqueGiftModelmodel
 Model of the gift.
 
Ptr< UniqueGiftSymbolsymbol
 Symbol of the gift.
 
Ptr< UniqueGiftBackdropbackdrop
 Backdrop of the gift.
 
Ptr< ChatpublisherChat
 Optional. Information about the chat that published the gift.
 

Detailed Description

This object describes a unique gift that was upgraded from a regular gift. https://core.telegram.org/bots/api#uniquegift.

Definition at line 11 of file UniqueGift.hpp.

Constructor & Destructor Documentation

◆ UniqueGift() [1/2]

tgbotxx::UniqueGift::UniqueGift ( )
default

◆ UniqueGift() [2/2]

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

Definition at line 13 of file UniqueGift.hpp.

Member Function Documentation

◆ fromJson()

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

Deserializes this object from JSON.

Definition at line 53 of file UniqueGift.hpp.

◆ toJson()

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

Serializes this object to JSON.

Returns
JSON representation of this object

Definition at line 40 of file UniqueGift.hpp.

Member Data Documentation

◆ backdrop

Ptr<UniqueGiftBackdrop> tgbotxx::UniqueGift::backdrop

Backdrop of the gift.

Definition at line 33 of file UniqueGift.hpp.

◆ baseName

std::string tgbotxx::UniqueGift::baseName

Human-readable name of the regular gift from which this unique gift was upgraded.

Definition at line 18 of file UniqueGift.hpp.

◆ model

Ptr<UniqueGiftModel> tgbotxx::UniqueGift::model

Model of the gift.

Definition at line 27 of file UniqueGift.hpp.

◆ name

std::string tgbotxx::UniqueGift::name

Unique name of the gift. This name can be used in https://t.me/nft/... links and story areas.

Definition at line 21 of file UniqueGift.hpp.

◆ number

std::int32_t tgbotxx::UniqueGift::number {}

Unique number of the upgraded gift among gifts upgraded from the same regular gift.

Definition at line 24 of file UniqueGift.hpp.

◆ publisherChat

Ptr<Chat> tgbotxx::UniqueGift::publisherChat

Optional. Information about the chat that published the gift.

Definition at line 36 of file UniqueGift.hpp.

◆ symbol

Ptr<UniqueGiftSymbol> tgbotxx::UniqueGift::symbol

Symbol of the gift.

Definition at line 30 of file UniqueGift.hpp.


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