class

Stripe::SubscriptionDataParams

Inherits OpenApi::Json < OpenApi::Validatable < JSON::Serializable::Unmapped < JSON::Serializable < Reference < Object

Constants

ERROR_MESSAGE_FOR_PRORATION_BEHAVIOR = "invalid value for \"proration_behavior\", must be one of [create_prorations, none]."
MAX_LENGTH_FOR_DESCRIPTION = 500
VALID_VALUES_FOR_PRORATION_BEHAVIOR = String.static_array("create_prorations", "none")

Constructors

new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source
new(*, application_fee_percent : Float64 | Nil = nil, billing_cycle_anchor : Int64 | Nil = nil, default_tax_rates : Array(String) | Nil = nil, description : String | Nil = nil, invoice_settings : Stripe::SubscriptionDataInvoiceSettingsParams | Nil = nil, metadata : Hash(String, String) | Nil = nil, on_behalf_of : String | Nil = nil, proration_behavior : String | Nil = nil, transfer_data : Stripe::TransferDataSpecs | Nil = nil, trial_end : Int64 | Nil = nil, trial_period_days : Int64 | Nil = nil, trial_settings : Stripe::TrialSettingsConfig | Nil = nil)

Initializes the object @param [Hash] attributes Model attributes in the form of hash

Source

Instance methods

==(other : self)

Generates #hash and #== methods from all fields #== @return [Bool] #hash calculates hash code according to all attributes. #hash @return [UInt64] Hash code

application_fee_percent

A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. To use an application fee percent, the request must be made on behalf of another account, using the Stripe-Account header or an OAuth key. For more information, see the application fees documentation.

Source
application_fee_percent=(new_value : Float64 | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] application_fee_percent Object to be assigned

Source
billing_cycle_anchor

A future timestamp to anchor the subscription's billing cycle for new subscriptions.

Source
billing_cycle_anchor=(new_value : Int64 | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] billing_cycle_anchor Object to be assigned

Source
default_tax_rates

The tax rates that will apply to any subscription item that does not have tax_rates set. Invoices created will have their default_tax_rates populated from the subscription.

Source
default_tax_rates=(new_value : Array(String) | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] default_tax_rates Object to be assigned

Source
description

The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.

Source
description=(new_value : String | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] description Object to be assigned

Source
hash(hasher)

Generates #hash and #== methods from all fields #== @return [Bool] #hash calculates hash code according to all attributes. #hash @return [UInt64] Hash code

invoice_settings
Source
invoice_settings=(new_value : Stripe::SubscriptionDataInvoiceSettingsParams | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] invoice_settings Object to be assigned

Source
list_invalid_properties

Show invalid properties with the reasons. Usually used together with valid? @return Array for valid properties with the reasons

Source
metadata
Source
metadata=(new_value : Hash(String, String) | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] metadata Object to be assigned

Source
on_behalf_of

The account on behalf of which to charge, for each of the subscription's invoices.

Source
on_behalf_of=(new_value : String | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] on_behalf_of Object to be assigned

Source
proration_behavior

Determines how to handle prorations resulting from the billing_cycle_anchor. If no value is passed, the default is create_prorations.

Source
proration_behavior=(new_value : String | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] proration_behavior Object to be assigned

Source
transfer_data
Source
transfer_data=(new_value : Stripe::TransferDataSpecs | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] transfer_data Object to be assigned

Source
trial_end

Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. Has to be at least 48 hours in the future.

Source
trial_end=(new_value : Int64 | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] trial_end Object to be assigned

Source
trial_period_days

Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.

Source
trial_period_days=(new_value : Int64 | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] trial_period_days Object to be assigned

Source
trial_settings
Source
trial_settings=(new_value : Stripe::TrialSettingsConfig | Nil)

Custom attribute writer method checking allowed values (enum). @param [Object] trial_settings Object to be assigned

Source
valid?

Check to see if the all the properties in the model are valid @return true if the model is valid

Source