Class: Google::Apis::PaymentsresellersubscriptionV1::Promotion
- Inherits:
-
Object
- Object
- Google::Apis::PaymentsresellersubscriptionV1::Promotion
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/paymentsresellersubscription_v1/classes.rb,
lib/google/apis/paymentsresellersubscription_v1/representations.rb,
lib/google/apis/paymentsresellersubscription_v1/representations.rb
Overview
A Promotion resource that defines a promotion for a subscription that can be resold.
Instance Attribute Summary collapse
-
#applicable_products ⇒ Array<String>
Output only.
-
#end_time ⇒ String
Optional.
-
#free_trial_duration ⇒ Google::Apis::PaymentsresellersubscriptionV1::Duration
Describes the length of a period of a time.
-
#introductory_pricing_details ⇒ Google::Apis::PaymentsresellersubscriptionV1::PromotionIntroductoryPricingDetails
The details of a introductory pricing promotion.
-
#name ⇒ String
Identifier.
-
#promotion_type ⇒ String
Output only.
-
#region_codes ⇒ Array<String>
Output only.
-
#start_time ⇒ String
Optional.
-
#titles ⇒ Array<Google::Apis::PaymentsresellersubscriptionV1::GoogleTypeLocalizedText>
Output only.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Promotion
constructor
A new instance of Promotion.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Promotion
Returns a new instance of Promotion.
980 981 982 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 980 def initialize(**args) update!(**args) end |
Instance Attribute Details
#applicable_products ⇒ Array<String>
Output only. The product ids this promotion can be applied to.
Corresponds to the JSON property applicableProducts
934 935 936 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 934 def applicable_products @applicable_products end |
#end_time ⇒ String
Optional. Specifies the end time (exclusive) of the period that the promotion
is available in. If unset, the promotion is available indefinitely.
Corresponds to the JSON property endTime
940 941 942 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 940 def end_time @end_time end |
#free_trial_duration ⇒ Google::Apis::PaymentsresellersubscriptionV1::Duration
Describes the length of a period of a time.
Corresponds to the JSON property freeTrialDuration
945 946 947 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 945 def free_trial_duration @free_trial_duration end |
#introductory_pricing_details ⇒ Google::Apis::PaymentsresellersubscriptionV1::PromotionIntroductoryPricingDetails
The details of a introductory pricing promotion.
Corresponds to the JSON property introductoryPricingDetails
950 951 952 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 950 def introductory_pricing_details @introductory_pricing_details end |
#name ⇒ String
Identifier. Response only. Resource name of the subscription promotion. It
will have the format of "partners/partner_id/promotion/promotion_id"
Corresponds to the JSON property name
956 957 958 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 956 def name @name end |
#promotion_type ⇒ String
Output only. Specifies the type of the promotion.
Corresponds to the JSON property promotionType
961 962 963 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 961 def promotion_type @promotion_type end |
#region_codes ⇒ Array<String>
Output only. 2-letter ISO region code where the promotion is available in. Ex.
"US" Please refers to: https://en.wikipedia.org/wiki/ISO_3166-1
Corresponds to the JSON property regionCodes
967 968 969 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 967 def region_codes @region_codes end |
#start_time ⇒ String
Optional. Specifies the start time (inclusive) of the period that the
promotion is available in.
Corresponds to the JSON property startTime
973 974 975 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 973 def start_time @start_time end |
#titles ⇒ Array<Google::Apis::PaymentsresellersubscriptionV1::GoogleTypeLocalizedText>
Output only. Localized human readable name of the promotion.
Corresponds to the JSON property titles
978 979 980 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 978 def titles @titles end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
985 986 987 988 989 990 991 992 993 994 995 |
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 985 def update!(**args) @applicable_products = args[:applicable_products] if args.key?(:applicable_products) @end_time = args[:end_time] if args.key?(:end_time) @free_trial_duration = args[:free_trial_duration] if args.key?(:free_trial_duration) @introductory_pricing_details = args[:introductory_pricing_details] if args.key?(:introductory_pricing_details) @name = args[:name] if args.key?(:name) @promotion_type = args[:promotion_type] if args.key?(:promotion_type) @region_codes = args[:region_codes] if args.key?(:region_codes) @start_time = args[:start_time] if args.key?(:start_time) @titles = args[:titles] if args.key?(:titles) end |