Package org.drinkless.tdlib
Class TdApi.UpgradedGift
java.lang.Object
org.drinkless.tdlib.TdApi.Object
org.drinkless.tdlib.TdApi.UpgradedGift
- Enclosing class:
- TdApi
Describes an upgraded gift that can be transferred to another owner or transferred to the TON blockchain as an NFT.
-
Field Summary
FieldsModifier and TypeFieldDescriptionBackdrop of the upgraded gift.booleanTrue, if an offer to purchase the gift can be sent using sendGiftPurchaseOffer.Colors that can be set for user's name, background of empty chat photo, replies to messages and link previews; may be null if none.static final intIdentifier uniquely determining type of the object.Address of the gift NFT in TON blockchain; may be empty if none.Identifier of the user or the chat to which the upgraded gift was assigned from blockchain; may be null if none or unknown.longUnique identifier of the gift.booleanTrue, if the original gift could have been bought only by Telegram Premium subscribers.booleanTrue, if the gift can be used to set a theme in a chat.intThe maximum number of gifts that can be upgraded from the same gift.Model of the upgraded gift.Unique name of the upgraded gift that can be used with internalLinkTypeUpgradedGift or sendResoldGift.intUnique number of the upgraded gift among gifts upgraded from the same gift.Information about the originally sent gift; may be null if unknown.Address of the gift NFT owner in TON blockchain; may be empty if none.Identifier of the user or the chat that owns the upgraded gift; may be null if none or unknown.Name of the owner for the case when owner identifier and address aren't known.longIdentifier of the chat that published the gift; 0 if none.longUnique identifier of the regular gift from which the gift was upgraded; may be 0 for short period of time for old gifts from database.Resale parameters of the gift; may be null if resale isn't possible.Symbol of the upgraded gift.The title of the upgraded gift.intTotal number of gifts that were upgraded from the same gift.longIdentifier of the chat for which the gift is used to set a theme; 0 if none or the gift isn't owned by the current user.longEstimated value of the gift; in the smallest units of the currency; 0 if unavailable.ISO 4217 currency code of the currency in which value of the gift is represented; may be empty if unavailable.longEstimated value of the gift in USD; in USD cents; 0 if unavailable. -
Constructor Summary
ConstructorsConstructorDescriptionDescribes an upgraded gift that can be transferred to another owner or transferred to the TON blockchain as an NFT.UpgradedGift(long id, long regularGiftId, long publisherChatId, String title, String name, int number, int totalUpgradedCount, int maxUpgradedCount, boolean isPremium, boolean isThemeAvailable, long usedThemeChatId, TdApi.MessageSender hostId, TdApi.MessageSender ownerId, String ownerAddress, String ownerName, String giftAddress, TdApi.UpgradedGiftModel model, TdApi.UpgradedGiftSymbol symbol, TdApi.UpgradedGiftBackdrop backdrop, TdApi.UpgradedGiftOriginalDetails originalDetails, TdApi.UpgradedGiftColors colors, TdApi.GiftResaleParameters resaleParameters, boolean canSendPurchaseOffer, String valueCurrency, long valueAmount, long valueUsdAmount) Describes an upgraded gift that can be transferred to another owner or transferred to the TON blockchain as an NFT. -
Method Summary
Modifier and TypeMethodDescriptionintReturns an identifier uniquely determining type of the object.Methods inherited from class org.drinkless.tdlib.TdApi.Object
toString
-
Field Details
-
id
public long idUnique identifier of the gift. -
regularGiftId
public long regularGiftIdUnique identifier of the regular gift from which the gift was upgraded; may be 0 for short period of time for old gifts from database. -
publisherChatId
public long publisherChatIdIdentifier of the chat that published the gift; 0 if none. -
title
The title of the upgraded gift. -
name
Unique name of the upgraded gift that can be used with internalLinkTypeUpgradedGift or sendResoldGift. -
number
public int numberUnique number of the upgraded gift among gifts upgraded from the same gift. -
totalUpgradedCount
public int totalUpgradedCountTotal number of gifts that were upgraded from the same gift. -
maxUpgradedCount
public int maxUpgradedCountThe maximum number of gifts that can be upgraded from the same gift. -
isPremium
public boolean isPremiumTrue, if the original gift could have been bought only by Telegram Premium subscribers. -
isThemeAvailable
public boolean isThemeAvailableTrue, if the gift can be used to set a theme in a chat. -
usedThemeChatId
public long usedThemeChatIdIdentifier of the chat for which the gift is used to set a theme; 0 if none or the gift isn't owned by the current user. -
hostId
Identifier of the user or the chat to which the upgraded gift was assigned from blockchain; may be null if none or unknown. -
ownerId
Identifier of the user or the chat that owns the upgraded gift; may be null if none or unknown. -
ownerAddress
Address of the gift NFT owner in TON blockchain; may be empty if none. Append the address to getOption("ton_blockchain_explorer_url") to get a link with information about the address. -
ownerName
Name of the owner for the case when owner identifier and address aren't known. -
giftAddress
Address of the gift NFT in TON blockchain; may be empty if none. Append the address to getOption("ton_blockchain_explorer_url") to get a link with information about the address. -
model
Model of the upgraded gift. -
symbol
Symbol of the upgraded gift. -
backdrop
Backdrop of the upgraded gift. -
originalDetails
Information about the originally sent gift; may be null if unknown. -
colors
Colors that can be set for user's name, background of empty chat photo, replies to messages and link previews; may be null if none. -
resaleParameters
Resale parameters of the gift; may be null if resale isn't possible. -
canSendPurchaseOffer
public boolean canSendPurchaseOfferTrue, if an offer to purchase the gift can be sent using sendGiftPurchaseOffer. -
valueCurrency
ISO 4217 currency code of the currency in which value of the gift is represented; may be empty if unavailable. -
valueAmount
public long valueAmountEstimated value of the gift; in the smallest units of the currency; 0 if unavailable. -
valueUsdAmount
public long valueUsdAmountEstimated value of the gift in USD; in USD cents; 0 if unavailable. -
CONSTRUCTOR
public static final int CONSTRUCTORIdentifier uniquely determining type of the object.- See Also:
-
-
Constructor Details
-
UpgradedGift
public UpgradedGift()Describes an upgraded gift that can be transferred to another owner or transferred to the TON blockchain as an NFT. -
UpgradedGift
public UpgradedGift(long id, long regularGiftId, long publisherChatId, String title, String name, int number, int totalUpgradedCount, int maxUpgradedCount, boolean isPremium, boolean isThemeAvailable, long usedThemeChatId, TdApi.MessageSender hostId, TdApi.MessageSender ownerId, String ownerAddress, String ownerName, String giftAddress, TdApi.UpgradedGiftModel model, TdApi.UpgradedGiftSymbol symbol, TdApi.UpgradedGiftBackdrop backdrop, TdApi.UpgradedGiftOriginalDetails originalDetails, TdApi.UpgradedGiftColors colors, TdApi.GiftResaleParameters resaleParameters, boolean canSendPurchaseOffer, String valueCurrency, long valueAmount, long valueUsdAmount) Describes an upgraded gift that can be transferred to another owner or transferred to the TON blockchain as an NFT.- Parameters:
id- Unique identifier of the gift.regularGiftId- Unique identifier of the regular gift from which the gift was upgraded; may be 0 for short period of time for old gifts from database.publisherChatId- Identifier of the chat that published the gift; 0 if none.title- The title of the upgraded gift.name- Unique name of the upgraded gift that can be used with internalLinkTypeUpgradedGift or sendResoldGift.number- Unique number of the upgraded gift among gifts upgraded from the same gift.totalUpgradedCount- Total number of gifts that were upgraded from the same gift.maxUpgradedCount- The maximum number of gifts that can be upgraded from the same gift.isPremium- True, if the original gift could have been bought only by Telegram Premium subscribers.isThemeAvailable- True, if the gift can be used to set a theme in a chat.usedThemeChatId- Identifier of the chat for which the gift is used to set a theme; 0 if none or the gift isn't owned by the current user.hostId- Identifier of the user or the chat to which the upgraded gift was assigned from blockchain; may be null if none or unknown.ownerId- Identifier of the user or the chat that owns the upgraded gift; may be null if none or unknown.ownerAddress- Address of the gift NFT owner in TON blockchain; may be empty if none. Append the address to getOption("ton_blockchain_explorer_url") to get a link with information about the address.ownerName- Name of the owner for the case when owner identifier and address aren't known.giftAddress- Address of the gift NFT in TON blockchain; may be empty if none. Append the address to getOption("ton_blockchain_explorer_url") to get a link with information about the address.model- Model of the upgraded gift.symbol- Symbol of the upgraded gift.backdrop- Backdrop of the upgraded gift.originalDetails- Information about the originally sent gift; may be null if unknown.colors- Colors that can be set for user's name, background of empty chat photo, replies to messages and link previews; may be null if none.resaleParameters- Resale parameters of the gift; may be null if resale isn't possible.canSendPurchaseOffer- True, if an offer to purchase the gift can be sent using sendGiftPurchaseOffer.valueCurrency- ISO 4217 currency code of the currency in which value of the gift is represented; may be empty if unavailable.valueAmount- Estimated value of the gift; in the smallest units of the currency; 0 if unavailable.valueUsdAmount- Estimated value of the gift in USD; in USD cents; 0 if unavailable.
-
-
Method Details
-
getConstructor
public int getConstructor()Description copied from class:TdApi.ObjectReturns an identifier uniquely determining type of the object.- Specified by:
getConstructorin classTdApi.Object- Returns:
- this.CONSTRUCTOR
-