Class: TD::Types::PremiumGiftCodeInfo
- Defined in:
- lib/tdlib/types/premium_gift_code_info.rb
Overview
Contains information about a Telegram Premium gift code.
Instance Attribute Summary collapse
-
#creation_date ⇒ Integer
Point in time (Unix timestamp) when the code was created.
-
#creator_id ⇒ TD::Types::MessageSender?
Identifier of a chat or a user that created the gift code; may be null if unknown.
-
#giveaway_message_id ⇒ Integer
Identifier of the corresponding giveaway message in the creator_id chat; can be 0 or an identifier of a deleted message.
-
#is_from_giveaway ⇒ Boolean
True, if the gift code was created for a giveaway.
-
#month_count ⇒ Integer
Number of months the Telegram Premium subscription will be active after code activation.
-
#use_date ⇒ Integer
Point in time (Unix timestamp) when the code was activated; 0 if none.
-
#user_id ⇒ Integer
Identifier of a user for which the code was created; 0 if none.
Method Summary
Methods inherited from Base
Instance Attribute Details
#creation_date ⇒ Integer
Point in time (Unix timestamp) when the code was created.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def creation_date @creation_date end |
#creator_id ⇒ TD::Types::MessageSender?
Identifier of a chat or a user that created the gift code; may be null if unknown. If null and the code is from MessageContent::PremiumGiftCode message, then creator_id from the message can be used.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def creator_id @creator_id end |
#giveaway_message_id ⇒ Integer
Identifier of the corresponding giveaway message in the creator_id chat; can be 0 or an identifier of a deleted message.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def @giveaway_message_id end |
#is_from_giveaway ⇒ Boolean
True, if the gift code was created for a giveaway.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def is_from_giveaway @is_from_giveaway end |
#month_count ⇒ Integer
Number of months the Telegram Premium subscription will be active after code activation.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def month_count @month_count end |
#use_date ⇒ Integer
Point in time (Unix timestamp) when the code was activated; 0 if none.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def use_date @use_date end |
#user_id ⇒ Integer
Identifier of a user for which the code was created; 0 if none.
16 17 18 |
# File 'lib/tdlib/types/premium_gift_code_info.rb', line 16 def user_id @user_id end |