Class: Stripe::QuoteLine

Inherits:
APIResource show all
Defined in:
lib/stripe/resources/quote_line.rb

Overview

A quote line defines a set of changes, in the order provided, that will be applied upon quote acceptance.

Defined Under Namespace

Classes: Action, AppliesTo, CancelSubscriptionSchedule, EndsAt, SetPauseCollection, StartsAt, TrialSettings

Constant Summary collapse

OBJECT_NAME =
"quote_line"

Constants inherited from StripeObject

StripeObject::RESERVED_FIELD_NAMES

Instance Attribute Summary collapse

Attributes inherited from APIResource

#save_with_parent

Attributes inherited from StripeObject

#last_response

Class Method Summary collapse

Methods inherited from APIResource

class_name, custom_method, #refresh, #request_stripe_object, resource_url, #resource_url, retrieve, save_nested_resource

Methods included from APIOperations::Request

included

Methods inherited from StripeObject

#==, #[], #[]=, additive_object_param, additive_object_param?, #as_json, construct_from, #deleted?, #dirty!, #each, #eql?, #hash, #initialize, #inspect, #keys, #marshal_dump, #marshal_load, protected_fields, #serialize_params, #to_hash, #to_json, #to_s, #update_attributes, #values

Constructor Details

This class inherits a constructor from Stripe::StripeObject

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Stripe::StripeObject

Instance Attribute Details

#actionsObject (readonly)

A list of items the customer is being quoted for.



305
306
307
# File 'lib/stripe/resources/quote_line.rb', line 305

def actions
  @actions
end

#applies_toObject (readonly)

Details to identify the subscription schedule the quote line applies to.



308
309
310
# File 'lib/stripe/resources/quote_line.rb', line 308

def applies_to
  @applies_to
end

#billing_cycle_anchorObject (readonly)

For point-in-time quote lines (having no ‘ends_at` timestamp), this attribute lets you set or remove whether the subscription’s billing cycle anchor is reset at the Quote Line ‘starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.



311
312
313
# File 'lib/stripe/resources/quote_line.rb', line 311

def billing_cycle_anchor
  @billing_cycle_anchor
end

#cancel_subscription_scheduleObject (readonly)

A point-in-time operation that cancels an existing subscription schedule at the line’s starts_at timestamp. Currently only compatible with ‘quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.



314
315
316
# File 'lib/stripe/resources/quote_line.rb', line 314

def cancel_subscription_schedule
  @cancel_subscription_schedule
end

#ends_atObject (readonly)

Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at ‘starts_at`, and a restricted set of attributes is supported on the quote line.



317
318
319
# File 'lib/stripe/resources/quote_line.rb', line 317

def ends_at
  @ends_at
end

#idObject (readonly)

Unique identifier for the object.



320
321
322
# File 'lib/stripe/resources/quote_line.rb', line 320

def id
  @id
end

#objectObject (readonly)

String representing the object’s type. Objects of the same type share the same value.



323
324
325
# File 'lib/stripe/resources/quote_line.rb', line 323

def object
  @object
end

#proration_behaviorObject (readonly)

Changes to how Stripe handles prorations during the quote line’s time span. Affects if and how prorations are created when a future phase starts.



326
327
328
# File 'lib/stripe/resources/quote_line.rb', line 326

def proration_behavior
  @proration_behavior
end

#set_pause_collectionObject (readonly)

Details to modify the pause_collection behavior of the subscription schedule.



329
330
331
# File 'lib/stripe/resources/quote_line.rb', line 329

def set_pause_collection
  @set_pause_collection
end

#set_schedule_endObject (readonly)

Timestamp helper to end the underlying schedule early, based on the acompanying line’s start or end date.



332
333
334
# File 'lib/stripe/resources/quote_line.rb', line 332

def set_schedule_end
  @set_schedule_end
end

#starts_atObject (readonly)

Details to identify the earliest timestamp where the proposed change should take effect.



335
336
337
# File 'lib/stripe/resources/quote_line.rb', line 335

def starts_at
  @starts_at
end

#trial_settingsObject (readonly)

Settings related to subscription trials.



338
339
340
# File 'lib/stripe/resources/quote_line.rb', line 338

def trial_settings
  @trial_settings
end

Class Method Details

.object_nameObject



8
9
10
# File 'lib/stripe/resources/quote_line.rb', line 8

def self.object_name
  "quote_line"
end