Class: Stripe::InvoiceService::UpdateLinesParams::Line::TaxAmount

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/services/invoice_service.rb

Defined Under Namespace

Classes: TaxRateData

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(amount: nil, tax_rate_data: nil, taxable_amount: nil) ⇒ TaxAmount

Returns a new instance of TaxAmount.



3805
3806
3807
3808
3809
# File 'lib/stripe/services/invoice_service.rb', line 3805

def initialize(amount: nil, tax_rate_data: nil, taxable_amount: nil)
  @amount = amount
  @tax_rate_data = tax_rate_data
  @taxable_amount = taxable_amount
end

Instance Attribute Details

#amountObject

The amount, in cents (or local equivalent), of the tax.



3797
3798
3799
# File 'lib/stripe/services/invoice_service.rb', line 3797

def amount
  @amount
end

#tax_rate_dataObject

Data to find or create a TaxRate object.

Stripe automatically creates or reuses a TaxRate object for each tax amount. If the ‘tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.



3801
3802
3803
# File 'lib/stripe/services/invoice_service.rb', line 3801

def tax_rate_data
  @tax_rate_data
end

#taxable_amountObject

The amount on which tax is calculated, in cents (or local equivalent).



3803
3804
3805
# File 'lib/stripe/services/invoice_service.rb', line 3803

def taxable_amount
  @taxable_amount
end