class Venice::PendingRenewalInfo
Attributes
The current renewal preference for the auto-renewable subscription. The value for this key corresponds to the productIdentifier property of the product that the customer’s subscription renews.
The current renewal status for the auto-renewable subscription. This key is only present for auto-renewable subscription receipts, for active or expired subscriptions
For a transaction that was cancelled, the reason for cancellation. Use this value along with the cancellation date to identify possible issues in your app that may lead customers to contact Apple customer support.
For an expired subscription, the reason for the subscription expiration. This key is only present for a receipt containing an expired auto-renewable subscription.
For an expired subscription, whether or not Apple is still attempting to automatically renew the subscription. If the customer’s subscription failed to renew because the App Store was unable to complete the transaction, this value will reflect whether or not the App Store is still trying to renew the subscription.
Original JSON data returned from Apple for a PendingRenewalInfo
object.
The current price consent status for a subscription price increase This key is only present for auto-renewable subscription receipts if the subscription price was increased without keeping the existing price for active subscribers
The product identifier of the item that was purchased. This value corresponds to the productIdentifier property of the SKPayment object stored in the transaction’s payment property.
Public Class Methods
# File lib/venice/pending_renewal_info.rb, line 34 def initialize(attributes) @original_json_data = attributes @expiration_intent = Integer(attributes['expiration_intent']) if attributes['expiration_intent'] @auto_renew_status = Integer(attributes['auto_renew_status']) if attributes['auto_renew_status'] @auto_renew_product_id = attributes['auto_renew_product_id'] if attributes['is_in_billing_retry_period'] @is_in_billing_retry_period = (attributes['is_in_billing_retry_period'] == '1') end @product_id = attributes['product_id'] @price_consent_status = Integer(attributes['price_consent_status']) if attributes['price_consent_status'] @cancellation_reason = Integer(attributes['cancellation_reason']) if attributes['cancellation_reason'] end
Public Instance Methods
# File lib/venice/pending_renewal_info.rb, line 50 def to_hash { expiration_intent: @expiration_intent, auto_renew_status: @auto_renew_status, auto_renew_product_id: @auto_renew_product_id, is_in_billing_retry_period: @is_in_billing_retry_period, product_id: @product_id, price_consent_status: @price_consent_status, cancellation_reason: @cancellation_reason } end
# File lib/venice/pending_renewal_info.rb, line 64 def to_json to_hash.to_json end