Class: Google::Apis::AndroidpublisherV3::SubscriptionOffer
- Inherits:
-
Object
- Object
- Google::Apis::AndroidpublisherV3::SubscriptionOffer
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/androidpublisher_v3/classes.rb,
lib/google/apis/androidpublisher_v3/representations.rb,
lib/google/apis/androidpublisher_v3/representations.rb
Overview
A single, temporary offer
Instance Attribute Summary collapse
-
#base_plan_id ⇒ String
Required.
-
#offer_id ⇒ String
Required.
-
#offer_tags ⇒ Array<Google::Apis::AndroidpublisherV3::OfferTag>
List of up to 20 custom tags specified for this offer, and returned to the app through the billing library.
-
#other_regions_config ⇒ Google::Apis::AndroidpublisherV3::OtherRegionsSubscriptionOfferConfig
Configuration for any new locations Play may launch in specified on a subscription offer.
-
#package_name ⇒ String
Required.
-
#phases ⇒ Array<Google::Apis::AndroidpublisherV3::SubscriptionOfferPhase>
Required.
-
#product_id ⇒ String
Required.
-
#regional_configs ⇒ Array<Google::Apis::AndroidpublisherV3::RegionalSubscriptionOfferConfig>
Required.
-
#state ⇒ String
Output only.
-
#targeting ⇒ Google::Apis::AndroidpublisherV3::SubscriptionOfferTargeting
Defines the rule a user needs to satisfy to receive this offer.
Instance Method Summary collapse
-
#initialize(**args) ⇒ SubscriptionOffer
constructor
A new instance of SubscriptionOffer.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ SubscriptionOffer
Returns a new instance of SubscriptionOffer.
8491 8492 8493 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8491 def initialize(**args) update!(**args) end |
Instance Attribute Details
#base_plan_id ⇒ String
Required. Immutable. The ID of the base plan to which this offer is an
extension.
Corresponds to the JSON property basePlanId
8435 8436 8437 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8435 def base_plan_id @base_plan_id end |
#offer_id ⇒ String
Required. Immutable. Unique ID of this subscription offer. Must be unique
within the base plan.
Corresponds to the JSON property offerId
8441 8442 8443 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8441 def offer_id @offer_id end |
#offer_tags ⇒ Array<Google::Apis::AndroidpublisherV3::OfferTag>
List of up to 20 custom tags specified for this offer, and returned to the app
through the billing library.
Corresponds to the JSON property offerTags
8447 8448 8449 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8447 def @offer_tags end |
#other_regions_config ⇒ Google::Apis::AndroidpublisherV3::OtherRegionsSubscriptionOfferConfig
Configuration for any new locations Play may launch in specified on a
subscription offer.
Corresponds to the JSON property otherRegionsConfig
8453 8454 8455 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8453 def other_regions_config @other_regions_config end |
#package_name ⇒ String
Required. Immutable. The package name of the app the parent subscription
belongs to.
Corresponds to the JSON property packageName
8459 8460 8461 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8459 def package_name @package_name end |
#phases ⇒ Array<Google::Apis::AndroidpublisherV3::SubscriptionOfferPhase>
Required. The phases of this subscription offer. Must contain at least one and
at most two entries. Users will always receive all these phases in the
specified order.
Corresponds to the JSON property phases
8466 8467 8468 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8466 def phases @phases end |
#product_id ⇒ String
Required. Immutable. The ID of the parent subscription this offer belongs to.
Corresponds to the JSON property productId
8471 8472 8473 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8471 def product_id @product_id end |
#regional_configs ⇒ Array<Google::Apis::AndroidpublisherV3::RegionalSubscriptionOfferConfig>
Required. The region-specific configuration of this offer. Must contain at
least one entry.
Corresponds to the JSON property regionalConfigs
8477 8478 8479 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8477 def regional_configs @regional_configs end |
#state ⇒ String
Output only. The current state of this offer. Can be changed using Activate
and Deactivate actions. NB: the base plan state supersedes this state, so an
active offer may not be available if the base plan is not active.
Corresponds to the JSON property state
8484 8485 8486 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8484 def state @state end |
#targeting ⇒ Google::Apis::AndroidpublisherV3::SubscriptionOfferTargeting
Defines the rule a user needs to satisfy to receive this offer.
Corresponds to the JSON property targeting
8489 8490 8491 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8489 def targeting @targeting end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
8496 8497 8498 8499 8500 8501 8502 8503 8504 8505 8506 8507 |
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 8496 def update!(**args) @base_plan_id = args[:base_plan_id] if args.key?(:base_plan_id) @offer_id = args[:offer_id] if args.key?(:offer_id) @offer_tags = args[:offer_tags] if args.key?(:offer_tags) @other_regions_config = args[:other_regions_config] if args.key?(:other_regions_config) @package_name = args[:package_name] if args.key?(:package_name) @phases = args[:phases] if args.key?(:phases) @product_id = args[:product_id] if args.key?(:product_id) @regional_configs = args[:regional_configs] if args.key?(:regional_configs) @state = args[:state] if args.key?(:state) @targeting = args[:targeting] if args.key?(:targeting) end |