Class: Stripe::PriceCreateParams::Recurring
- Inherits:
-
RequestParams
- Object
- RequestParams
- Stripe::PriceCreateParams::Recurring
- Defined in:
- lib/stripe/params/price_create_params.rb
Instance Attribute Summary collapse
-
#interval ⇒ Object
Specifies billing frequency.
-
#interval_count ⇒ Object
The number of intervals between subscription billings.
-
#meter ⇒ Object
The meter tracking the usage of a metered price.
-
#trial_period_days ⇒ Object
Default number of trial days when subscribing a customer to this price using [‘trial_from_plan=true`](stripe.com/docs/api#create_subscription-trial_from_plan).
-
#usage_type ⇒ Object
Configures how the quantity per period should be determined.
Instance Method Summary collapse
-
#initialize(interval: nil, interval_count: nil, meter: nil, trial_period_days: nil, usage_type: nil) ⇒ Recurring
constructor
A new instance of Recurring.
Methods inherited from RequestParams
Constructor Details
#initialize(interval: nil, interval_count: nil, meter: nil, trial_period_days: nil, usage_type: nil) ⇒ Recurring
Returns a new instance of Recurring.
144 145 146 147 148 149 150 151 152 153 154 155 156 |
# File 'lib/stripe/params/price_create_params.rb', line 144 def initialize( interval: nil, interval_count: nil, meter: nil, trial_period_days: nil, usage_type: nil ) @interval = interval @interval_count = interval_count @meter = meter @trial_period_days = trial_period_days @usage_type = usage_type end |
Instance Attribute Details
#interval ⇒ Object
Specifies billing frequency. Either ‘day`, `week`, `month` or `year`.
134 135 136 |
# File 'lib/stripe/params/price_create_params.rb', line 134 def interval @interval end |
#interval_count ⇒ Object
The number of intervals between subscription billings. For example, ‘interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
136 137 138 |
# File 'lib/stripe/params/price_create_params.rb', line 136 def interval_count @interval_count end |
#meter ⇒ Object
The meter tracking the usage of a metered price
138 139 140 |
# File 'lib/stripe/params/price_create_params.rb', line 138 def meter @meter end |
#trial_period_days ⇒ Object
Default number of trial days when subscribing a customer to this price using [‘trial_from_plan=true`](stripe.com/docs/api#create_subscription-trial_from_plan).
140 141 142 |
# File 'lib/stripe/params/price_create_params.rb', line 140 def trial_period_days @trial_period_days end |
#usage_type ⇒ Object
Configures how the quantity per period should be determined. Can be either ‘metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
142 143 144 |
# File 'lib/stripe/params/price_create_params.rb', line 142 def usage_type @usage_type end |