Class: Stripe::Quote::UpdateParams

Inherits:
RequestParams show all
Defined in:
lib/stripe/resources/quote.rb

Defined Under Namespace

Classes: AutomaticTax, Discount, InvoiceSettings, Line, LineItem, SubscriptionData, SubscriptionDataOverride, TransferData

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(allow_backdated_lines: nil, application_fee_amount: nil, application_fee_percent: nil, automatic_tax: nil, collection_method: nil, customer: nil, customer_account: nil, default_tax_rates: nil, description: nil, discounts: nil, expand: nil, expires_at: nil, footer: nil, header: nil, invoice_settings: nil, line_items: nil, lines: nil, metadata: nil, on_behalf_of: nil, subscription_data: nil, subscription_data_overrides: nil, transfer_data: nil) ⇒ UpdateParams

Returns a new instance of UpdateParams.



2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
# File 'lib/stripe/resources/quote.rb', line 2618

def initialize(
  allow_backdated_lines: nil,
  application_fee_amount: nil,
  application_fee_percent: nil,
  automatic_tax: nil,
  collection_method: nil,
  customer: nil,
  customer_account: nil,
  default_tax_rates: nil,
  description: nil,
  discounts: nil,
  expand: nil,
  expires_at: nil,
  footer: nil,
  header: nil,
  invoice_settings: nil,
  line_items: nil,
  lines: nil,
  metadata: nil,
  on_behalf_of: nil,
  subscription_data: nil,
  subscription_data_overrides: nil,
  transfer_data: nil
)
  @allow_backdated_lines = allow_backdated_lines
  @application_fee_amount = application_fee_amount
  @application_fee_percent = application_fee_percent
  @automatic_tax = automatic_tax
  @collection_method = collection_method
  @customer = customer
  @customer_account = 
  @default_tax_rates = default_tax_rates
  @description = description
  @discounts = discounts
  @expand = expand
  @expires_at = expires_at
  @footer = footer
  @header = header
  @invoice_settings = invoice_settings
  @line_items = line_items
  @lines = lines
  @metadata = 
  @on_behalf_of = on_behalf_of
  @subscription_data = subscription_data
  @subscription_data_overrides = subscription_data_overrides
  @transfer_data = transfer_data
end

Instance Attribute Details

#allow_backdated_linesObject

Set to true to allow quote lines to have ‘starts_at` in the past if collection is paused between `starts_at` and now.



2574
2575
2576
# File 'lib/stripe/resources/quote.rb', line 2574

def allow_backdated_lines
  @allow_backdated_lines
end

#application_fee_amountObject

The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner’s Stripe account. There cannot be any line items with recurring prices when using this field.



2576
2577
2578
# File 'lib/stripe/resources/quote.rb', line 2576

def application_fee_amount
  @application_fee_amount
end

#application_fee_percentObject

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. There must be at least 1 line item with a recurring price to use this field.



2578
2579
2580
# File 'lib/stripe/resources/quote.rb', line 2578

def application_fee_percent
  @application_fee_percent
end

#automatic_taxObject

Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.



2580
2581
2582
# File 'lib/stripe/resources/quote.rb', line 2580

def automatic_tax
  @automatic_tax
end

#collection_methodObject

Either ‘charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.



2582
2583
2584
# File 'lib/stripe/resources/quote.rb', line 2582

def collection_method
  @collection_method
end

#customerObject

The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.



2584
2585
2586
# File 'lib/stripe/resources/quote.rb', line 2584

def customer
  @customer
end

#customer_accountObject

The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.



2586
2587
2588
# File 'lib/stripe/resources/quote.rb', line 2586

def 
  @customer_account
end

#default_tax_ratesObject

The tax rates that will apply to any line item that does not have ‘tax_rates` set.



2588
2589
2590
# File 'lib/stripe/resources/quote.rb', line 2588

def default_tax_rates
  @default_tax_rates
end

#descriptionObject

A description that will be displayed on the quote PDF.



2590
2591
2592
# File 'lib/stripe/resources/quote.rb', line 2590

def description
  @description
end

#discountsObject

The discounts applied to the quote.



2592
2593
2594
# File 'lib/stripe/resources/quote.rb', line 2592

def discounts
  @discounts
end

#expandObject

Specifies which fields in the response should be expanded.



2594
2595
2596
# File 'lib/stripe/resources/quote.rb', line 2594

def expand
  @expand
end

#expires_atObject

A future timestamp on which the quote will be canceled if in ‘open` or `draft` status. Measured in seconds since the Unix epoch.



2596
2597
2598
# File 'lib/stripe/resources/quote.rb', line 2596

def expires_at
  @expires_at
end

A footer that will be displayed on the quote PDF.



2598
2599
2600
# File 'lib/stripe/resources/quote.rb', line 2598

def footer
  @footer
end

#headerObject

A header that will be displayed on the quote PDF.



2600
2601
2602
# File 'lib/stripe/resources/quote.rb', line 2600

def header
  @header
end

#invoice_settingsObject

All invoices will be billed using the specified settings.



2602
2603
2604
# File 'lib/stripe/resources/quote.rb', line 2602

def invoice_settings
  @invoice_settings
end

#line_itemsObject

A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.



2604
2605
2606
# File 'lib/stripe/resources/quote.rb', line 2604

def line_items
  @line_items
end

#linesObject

A list of [quote lines](docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.



2606
2607
2608
# File 'lib/stripe/resources/quote.rb', line 2606

def lines
  @lines
end

#metadataObject

Set of [key-value pairs](stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to ‘metadata`.



2608
2609
2610
# File 'lib/stripe/resources/quote.rb', line 2608

def 
  @metadata
end

#on_behalf_ofObject

The account on behalf of which to charge.



2610
2611
2612
# File 'lib/stripe/resources/quote.rb', line 2610

def on_behalf_of
  @on_behalf_of
end

#subscription_dataObject

When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if ‘subscription_data` is present and in the future, otherwise a subscription is created.



2612
2613
2614
# File 'lib/stripe/resources/quote.rb', line 2612

def subscription_data
  @subscription_data
end

#subscription_data_overridesObject

List representing overrides for ‘subscription_data` configurations for specific subscription schedules.



2614
2615
2616
# File 'lib/stripe/resources/quote.rb', line 2614

def subscription_data_overrides
  @subscription_data_overrides
end

#transfer_dataObject

The data with which to automatically create a Transfer for each of the invoices.



2616
2617
2618
# File 'lib/stripe/resources/quote.rb', line 2616

def transfer_data
  @transfer_data
end