Class: Google::Apis::AndroidpublisherV3::SubscriptionPriceChange

Inherits:
Object
  • Object
show all
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

Contains the price change information for a subscription that can be used to control the user journey for the price change in the app. This can be in the form of seeking confirmation from the user or tailoring the experience for a successful conversion.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ SubscriptionPriceChange

Returns a new instance of SubscriptionPriceChange.



5713
5714
5715
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 5713

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#new_priceGoogle::Apis::AndroidpublisherV3::Price

Definition of a price, i.e. currency and units. Corresponds to the JSON property newPrice



5700
5701
5702
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 5700

def new_price
  @new_price
end

#stateFixnum

The current state of the price change. Possible values are: 0. Outstanding: State for a pending price change waiting for the user to agree. In this state, you can optionally seek confirmation from the user using the In-App API. 1. Accepted: State for an accepted price change that the subscription will renew with unless it's canceled. The price change takes effect on a future date when the subscription renews. Note that the change might not occur when the subscription is renewed next. Corresponds to the JSON property state

Returns:

  • (Fixnum)


5711
5712
5713
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 5711

def state
  @state
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5718
5719
5720
5721
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 5718

def update!(**args)
  @new_price = args[:new_price] if args.key?(:new_price)
  @state = args[:state] if args.key?(:state)
end