|
tgbotxx 1.2.9.2
Telegram Bot C++ Library
|
Describes a regular gift owned by a user or a chat. More...
#include <OwnedGift.hpp>
Public Member Functions | |
| OwnedGiftRegular () | |
| OwnedGiftRegular (const nl::json &json) | |
| ~OwnedGiftRegular () override=default | |
| nl::json | toJson () const override |
| Serializes this object to JSON. | |
| void | fromJson (const nl::json &json) override |
| Deserializes this object from JSON. | |
Public Member Functions inherited from tgbotxx::OwnedGift | |
| OwnedGift ()=default | |
| OwnedGift (const nl::json &json) | |
| virtual | ~OwnedGift ()=default |
Public Attributes | |
| Ptr< Gift > | gift |
| Information about the regular gift. | |
| std::string | ownedGiftId |
| Optional. Unique identifier of the gift for the bot; for gifts received on behalf of business accounts only. | |
| Ptr< User > | senderUser |
| Optional. Sender of the gift if it is a known user. | |
| std::int64_t | sendDate {} |
| Date the gift was sent in Unix time. | |
| std::string | text |
| Optional. Text of the message that was added to the gift. | |
| std::vector< Ptr< MessageEntity > > | entities |
| Optional. Special entities that appear in the text. | |
| bool | isPrivate {} |
| Optional. True, if the sender and gift text are shown only to the gift receiver. | |
| bool | isSaved {} |
| Optional. True, if the gift is displayed on the account's profile page; for gifts received on behalf of business accounts only. | |
| bool | canBeUpgraded {} |
| Optional. True, if the gift can be upgraded to a unique gift; for gifts received on behalf of business accounts only. | |
| bool | wasRefunded {} |
| Optional. True, if the gift was refunded and isn't available anymore. | |
| std::int32_t | convertStarCount {} |
| Optional. Number of Telegram Stars that can be claimed by the receiver instead of the gift. | |
| std::int32_t | prepaidUpgradeStarCount {} |
| Optional. Number of Telegram Stars that were paid by the sender for the ability to upgrade the gift. | |
Public Attributes inherited from tgbotxx::OwnedGift | |
| std::string | type |
| Type of the gift: "regular" or "unique". | |
Describes a regular gift owned by a user or a chat.
Definition at line 37 of file OwnedGift.hpp.
|
inline |
Definition at line 38 of file OwnedGift.hpp.
|
inlineexplicit |
Definition at line 41 of file OwnedGift.hpp.
|
overridedefault |
Deserializes this object from JSON.
Reimplemented from tgbotxx::OwnedGift.
Definition at line 101 of file OwnedGift.hpp.
|
inlineoverridevirtual |
Serializes this object to JSON.
Reimplemented from tgbotxx::OwnedGift.
Definition at line 83 of file OwnedGift.hpp.
| bool tgbotxx::OwnedGiftRegular::canBeUpgraded {} |
Optional. True, if the gift can be upgraded to a unique gift; for gifts received on behalf of business accounts only.
Definition at line 71 of file OwnedGift.hpp.
| std::int32_t tgbotxx::OwnedGiftRegular::convertStarCount {} |
Optional. Number of Telegram Stars that can be claimed by the receiver instead of the gift.
Definition at line 77 of file OwnedGift.hpp.
| std::vector<Ptr<MessageEntity> > tgbotxx::OwnedGiftRegular::entities |
Optional. Special entities that appear in the text.
Definition at line 62 of file OwnedGift.hpp.
Information about the regular gift.
Definition at line 47 of file OwnedGift.hpp.
| bool tgbotxx::OwnedGiftRegular::isPrivate {} |
Optional. True, if the sender and gift text are shown only to the gift receiver.
Definition at line 65 of file OwnedGift.hpp.
| bool tgbotxx::OwnedGiftRegular::isSaved {} |
Optional. True, if the gift is displayed on the account's profile page; for gifts received on behalf of business accounts only.
Definition at line 68 of file OwnedGift.hpp.
| std::string tgbotxx::OwnedGiftRegular::ownedGiftId |
Optional. Unique identifier of the gift for the bot; for gifts received on behalf of business accounts only.
Definition at line 50 of file OwnedGift.hpp.
| std::int32_t tgbotxx::OwnedGiftRegular::prepaidUpgradeStarCount {} |
Optional. Number of Telegram Stars that were paid by the sender for the ability to upgrade the gift.
Definition at line 80 of file OwnedGift.hpp.
| std::int64_t tgbotxx::OwnedGiftRegular::sendDate {} |
Date the gift was sent in Unix time.
Definition at line 56 of file OwnedGift.hpp.
Optional. Sender of the gift if it is a known user.
Definition at line 53 of file OwnedGift.hpp.
| std::string tgbotxx::OwnedGiftRegular::text |
Optional. Text of the message that was added to the gift.
Definition at line 59 of file OwnedGift.hpp.
| bool tgbotxx::OwnedGiftRegular::wasRefunded {} |
Optional. True, if the gift was refunded and isn't available anymore.
Definition at line 74 of file OwnedGift.hpp.