Class: Google::Apis::AndroidpublisherV2::SubscriptionPriceChange

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/androidpublisher_v2/classes.rb,
generated/google/apis/androidpublisher_v2/representations.rb,
generated/google/apis/androidpublisher_v2/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

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ SubscriptionPriceChange

Returns a new instance of SubscriptionPriceChange



1407
1408
1409
# File 'generated/google/apis/androidpublisher_v2/classes.rb', line 1407

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

Instance Attribute Details

#new_priceGoogle::Apis::AndroidpublisherV2::Price

The new price the subscription will renew with if the price change is accepted by the user. Corresponds to the JSON property newPrice



1393
1394
1395
# File 'generated/google/apis/androidpublisher_v2/classes.rb', line 1393

def new_price
  @new_price
end

#stateFixnum

The current state of the price change. Possible values are:

  • 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.
  • 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)


1405
1406
1407
# File 'generated/google/apis/androidpublisher_v2/classes.rb', line 1405

def state
  @state
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1412
1413
1414
1415
# File 'generated/google/apis/androidpublisher_v2/classes.rb', line 1412

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