Class: Stripe::PaymentIntent::CaptureParams::AmountDetails

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/resources/payment_intent.rb

Defined Under Namespace

Classes: LineItem, Shipping, Tax

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil) ⇒ AmountDetails

Returns a new instance of AmountDetails.



11200
11201
11202
11203
11204
11205
# File 'lib/stripe/resources/payment_intent.rb', line 11200

def initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil)
  @discount_amount = discount_amount
  @line_items = line_items
  @shipping = shipping
  @tax = tax
end

Instance Attribute Details

#discount_amountObject

The amount an item was discounted for.



11192
11193
11194
# File 'lib/stripe/resources/payment_intent.rb', line 11192

def discount_amount
  @discount_amount
end

#line_itemsObject

A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.



11194
11195
11196
# File 'lib/stripe/resources/payment_intent.rb', line 11194

def line_items
  @line_items
end

#shippingObject

Contains information about the shipping portion of the amount.



11196
11197
11198
# File 'lib/stripe/resources/payment_intent.rb', line 11196

def shipping
  @shipping
end

#taxObject

Contains information about the tax portion of the amount.



11198
11199
11200
# File 'lib/stripe/resources/payment_intent.rb', line 11198

def tax
  @tax
end