Class: TD::Types::MessageContent::PremiumGiftCode
- Inherits:
-
TD::Types::MessageContent
- Object
- Dry::Struct
- Base
- TD::Types::MessageContent
- TD::Types::MessageContent::PremiumGiftCode
- Defined in:
- lib/tdlib/types/message_content/premium_gift_code.rb
Overview
A Telegram Premium gift code was created for the user.
Instance Attribute Summary collapse
-
#amount ⇒ Integer
The paid amount, in the smallest units of the currency; 0 if unknown.
-
#code ⇒ TD::Types::String
The gift code.
-
#creator_id ⇒ TD::Types::MessageSender?
Identifier of a chat or a user that created the gift code; may be null if unknown.
-
#cryptocurrency ⇒ TD::Types::String?
Cryptocurrency used to pay for the gift; may be empty if none or unknown.
-
#cryptocurrency_amount ⇒ Integer
The paid amount, in the smallest units of the cryptocurrency; 0 if unknown.
-
#currency ⇒ TD::Types::String
Currency for the paid amount; empty if unknown.
-
#is_from_giveaway ⇒ Boolean
True, if the gift code was created for a giveaway.
-
#is_unclaimed ⇒ Boolean
True, if the winner for the corresponding Telegram Premium subscription wasn’t chosen.
-
#month_count ⇒ Integer
Number of months the Telegram Premium subscription will be active after code activation.
-
#sticker ⇒ TD::Types::Sticker?
A sticker to be shown in the message; may be null if unknown.
Method Summary
Methods inherited from Base
Instance Attribute Details
#amount ⇒ Integer
The paid amount, in the smallest units of the currency; 0 if unknown.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def amount @amount end |
#code ⇒ TD::Types::String
The gift code.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def code @code end |
#creator_id ⇒ TD::Types::MessageSender?
Identifier of a chat or a user that created the gift code; may be null if unknown.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def creator_id @creator_id end |
#cryptocurrency ⇒ TD::Types::String?
Cryptocurrency used to pay for the gift; may be empty if none or unknown.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def cryptocurrency @cryptocurrency end |
#cryptocurrency_amount ⇒ Integer
The paid amount, in the smallest units of the cryptocurrency; 0 if unknown.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def cryptocurrency_amount @cryptocurrency_amount end |
#currency ⇒ TD::Types::String
Currency for the paid amount; empty if unknown.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def currency @currency end |
#is_from_giveaway ⇒ Boolean
True, if the gift code was created for a giveaway.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def is_from_giveaway @is_from_giveaway end |
#is_unclaimed ⇒ Boolean
True, if the winner for the corresponding Telegram Premium subscription wasn’t chosen.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def is_unclaimed @is_unclaimed end |
#month_count ⇒ Integer
Number of months the Telegram Premium subscription will be active after code activation.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def month_count @month_count end |
#sticker ⇒ TD::Types::Sticker?
A sticker to be shown in the message; may be null if unknown.
17 18 19 |
# File 'lib/tdlib/types/message_content/premium_gift_code.rb', line 17 def sticker @sticker end |