Class: TD::Types::PremiumPaymentOption

Inherits:
Base
  • Object
show all
Defined in:
lib/tdlib/types/premium_payment_option.rb

Overview

Describes an option for buying Telegram Premium to a user.

Instance Attribute Summary collapse

Method Summary

Methods inherited from Base

#to_hash, #to_json

Instance Attribute Details

#amountInteger

The amount to pay, in the smallest units of the currency.

Returns:

  • (Integer)

    the current value of amount



11
12
13
# File 'lib/tdlib/types/premium_payment_option.rb', line 11

def amount
  @amount
end

#currencyTD::Types::String

ISO 4217 currency code for Telegram Premium subscription payment.

Returns:

  • (TD::Types::String)

    the current value of currency



11
12
13
# File 'lib/tdlib/types/premium_payment_option.rb', line 11

def currency
  @currency
end

#discount_percentageInteger

The discount associated with this option, as a percentage.

Returns:

  • (Integer)

    the current value of discount_percentage



11
12
13
# File 'lib/tdlib/types/premium_payment_option.rb', line 11

def discount_percentage
  @discount_percentage
end

#month_countInteger

Number of months the Telegram Premium subscription will be active.

Returns:

  • (Integer)

    the current value of month_count



11
12
13
# File 'lib/tdlib/types/premium_payment_option.rb', line 11

def month_count
  @month_count
end

An internal link to be opened for buying Telegram Premium to the user if store payment isn’t possible; may be null if direct payment isn’t available.

Returns:



11
12
13
# File 'lib/tdlib/types/premium_payment_option.rb', line 11

def payment_link
  @payment_link
end

#store_product_idTD::Types::String

Identifier of the store product associated with the option.

Returns:

  • (TD::Types::String)

    the current value of store_product_id



11
12
13
# File 'lib/tdlib/types/premium_payment_option.rb', line 11

def store_product_id
  @store_product_id
end