stripe 15.4.0.pre.beta.2 → 15.5.0.pre.beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/API_VERSION +1 -1
- data/CHANGELOG.md +61 -5
- data/OPENAPI_VERSION +1 -1
- data/README.md +1 -1
- data/VERSION +1 -1
- data/lib/stripe/api_version.rb +1 -1
- data/lib/stripe/event_types.rb +2 -2
- data/lib/stripe/events/{v2_core_account_link_completed_event.rb → v2_core_account_link_returned_event.rb} +2 -2
- data/lib/stripe/events/{v2_off_session_payment_requires_capture_event.rb → v2_money_management_payout_method_updated_event.rb} +3 -3
- data/lib/stripe/events/v2_payments_off_session_payment_authorization_attempt_failed_event.rb +1 -1
- data/lib/stripe/events/v2_payments_off_session_payment_authorization_attempt_started_event.rb +2 -1
- data/lib/stripe/events/v2_payments_off_session_payment_canceled_event.rb +1 -1
- data/lib/stripe/events/v2_payments_off_session_payment_created_event.rb +1 -1
- data/lib/stripe/events/v2_payments_off_session_payment_failed_event.rb +1 -1
- data/lib/stripe/events/v2_payments_off_session_payment_succeeded_event.rb +1 -1
- data/lib/stripe/object_types.rb +3 -0
- data/lib/stripe/resources/account.rb +5 -5
- data/lib/stripe/resources/account_link.rb +3 -1
- data/lib/stripe/resources/account_session.rb +51 -0
- data/lib/stripe/resources/balance_settings.rb +13 -13
- data/lib/stripe/resources/billing/credit_grant.rb +1 -1
- data/lib/stripe/resources/billing/meter_usage.rb +23 -0
- data/lib/stripe/resources/billing/meter_usage_row.rb +28 -0
- data/lib/stripe/resources/billing_portal/configuration.rb +46 -2
- data/lib/stripe/resources/charge.rb +7 -5
- data/lib/stripe/resources/checkout/session.rb +106 -6
- data/lib/stripe/resources/confirmation_token.rb +3 -3
- data/lib/stripe/resources/customer.rb +1 -1
- data/lib/stripe/resources/dispute.rb +10 -1
- data/lib/stripe/resources/event.rb +14 -26
- data/lib/stripe/resources/fx_quote.rb +6 -4
- data/lib/stripe/resources/invoice.rb +101 -8
- data/lib/stripe/resources/invoice_item.rb +1 -1
- data/lib/stripe/resources/payment_attempt_record.rb +6 -4
- data/lib/stripe/resources/payment_intent.rb +815 -4
- data/lib/stripe/resources/payment_link.rb +83 -5
- data/lib/stripe/resources/payment_method.rb +4 -4
- data/lib/stripe/resources/payment_record.rb +6 -4
- data/lib/stripe/resources/quote.rb +1 -1
- data/lib/stripe/resources/quote_preview_invoice.rb +17 -0
- data/lib/stripe/resources/radar/value_list.rb +2 -2
- data/lib/stripe/resources/refund.rb +1 -1
- data/lib/stripe/resources/review.rb +2 -2
- data/lib/stripe/resources/setup_attempt.rb +1 -1
- data/lib/stripe/resources/subscription.rb +79 -2
- data/lib/stripe/resources/subscription_item.rb +2 -2
- data/lib/stripe/resources/subscription_schedule.rb +35 -3
- data/lib/stripe/resources/tax/registration.rb +408 -30
- data/lib/stripe/resources/terminal/configuration.rb +196 -0
- data/lib/stripe/resources/terminal/onboarding_link.rb +84 -0
- data/lib/stripe/resources/v2/core/account.rb +11 -0
- data/lib/stripe/resources/v2/core/account_link.rb +18 -2
- data/lib/stripe/resources/v2/money_management/payout_method.rb +2 -0
- data/lib/stripe/resources/v2/payments/off_session_payment.rb +40 -23
- data/lib/stripe/resources.rb +5 -2
- data/lib/stripe/services/account_link_service.rb +3 -1
- data/lib/stripe/services/account_service.rb +3 -3
- data/lib/stripe/services/account_session_service.rb +34 -0
- data/lib/stripe/services/balance_settings_service.rb +10 -10
- data/lib/stripe/services/billing/credit_grant_service.rb +1 -1
- data/lib/stripe/services/billing/meter_usage_service.rb +76 -0
- data/lib/stripe/services/billing_portal/configuration_service.rb +36 -2
- data/lib/stripe/services/billing_service.rb +2 -1
- data/lib/stripe/services/checkout/session_service.rb +93 -5
- data/lib/stripe/services/invoice_item_service.rb +1 -1
- data/lib/stripe/services/invoice_service.rb +84 -8
- data/lib/stripe/services/payment_intent_service.rb +809 -3
- data/lib/stripe/services/payment_link_service.rb +81 -5
- data/lib/stripe/services/payment_method_service.rb +1 -1
- data/lib/stripe/services/quote_service.rb +1 -1
- data/lib/stripe/services/radar/value_list_service.rb +1 -1
- data/lib/stripe/services/subscription_item_service.rb +2 -2
- data/lib/stripe/services/subscription_schedule_service.rb +35 -3
- data/lib/stripe/services/subscription_service.rb +62 -2
- data/lib/stripe/services/tax/registration_service.rb +360 -30
- data/lib/stripe/services/terminal/configuration_service.rb +152 -0
- data/lib/stripe/services/terminal/onboarding_link_service.rb +56 -0
- data/lib/stripe/services/terminal_service.rb +2 -1
- data/lib/stripe/services/v2/core/account_link_service.rb +41 -3
- data/lib/stripe/services/v2/core/account_service.rb +38 -2
- data/lib/stripe/services/v2/payments/off_session_payment_service.rb +34 -19
- data/lib/stripe/services/v2/test_helpers/financial_address_service.rb +4 -0
- data/lib/stripe/services.rb +2 -0
- data/lib/stripe/version.rb +1 -1
- data/rbi/stripe.rbi +4893 -390
- metadata +9 -4
@@ -1932,7 +1932,7 @@ module Stripe
|
|
1932
1932
|
end
|
1933
1933
|
|
1934
1934
|
class PresentmentDetails < Stripe::StripeObject
|
1935
|
-
# Amount intended to be collected by this payment, denominated in presentment_currency
|
1935
|
+
# Amount intended to be collected by this payment, denominated in `presentment_currency`.
|
1936
1936
|
attr_reader :presentment_amount
|
1937
1937
|
# Currency presented to the customer during payment.
|
1938
1938
|
attr_reader :presentment_currency
|
@@ -2044,6 +2044,159 @@ module Stripe
|
|
2044
2044
|
end
|
2045
2045
|
|
2046
2046
|
class CreateParams < Stripe::RequestParams
|
2047
|
+
class AmountDetails < Stripe::RequestParams
|
2048
|
+
class LineItem < Stripe::RequestParams
|
2049
|
+
class PaymentMethodOptions < Stripe::RequestParams
|
2050
|
+
class Card < Stripe::RequestParams
|
2051
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
2052
|
+
attr_accessor :commodity_code
|
2053
|
+
|
2054
|
+
def initialize(commodity_code: nil)
|
2055
|
+
@commodity_code = commodity_code
|
2056
|
+
end
|
2057
|
+
end
|
2058
|
+
|
2059
|
+
class CardPresent < Stripe::RequestParams
|
2060
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
2061
|
+
attr_accessor :commodity_code
|
2062
|
+
|
2063
|
+
def initialize(commodity_code: nil)
|
2064
|
+
@commodity_code = commodity_code
|
2065
|
+
end
|
2066
|
+
end
|
2067
|
+
|
2068
|
+
class Klarna < Stripe::RequestParams
|
2069
|
+
# URL to an image for the product. Max length, 4096 characters.
|
2070
|
+
attr_accessor :image_url
|
2071
|
+
# URL to the product page. Max length, 4096 characters.
|
2072
|
+
attr_accessor :product_url
|
2073
|
+
# Reference for the subscription this line item is for.
|
2074
|
+
attr_accessor :subscription_reference
|
2075
|
+
|
2076
|
+
def initialize(image_url: nil, product_url: nil, subscription_reference: nil)
|
2077
|
+
@image_url = image_url
|
2078
|
+
@product_url = product_url
|
2079
|
+
@subscription_reference = subscription_reference
|
2080
|
+
end
|
2081
|
+
end
|
2082
|
+
|
2083
|
+
class Paypal < Stripe::RequestParams
|
2084
|
+
# Type of the line item.
|
2085
|
+
attr_accessor :category
|
2086
|
+
# Description of the line item.
|
2087
|
+
attr_accessor :description
|
2088
|
+
# The Stripe account ID of the connected account that sells the item.
|
2089
|
+
attr_accessor :sold_by
|
2090
|
+
|
2091
|
+
def initialize(category: nil, description: nil, sold_by: nil)
|
2092
|
+
@category = category
|
2093
|
+
@description = description
|
2094
|
+
@sold_by = sold_by
|
2095
|
+
end
|
2096
|
+
end
|
2097
|
+
# This sub-hash contains line item details that are specific to `card` payment method."
|
2098
|
+
attr_accessor :card
|
2099
|
+
# This sub-hash contains line item details that are specific to `card_present` payment method."
|
2100
|
+
attr_accessor :card_present
|
2101
|
+
# This sub-hash contains line item details that are specific to `klarna` payment method."
|
2102
|
+
attr_accessor :klarna
|
2103
|
+
# This sub-hash contains line item details that are specific to `paypal` payment method."
|
2104
|
+
attr_accessor :paypal
|
2105
|
+
|
2106
|
+
def initialize(card: nil, card_present: nil, klarna: nil, paypal: nil)
|
2107
|
+
@card = card
|
2108
|
+
@card_present = card_present
|
2109
|
+
@klarna = klarna
|
2110
|
+
@paypal = paypal
|
2111
|
+
end
|
2112
|
+
end
|
2113
|
+
|
2114
|
+
class Tax < Stripe::RequestParams
|
2115
|
+
# The total tax on an item. Non-negative integer.
|
2116
|
+
attr_accessor :total_tax_amount
|
2117
|
+
|
2118
|
+
def initialize(total_tax_amount: nil)
|
2119
|
+
@total_tax_amount = total_tax_amount
|
2120
|
+
end
|
2121
|
+
end
|
2122
|
+
# The amount an item was discounted for. Positive integer.
|
2123
|
+
attr_accessor :discount_amount
|
2124
|
+
# Payment method-specific information for line items.
|
2125
|
+
attr_accessor :payment_method_options
|
2126
|
+
# Unique identifier of the product. At most 12 characters long.
|
2127
|
+
attr_accessor :product_code
|
2128
|
+
# Name of the product. At most 100 characters long.
|
2129
|
+
attr_accessor :product_name
|
2130
|
+
# Number of items of the product. Positive integer.
|
2131
|
+
attr_accessor :quantity
|
2132
|
+
# Contains information about the tax on the item.
|
2133
|
+
attr_accessor :tax
|
2134
|
+
# Cost of the product. Non-negative integer.
|
2135
|
+
attr_accessor :unit_cost
|
2136
|
+
# A unit of measure for the line item, such as gallons, feet, meters, etc.
|
2137
|
+
attr_accessor :unit_of_measure
|
2138
|
+
|
2139
|
+
def initialize(
|
2140
|
+
discount_amount: nil,
|
2141
|
+
payment_method_options: nil,
|
2142
|
+
product_code: nil,
|
2143
|
+
product_name: nil,
|
2144
|
+
quantity: nil,
|
2145
|
+
tax: nil,
|
2146
|
+
unit_cost: nil,
|
2147
|
+
unit_of_measure: nil
|
2148
|
+
)
|
2149
|
+
@discount_amount = discount_amount
|
2150
|
+
@payment_method_options = payment_method_options
|
2151
|
+
@product_code = product_code
|
2152
|
+
@product_name = product_name
|
2153
|
+
@quantity = quantity
|
2154
|
+
@tax = tax
|
2155
|
+
@unit_cost = unit_cost
|
2156
|
+
@unit_of_measure = unit_of_measure
|
2157
|
+
end
|
2158
|
+
end
|
2159
|
+
|
2160
|
+
class Shipping < Stripe::RequestParams
|
2161
|
+
# Portion of the amount that is for shipping.
|
2162
|
+
attr_accessor :amount
|
2163
|
+
# The postal code that represents the shipping source.
|
2164
|
+
attr_accessor :from_postal_code
|
2165
|
+
# The postal code that represents the shipping destination.
|
2166
|
+
attr_accessor :to_postal_code
|
2167
|
+
|
2168
|
+
def initialize(amount: nil, from_postal_code: nil, to_postal_code: nil)
|
2169
|
+
@amount = amount
|
2170
|
+
@from_postal_code = from_postal_code
|
2171
|
+
@to_postal_code = to_postal_code
|
2172
|
+
end
|
2173
|
+
end
|
2174
|
+
|
2175
|
+
class Tax < Stripe::RequestParams
|
2176
|
+
# Total portion of the amount that is for tax.
|
2177
|
+
attr_accessor :total_tax_amount
|
2178
|
+
|
2179
|
+
def initialize(total_tax_amount: nil)
|
2180
|
+
@total_tax_amount = total_tax_amount
|
2181
|
+
end
|
2182
|
+
end
|
2183
|
+
# The amount an item was discounted for.
|
2184
|
+
attr_accessor :discount_amount
|
2185
|
+
# A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.
|
2186
|
+
attr_accessor :line_items
|
2187
|
+
# Contains information about the shipping portion of the amount.
|
2188
|
+
attr_accessor :shipping
|
2189
|
+
# Contains information about the tax portion of the amount.
|
2190
|
+
attr_accessor :tax
|
2191
|
+
|
2192
|
+
def initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil)
|
2193
|
+
@discount_amount = discount_amount
|
2194
|
+
@line_items = line_items
|
2195
|
+
@shipping = shipping
|
2196
|
+
@tax = tax
|
2197
|
+
end
|
2198
|
+
end
|
2199
|
+
|
2047
2200
|
class AutomaticPaymentMethods < Stripe::RequestParams
|
2048
2201
|
# Controls whether this PaymentIntent will accept redirect-based payment methods.
|
2049
2202
|
#
|
@@ -3928,7 +4081,7 @@ module Stripe
|
|
3928
4081
|
attr_accessor :capture_method
|
3929
4082
|
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
|
3930
4083
|
attr_accessor :cvc_token
|
3931
|
-
# Installment configuration for payments attempted on this PaymentIntent
|
4084
|
+
# Installment configuration for payments attempted on this PaymentIntent.
|
3932
4085
|
#
|
3933
4086
|
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
|
3934
4087
|
attr_accessor :installments
|
@@ -5483,6 +5636,8 @@ module Stripe
|
|
5483
5636
|
end
|
5484
5637
|
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
|
5485
5638
|
attr_accessor :amount
|
5639
|
+
# Provides industry-specific information about the amount.
|
5640
|
+
attr_accessor :amount_details
|
5486
5641
|
# 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. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
|
5487
5642
|
attr_accessor :application_fee_amount
|
5488
5643
|
# When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.
|
@@ -5583,6 +5738,7 @@ module Stripe
|
|
5583
5738
|
|
5584
5739
|
def initialize(
|
5585
5740
|
amount: nil,
|
5741
|
+
amount_details: nil,
|
5586
5742
|
application_fee_amount: nil,
|
5587
5743
|
automatic_payment_methods: nil,
|
5588
5744
|
capture_method: nil,
|
@@ -5621,6 +5777,7 @@ module Stripe
|
|
5621
5777
|
use_stripe_sdk: nil
|
5622
5778
|
)
|
5623
5779
|
@amount = amount
|
5780
|
+
@amount_details = amount_details
|
5624
5781
|
@application_fee_amount = application_fee_amount
|
5625
5782
|
@automatic_payment_methods = automatic_payment_methods
|
5626
5783
|
@capture_method = capture_method
|
@@ -5661,6 +5818,159 @@ module Stripe
|
|
5661
5818
|
end
|
5662
5819
|
|
5663
5820
|
class UpdateParams < Stripe::RequestParams
|
5821
|
+
class AmountDetails < Stripe::RequestParams
|
5822
|
+
class LineItem < Stripe::RequestParams
|
5823
|
+
class PaymentMethodOptions < Stripe::RequestParams
|
5824
|
+
class Card < Stripe::RequestParams
|
5825
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
5826
|
+
attr_accessor :commodity_code
|
5827
|
+
|
5828
|
+
def initialize(commodity_code: nil)
|
5829
|
+
@commodity_code = commodity_code
|
5830
|
+
end
|
5831
|
+
end
|
5832
|
+
|
5833
|
+
class CardPresent < Stripe::RequestParams
|
5834
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
5835
|
+
attr_accessor :commodity_code
|
5836
|
+
|
5837
|
+
def initialize(commodity_code: nil)
|
5838
|
+
@commodity_code = commodity_code
|
5839
|
+
end
|
5840
|
+
end
|
5841
|
+
|
5842
|
+
class Klarna < Stripe::RequestParams
|
5843
|
+
# URL to an image for the product. Max length, 4096 characters.
|
5844
|
+
attr_accessor :image_url
|
5845
|
+
# URL to the product page. Max length, 4096 characters.
|
5846
|
+
attr_accessor :product_url
|
5847
|
+
# Reference for the subscription this line item is for.
|
5848
|
+
attr_accessor :subscription_reference
|
5849
|
+
|
5850
|
+
def initialize(image_url: nil, product_url: nil, subscription_reference: nil)
|
5851
|
+
@image_url = image_url
|
5852
|
+
@product_url = product_url
|
5853
|
+
@subscription_reference = subscription_reference
|
5854
|
+
end
|
5855
|
+
end
|
5856
|
+
|
5857
|
+
class Paypal < Stripe::RequestParams
|
5858
|
+
# Type of the line item.
|
5859
|
+
attr_accessor :category
|
5860
|
+
# Description of the line item.
|
5861
|
+
attr_accessor :description
|
5862
|
+
# The Stripe account ID of the connected account that sells the item.
|
5863
|
+
attr_accessor :sold_by
|
5864
|
+
|
5865
|
+
def initialize(category: nil, description: nil, sold_by: nil)
|
5866
|
+
@category = category
|
5867
|
+
@description = description
|
5868
|
+
@sold_by = sold_by
|
5869
|
+
end
|
5870
|
+
end
|
5871
|
+
# This sub-hash contains line item details that are specific to `card` payment method."
|
5872
|
+
attr_accessor :card
|
5873
|
+
# This sub-hash contains line item details that are specific to `card_present` payment method."
|
5874
|
+
attr_accessor :card_present
|
5875
|
+
# This sub-hash contains line item details that are specific to `klarna` payment method."
|
5876
|
+
attr_accessor :klarna
|
5877
|
+
# This sub-hash contains line item details that are specific to `paypal` payment method."
|
5878
|
+
attr_accessor :paypal
|
5879
|
+
|
5880
|
+
def initialize(card: nil, card_present: nil, klarna: nil, paypal: nil)
|
5881
|
+
@card = card
|
5882
|
+
@card_present = card_present
|
5883
|
+
@klarna = klarna
|
5884
|
+
@paypal = paypal
|
5885
|
+
end
|
5886
|
+
end
|
5887
|
+
|
5888
|
+
class Tax < Stripe::RequestParams
|
5889
|
+
# The total tax on an item. Non-negative integer.
|
5890
|
+
attr_accessor :total_tax_amount
|
5891
|
+
|
5892
|
+
def initialize(total_tax_amount: nil)
|
5893
|
+
@total_tax_amount = total_tax_amount
|
5894
|
+
end
|
5895
|
+
end
|
5896
|
+
# The amount an item was discounted for. Positive integer.
|
5897
|
+
attr_accessor :discount_amount
|
5898
|
+
# Payment method-specific information for line items.
|
5899
|
+
attr_accessor :payment_method_options
|
5900
|
+
# Unique identifier of the product. At most 12 characters long.
|
5901
|
+
attr_accessor :product_code
|
5902
|
+
# Name of the product. At most 100 characters long.
|
5903
|
+
attr_accessor :product_name
|
5904
|
+
# Number of items of the product. Positive integer.
|
5905
|
+
attr_accessor :quantity
|
5906
|
+
# Contains information about the tax on the item.
|
5907
|
+
attr_accessor :tax
|
5908
|
+
# Cost of the product. Non-negative integer.
|
5909
|
+
attr_accessor :unit_cost
|
5910
|
+
# A unit of measure for the line item, such as gallons, feet, meters, etc.
|
5911
|
+
attr_accessor :unit_of_measure
|
5912
|
+
|
5913
|
+
def initialize(
|
5914
|
+
discount_amount: nil,
|
5915
|
+
payment_method_options: nil,
|
5916
|
+
product_code: nil,
|
5917
|
+
product_name: nil,
|
5918
|
+
quantity: nil,
|
5919
|
+
tax: nil,
|
5920
|
+
unit_cost: nil,
|
5921
|
+
unit_of_measure: nil
|
5922
|
+
)
|
5923
|
+
@discount_amount = discount_amount
|
5924
|
+
@payment_method_options = payment_method_options
|
5925
|
+
@product_code = product_code
|
5926
|
+
@product_name = product_name
|
5927
|
+
@quantity = quantity
|
5928
|
+
@tax = tax
|
5929
|
+
@unit_cost = unit_cost
|
5930
|
+
@unit_of_measure = unit_of_measure
|
5931
|
+
end
|
5932
|
+
end
|
5933
|
+
|
5934
|
+
class Shipping < Stripe::RequestParams
|
5935
|
+
# Portion of the amount that is for shipping.
|
5936
|
+
attr_accessor :amount
|
5937
|
+
# The postal code that represents the shipping source.
|
5938
|
+
attr_accessor :from_postal_code
|
5939
|
+
# The postal code that represents the shipping destination.
|
5940
|
+
attr_accessor :to_postal_code
|
5941
|
+
|
5942
|
+
def initialize(amount: nil, from_postal_code: nil, to_postal_code: nil)
|
5943
|
+
@amount = amount
|
5944
|
+
@from_postal_code = from_postal_code
|
5945
|
+
@to_postal_code = to_postal_code
|
5946
|
+
end
|
5947
|
+
end
|
5948
|
+
|
5949
|
+
class Tax < Stripe::RequestParams
|
5950
|
+
# Total portion of the amount that is for tax.
|
5951
|
+
attr_accessor :total_tax_amount
|
5952
|
+
|
5953
|
+
def initialize(total_tax_amount: nil)
|
5954
|
+
@total_tax_amount = total_tax_amount
|
5955
|
+
end
|
5956
|
+
end
|
5957
|
+
# The amount an item was discounted for.
|
5958
|
+
attr_accessor :discount_amount
|
5959
|
+
# A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.
|
5960
|
+
attr_accessor :line_items
|
5961
|
+
# Contains information about the shipping portion of the amount.
|
5962
|
+
attr_accessor :shipping
|
5963
|
+
# Contains information about the tax portion of the amount.
|
5964
|
+
attr_accessor :tax
|
5965
|
+
|
5966
|
+
def initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil)
|
5967
|
+
@discount_amount = discount_amount
|
5968
|
+
@line_items = line_items
|
5969
|
+
@shipping = shipping
|
5970
|
+
@tax = tax
|
5971
|
+
end
|
5972
|
+
end
|
5973
|
+
|
5664
5974
|
class Hooks < Stripe::RequestParams
|
5665
5975
|
class Inputs < Stripe::RequestParams
|
5666
5976
|
class Tax < Stripe::RequestParams
|
@@ -7523,7 +7833,7 @@ module Stripe
|
|
7523
7833
|
attr_accessor :capture_method
|
7524
7834
|
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
|
7525
7835
|
attr_accessor :cvc_token
|
7526
|
-
# Installment configuration for payments attempted on this PaymentIntent
|
7836
|
+
# Installment configuration for payments attempted on this PaymentIntent.
|
7527
7837
|
#
|
7528
7838
|
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
|
7529
7839
|
attr_accessor :installments
|
@@ -9057,6 +9367,8 @@ module Stripe
|
|
9057
9367
|
end
|
9058
9368
|
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
|
9059
9369
|
attr_accessor :amount
|
9370
|
+
# Provides industry-specific information about the amount.
|
9371
|
+
attr_accessor :amount_details
|
9060
9372
|
# 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. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
|
9061
9373
|
attr_accessor :application_fee_amount
|
9062
9374
|
# Controls when the funds will be captured from the customer's account.
|
@@ -9128,6 +9440,7 @@ module Stripe
|
|
9128
9440
|
|
9129
9441
|
def initialize(
|
9130
9442
|
amount: nil,
|
9443
|
+
amount_details: nil,
|
9131
9444
|
application_fee_amount: nil,
|
9132
9445
|
capture_method: nil,
|
9133
9446
|
currency: nil,
|
@@ -9154,6 +9467,7 @@ module Stripe
|
|
9154
9467
|
transfer_group: nil
|
9155
9468
|
)
|
9156
9469
|
@amount = amount
|
9470
|
+
@amount_details = amount_details
|
9157
9471
|
@application_fee_amount = application_fee_amount
|
9158
9472
|
@capture_method = capture_method
|
9159
9473
|
@currency = currency
|
@@ -9231,6 +9545,159 @@ module Stripe
|
|
9231
9545
|
end
|
9232
9546
|
|
9233
9547
|
class CaptureParams < Stripe::RequestParams
|
9548
|
+
class AmountDetails < Stripe::RequestParams
|
9549
|
+
class LineItem < Stripe::RequestParams
|
9550
|
+
class PaymentMethodOptions < Stripe::RequestParams
|
9551
|
+
class Card < Stripe::RequestParams
|
9552
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
9553
|
+
attr_accessor :commodity_code
|
9554
|
+
|
9555
|
+
def initialize(commodity_code: nil)
|
9556
|
+
@commodity_code = commodity_code
|
9557
|
+
end
|
9558
|
+
end
|
9559
|
+
|
9560
|
+
class CardPresent < Stripe::RequestParams
|
9561
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
9562
|
+
attr_accessor :commodity_code
|
9563
|
+
|
9564
|
+
def initialize(commodity_code: nil)
|
9565
|
+
@commodity_code = commodity_code
|
9566
|
+
end
|
9567
|
+
end
|
9568
|
+
|
9569
|
+
class Klarna < Stripe::RequestParams
|
9570
|
+
# URL to an image for the product. Max length, 4096 characters.
|
9571
|
+
attr_accessor :image_url
|
9572
|
+
# URL to the product page. Max length, 4096 characters.
|
9573
|
+
attr_accessor :product_url
|
9574
|
+
# Reference for the subscription this line item is for.
|
9575
|
+
attr_accessor :subscription_reference
|
9576
|
+
|
9577
|
+
def initialize(image_url: nil, product_url: nil, subscription_reference: nil)
|
9578
|
+
@image_url = image_url
|
9579
|
+
@product_url = product_url
|
9580
|
+
@subscription_reference = subscription_reference
|
9581
|
+
end
|
9582
|
+
end
|
9583
|
+
|
9584
|
+
class Paypal < Stripe::RequestParams
|
9585
|
+
# Type of the line item.
|
9586
|
+
attr_accessor :category
|
9587
|
+
# Description of the line item.
|
9588
|
+
attr_accessor :description
|
9589
|
+
# The Stripe account ID of the connected account that sells the item.
|
9590
|
+
attr_accessor :sold_by
|
9591
|
+
|
9592
|
+
def initialize(category: nil, description: nil, sold_by: nil)
|
9593
|
+
@category = category
|
9594
|
+
@description = description
|
9595
|
+
@sold_by = sold_by
|
9596
|
+
end
|
9597
|
+
end
|
9598
|
+
# This sub-hash contains line item details that are specific to `card` payment method."
|
9599
|
+
attr_accessor :card
|
9600
|
+
# This sub-hash contains line item details that are specific to `card_present` payment method."
|
9601
|
+
attr_accessor :card_present
|
9602
|
+
# This sub-hash contains line item details that are specific to `klarna` payment method."
|
9603
|
+
attr_accessor :klarna
|
9604
|
+
# This sub-hash contains line item details that are specific to `paypal` payment method."
|
9605
|
+
attr_accessor :paypal
|
9606
|
+
|
9607
|
+
def initialize(card: nil, card_present: nil, klarna: nil, paypal: nil)
|
9608
|
+
@card = card
|
9609
|
+
@card_present = card_present
|
9610
|
+
@klarna = klarna
|
9611
|
+
@paypal = paypal
|
9612
|
+
end
|
9613
|
+
end
|
9614
|
+
|
9615
|
+
class Tax < Stripe::RequestParams
|
9616
|
+
# The total tax on an item. Non-negative integer.
|
9617
|
+
attr_accessor :total_tax_amount
|
9618
|
+
|
9619
|
+
def initialize(total_tax_amount: nil)
|
9620
|
+
@total_tax_amount = total_tax_amount
|
9621
|
+
end
|
9622
|
+
end
|
9623
|
+
# The amount an item was discounted for. Positive integer.
|
9624
|
+
attr_accessor :discount_amount
|
9625
|
+
# Payment method-specific information for line items.
|
9626
|
+
attr_accessor :payment_method_options
|
9627
|
+
# Unique identifier of the product. At most 12 characters long.
|
9628
|
+
attr_accessor :product_code
|
9629
|
+
# Name of the product. At most 100 characters long.
|
9630
|
+
attr_accessor :product_name
|
9631
|
+
# Number of items of the product. Positive integer.
|
9632
|
+
attr_accessor :quantity
|
9633
|
+
# Contains information about the tax on the item.
|
9634
|
+
attr_accessor :tax
|
9635
|
+
# Cost of the product. Non-negative integer.
|
9636
|
+
attr_accessor :unit_cost
|
9637
|
+
# A unit of measure for the line item, such as gallons, feet, meters, etc.
|
9638
|
+
attr_accessor :unit_of_measure
|
9639
|
+
|
9640
|
+
def initialize(
|
9641
|
+
discount_amount: nil,
|
9642
|
+
payment_method_options: nil,
|
9643
|
+
product_code: nil,
|
9644
|
+
product_name: nil,
|
9645
|
+
quantity: nil,
|
9646
|
+
tax: nil,
|
9647
|
+
unit_cost: nil,
|
9648
|
+
unit_of_measure: nil
|
9649
|
+
)
|
9650
|
+
@discount_amount = discount_amount
|
9651
|
+
@payment_method_options = payment_method_options
|
9652
|
+
@product_code = product_code
|
9653
|
+
@product_name = product_name
|
9654
|
+
@quantity = quantity
|
9655
|
+
@tax = tax
|
9656
|
+
@unit_cost = unit_cost
|
9657
|
+
@unit_of_measure = unit_of_measure
|
9658
|
+
end
|
9659
|
+
end
|
9660
|
+
|
9661
|
+
class Shipping < Stripe::RequestParams
|
9662
|
+
# Portion of the amount that is for shipping.
|
9663
|
+
attr_accessor :amount
|
9664
|
+
# The postal code that represents the shipping source.
|
9665
|
+
attr_accessor :from_postal_code
|
9666
|
+
# The postal code that represents the shipping destination.
|
9667
|
+
attr_accessor :to_postal_code
|
9668
|
+
|
9669
|
+
def initialize(amount: nil, from_postal_code: nil, to_postal_code: nil)
|
9670
|
+
@amount = amount
|
9671
|
+
@from_postal_code = from_postal_code
|
9672
|
+
@to_postal_code = to_postal_code
|
9673
|
+
end
|
9674
|
+
end
|
9675
|
+
|
9676
|
+
class Tax < Stripe::RequestParams
|
9677
|
+
# Total portion of the amount that is for tax.
|
9678
|
+
attr_accessor :total_tax_amount
|
9679
|
+
|
9680
|
+
def initialize(total_tax_amount: nil)
|
9681
|
+
@total_tax_amount = total_tax_amount
|
9682
|
+
end
|
9683
|
+
end
|
9684
|
+
# The amount an item was discounted for.
|
9685
|
+
attr_accessor :discount_amount
|
9686
|
+
# A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.
|
9687
|
+
attr_accessor :line_items
|
9688
|
+
# Contains information about the shipping portion of the amount.
|
9689
|
+
attr_accessor :shipping
|
9690
|
+
# Contains information about the tax portion of the amount.
|
9691
|
+
attr_accessor :tax
|
9692
|
+
|
9693
|
+
def initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil)
|
9694
|
+
@discount_amount = discount_amount
|
9695
|
+
@line_items = line_items
|
9696
|
+
@shipping = shipping
|
9697
|
+
@tax = tax
|
9698
|
+
end
|
9699
|
+
end
|
9700
|
+
|
9234
9701
|
class Hooks < Stripe::RequestParams
|
9235
9702
|
class Inputs < Stripe::RequestParams
|
9236
9703
|
class Tax < Stripe::RequestParams
|
@@ -9969,6 +10436,8 @@ module Stripe
|
|
9969
10436
|
@amount = amount
|
9970
10437
|
end
|
9971
10438
|
end
|
10439
|
+
# Provides industry-specific information about the amount.
|
10440
|
+
attr_accessor :amount_details
|
9972
10441
|
# The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Defaults to the full `amount_capturable` if it's not provided.
|
9973
10442
|
attr_accessor :amount_to_capture
|
9974
10443
|
# 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. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
|
@@ -9994,6 +10463,7 @@ module Stripe
|
|
9994
10463
|
attr_accessor :transfer_data
|
9995
10464
|
|
9996
10465
|
def initialize(
|
10466
|
+
amount_details: nil,
|
9997
10467
|
amount_to_capture: nil,
|
9998
10468
|
application_fee_amount: nil,
|
9999
10469
|
expand: nil,
|
@@ -10005,6 +10475,7 @@ module Stripe
|
|
10005
10475
|
statement_descriptor_suffix: nil,
|
10006
10476
|
transfer_data: nil
|
10007
10477
|
)
|
10478
|
+
@amount_details = amount_details
|
10008
10479
|
@amount_to_capture = amount_to_capture
|
10009
10480
|
@application_fee_amount = application_fee_amount
|
10010
10481
|
@expand = expand
|
@@ -10019,6 +10490,159 @@ module Stripe
|
|
10019
10490
|
end
|
10020
10491
|
|
10021
10492
|
class ConfirmParams < Stripe::RequestParams
|
10493
|
+
class AmountDetails < Stripe::RequestParams
|
10494
|
+
class LineItem < Stripe::RequestParams
|
10495
|
+
class PaymentMethodOptions < Stripe::RequestParams
|
10496
|
+
class Card < Stripe::RequestParams
|
10497
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
10498
|
+
attr_accessor :commodity_code
|
10499
|
+
|
10500
|
+
def initialize(commodity_code: nil)
|
10501
|
+
@commodity_code = commodity_code
|
10502
|
+
end
|
10503
|
+
end
|
10504
|
+
|
10505
|
+
class CardPresent < Stripe::RequestParams
|
10506
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
10507
|
+
attr_accessor :commodity_code
|
10508
|
+
|
10509
|
+
def initialize(commodity_code: nil)
|
10510
|
+
@commodity_code = commodity_code
|
10511
|
+
end
|
10512
|
+
end
|
10513
|
+
|
10514
|
+
class Klarna < Stripe::RequestParams
|
10515
|
+
# URL to an image for the product. Max length, 4096 characters.
|
10516
|
+
attr_accessor :image_url
|
10517
|
+
# URL to the product page. Max length, 4096 characters.
|
10518
|
+
attr_accessor :product_url
|
10519
|
+
# Reference for the subscription this line item is for.
|
10520
|
+
attr_accessor :subscription_reference
|
10521
|
+
|
10522
|
+
def initialize(image_url: nil, product_url: nil, subscription_reference: nil)
|
10523
|
+
@image_url = image_url
|
10524
|
+
@product_url = product_url
|
10525
|
+
@subscription_reference = subscription_reference
|
10526
|
+
end
|
10527
|
+
end
|
10528
|
+
|
10529
|
+
class Paypal < Stripe::RequestParams
|
10530
|
+
# Type of the line item.
|
10531
|
+
attr_accessor :category
|
10532
|
+
# Description of the line item.
|
10533
|
+
attr_accessor :description
|
10534
|
+
# The Stripe account ID of the connected account that sells the item.
|
10535
|
+
attr_accessor :sold_by
|
10536
|
+
|
10537
|
+
def initialize(category: nil, description: nil, sold_by: nil)
|
10538
|
+
@category = category
|
10539
|
+
@description = description
|
10540
|
+
@sold_by = sold_by
|
10541
|
+
end
|
10542
|
+
end
|
10543
|
+
# This sub-hash contains line item details that are specific to `card` payment method."
|
10544
|
+
attr_accessor :card
|
10545
|
+
# This sub-hash contains line item details that are specific to `card_present` payment method."
|
10546
|
+
attr_accessor :card_present
|
10547
|
+
# This sub-hash contains line item details that are specific to `klarna` payment method."
|
10548
|
+
attr_accessor :klarna
|
10549
|
+
# This sub-hash contains line item details that are specific to `paypal` payment method."
|
10550
|
+
attr_accessor :paypal
|
10551
|
+
|
10552
|
+
def initialize(card: nil, card_present: nil, klarna: nil, paypal: nil)
|
10553
|
+
@card = card
|
10554
|
+
@card_present = card_present
|
10555
|
+
@klarna = klarna
|
10556
|
+
@paypal = paypal
|
10557
|
+
end
|
10558
|
+
end
|
10559
|
+
|
10560
|
+
class Tax < Stripe::RequestParams
|
10561
|
+
# The total tax on an item. Non-negative integer.
|
10562
|
+
attr_accessor :total_tax_amount
|
10563
|
+
|
10564
|
+
def initialize(total_tax_amount: nil)
|
10565
|
+
@total_tax_amount = total_tax_amount
|
10566
|
+
end
|
10567
|
+
end
|
10568
|
+
# The amount an item was discounted for. Positive integer.
|
10569
|
+
attr_accessor :discount_amount
|
10570
|
+
# Payment method-specific information for line items.
|
10571
|
+
attr_accessor :payment_method_options
|
10572
|
+
# Unique identifier of the product. At most 12 characters long.
|
10573
|
+
attr_accessor :product_code
|
10574
|
+
# Name of the product. At most 100 characters long.
|
10575
|
+
attr_accessor :product_name
|
10576
|
+
# Number of items of the product. Positive integer.
|
10577
|
+
attr_accessor :quantity
|
10578
|
+
# Contains information about the tax on the item.
|
10579
|
+
attr_accessor :tax
|
10580
|
+
# Cost of the product. Non-negative integer.
|
10581
|
+
attr_accessor :unit_cost
|
10582
|
+
# A unit of measure for the line item, such as gallons, feet, meters, etc.
|
10583
|
+
attr_accessor :unit_of_measure
|
10584
|
+
|
10585
|
+
def initialize(
|
10586
|
+
discount_amount: nil,
|
10587
|
+
payment_method_options: nil,
|
10588
|
+
product_code: nil,
|
10589
|
+
product_name: nil,
|
10590
|
+
quantity: nil,
|
10591
|
+
tax: nil,
|
10592
|
+
unit_cost: nil,
|
10593
|
+
unit_of_measure: nil
|
10594
|
+
)
|
10595
|
+
@discount_amount = discount_amount
|
10596
|
+
@payment_method_options = payment_method_options
|
10597
|
+
@product_code = product_code
|
10598
|
+
@product_name = product_name
|
10599
|
+
@quantity = quantity
|
10600
|
+
@tax = tax
|
10601
|
+
@unit_cost = unit_cost
|
10602
|
+
@unit_of_measure = unit_of_measure
|
10603
|
+
end
|
10604
|
+
end
|
10605
|
+
|
10606
|
+
class Shipping < Stripe::RequestParams
|
10607
|
+
# Portion of the amount that is for shipping.
|
10608
|
+
attr_accessor :amount
|
10609
|
+
# The postal code that represents the shipping source.
|
10610
|
+
attr_accessor :from_postal_code
|
10611
|
+
# The postal code that represents the shipping destination.
|
10612
|
+
attr_accessor :to_postal_code
|
10613
|
+
|
10614
|
+
def initialize(amount: nil, from_postal_code: nil, to_postal_code: nil)
|
10615
|
+
@amount = amount
|
10616
|
+
@from_postal_code = from_postal_code
|
10617
|
+
@to_postal_code = to_postal_code
|
10618
|
+
end
|
10619
|
+
end
|
10620
|
+
|
10621
|
+
class Tax < Stripe::RequestParams
|
10622
|
+
# Total portion of the amount that is for tax.
|
10623
|
+
attr_accessor :total_tax_amount
|
10624
|
+
|
10625
|
+
def initialize(total_tax_amount: nil)
|
10626
|
+
@total_tax_amount = total_tax_amount
|
10627
|
+
end
|
10628
|
+
end
|
10629
|
+
# The amount an item was discounted for.
|
10630
|
+
attr_accessor :discount_amount
|
10631
|
+
# A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.
|
10632
|
+
attr_accessor :line_items
|
10633
|
+
# Contains information about the shipping portion of the amount.
|
10634
|
+
attr_accessor :shipping
|
10635
|
+
# Contains information about the tax portion of the amount.
|
10636
|
+
attr_accessor :tax
|
10637
|
+
|
10638
|
+
def initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil)
|
10639
|
+
@discount_amount = discount_amount
|
10640
|
+
@line_items = line_items
|
10641
|
+
@shipping = shipping
|
10642
|
+
@tax = tax
|
10643
|
+
end
|
10644
|
+
end
|
10645
|
+
|
10022
10646
|
class Hooks < Stripe::RequestParams
|
10023
10647
|
class Inputs < Stripe::RequestParams
|
10024
10648
|
class Tax < Stripe::RequestParams
|
@@ -11889,7 +12513,7 @@ module Stripe
|
|
11889
12513
|
attr_accessor :capture_method
|
11890
12514
|
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
|
11891
12515
|
attr_accessor :cvc_token
|
11892
|
-
# Installment configuration for payments attempted on this PaymentIntent
|
12516
|
+
# Installment configuration for payments attempted on this PaymentIntent.
|
11893
12517
|
#
|
11894
12518
|
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
|
11895
12519
|
attr_accessor :installments
|
@@ -13421,6 +14045,8 @@ module Stripe
|
|
13421
14045
|
@tracking_number = tracking_number
|
13422
14046
|
end
|
13423
14047
|
end
|
14048
|
+
# Provides industry-specific information about the amount.
|
14049
|
+
attr_accessor :amount_details
|
13424
14050
|
# 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. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
|
13425
14051
|
attr_accessor :application_fee_amount
|
13426
14052
|
# Controls when the funds will be captured from the customer's account.
|
@@ -13480,6 +14106,7 @@ module Stripe
|
|
13480
14106
|
attr_accessor :use_stripe_sdk
|
13481
14107
|
|
13482
14108
|
def initialize(
|
14109
|
+
amount_details: nil,
|
13483
14110
|
application_fee_amount: nil,
|
13484
14111
|
capture_method: nil,
|
13485
14112
|
confirmation_token: nil,
|
@@ -13502,6 +14129,7 @@ module Stripe
|
|
13502
14129
|
shipping: nil,
|
13503
14130
|
use_stripe_sdk: nil
|
13504
14131
|
)
|
14132
|
+
@amount_details = amount_details
|
13505
14133
|
@application_fee_amount = application_fee_amount
|
13506
14134
|
@capture_method = capture_method
|
13507
14135
|
@confirmation_token = confirmation_token
|
@@ -13596,6 +14224,159 @@ module Stripe
|
|
13596
14224
|
end
|
13597
14225
|
|
13598
14226
|
class IncrementAuthorizationParams < Stripe::RequestParams
|
14227
|
+
class AmountDetails < Stripe::RequestParams
|
14228
|
+
class LineItem < Stripe::RequestParams
|
14229
|
+
class PaymentMethodOptions < Stripe::RequestParams
|
14230
|
+
class Card < Stripe::RequestParams
|
14231
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
14232
|
+
attr_accessor :commodity_code
|
14233
|
+
|
14234
|
+
def initialize(commodity_code: nil)
|
14235
|
+
@commodity_code = commodity_code
|
14236
|
+
end
|
14237
|
+
end
|
14238
|
+
|
14239
|
+
class CardPresent < Stripe::RequestParams
|
14240
|
+
# Identifier that categorizes the items being purchased using a standardized commodity scheme such as (but not limited to) UNSPSC, NAICS, NAPCS, etc.
|
14241
|
+
attr_accessor :commodity_code
|
14242
|
+
|
14243
|
+
def initialize(commodity_code: nil)
|
14244
|
+
@commodity_code = commodity_code
|
14245
|
+
end
|
14246
|
+
end
|
14247
|
+
|
14248
|
+
class Klarna < Stripe::RequestParams
|
14249
|
+
# URL to an image for the product. Max length, 4096 characters.
|
14250
|
+
attr_accessor :image_url
|
14251
|
+
# URL to the product page. Max length, 4096 characters.
|
14252
|
+
attr_accessor :product_url
|
14253
|
+
# Reference for the subscription this line item is for.
|
14254
|
+
attr_accessor :subscription_reference
|
14255
|
+
|
14256
|
+
def initialize(image_url: nil, product_url: nil, subscription_reference: nil)
|
14257
|
+
@image_url = image_url
|
14258
|
+
@product_url = product_url
|
14259
|
+
@subscription_reference = subscription_reference
|
14260
|
+
end
|
14261
|
+
end
|
14262
|
+
|
14263
|
+
class Paypal < Stripe::RequestParams
|
14264
|
+
# Type of the line item.
|
14265
|
+
attr_accessor :category
|
14266
|
+
# Description of the line item.
|
14267
|
+
attr_accessor :description
|
14268
|
+
# The Stripe account ID of the connected account that sells the item.
|
14269
|
+
attr_accessor :sold_by
|
14270
|
+
|
14271
|
+
def initialize(category: nil, description: nil, sold_by: nil)
|
14272
|
+
@category = category
|
14273
|
+
@description = description
|
14274
|
+
@sold_by = sold_by
|
14275
|
+
end
|
14276
|
+
end
|
14277
|
+
# This sub-hash contains line item details that are specific to `card` payment method."
|
14278
|
+
attr_accessor :card
|
14279
|
+
# This sub-hash contains line item details that are specific to `card_present` payment method."
|
14280
|
+
attr_accessor :card_present
|
14281
|
+
# This sub-hash contains line item details that are specific to `klarna` payment method."
|
14282
|
+
attr_accessor :klarna
|
14283
|
+
# This sub-hash contains line item details that are specific to `paypal` payment method."
|
14284
|
+
attr_accessor :paypal
|
14285
|
+
|
14286
|
+
def initialize(card: nil, card_present: nil, klarna: nil, paypal: nil)
|
14287
|
+
@card = card
|
14288
|
+
@card_present = card_present
|
14289
|
+
@klarna = klarna
|
14290
|
+
@paypal = paypal
|
14291
|
+
end
|
14292
|
+
end
|
14293
|
+
|
14294
|
+
class Tax < Stripe::RequestParams
|
14295
|
+
# The total tax on an item. Non-negative integer.
|
14296
|
+
attr_accessor :total_tax_amount
|
14297
|
+
|
14298
|
+
def initialize(total_tax_amount: nil)
|
14299
|
+
@total_tax_amount = total_tax_amount
|
14300
|
+
end
|
14301
|
+
end
|
14302
|
+
# The amount an item was discounted for. Positive integer.
|
14303
|
+
attr_accessor :discount_amount
|
14304
|
+
# Payment method-specific information for line items.
|
14305
|
+
attr_accessor :payment_method_options
|
14306
|
+
# Unique identifier of the product. At most 12 characters long.
|
14307
|
+
attr_accessor :product_code
|
14308
|
+
# Name of the product. At most 100 characters long.
|
14309
|
+
attr_accessor :product_name
|
14310
|
+
# Number of items of the product. Positive integer.
|
14311
|
+
attr_accessor :quantity
|
14312
|
+
# Contains information about the tax on the item.
|
14313
|
+
attr_accessor :tax
|
14314
|
+
# Cost of the product. Non-negative integer.
|
14315
|
+
attr_accessor :unit_cost
|
14316
|
+
# A unit of measure for the line item, such as gallons, feet, meters, etc.
|
14317
|
+
attr_accessor :unit_of_measure
|
14318
|
+
|
14319
|
+
def initialize(
|
14320
|
+
discount_amount: nil,
|
14321
|
+
payment_method_options: nil,
|
14322
|
+
product_code: nil,
|
14323
|
+
product_name: nil,
|
14324
|
+
quantity: nil,
|
14325
|
+
tax: nil,
|
14326
|
+
unit_cost: nil,
|
14327
|
+
unit_of_measure: nil
|
14328
|
+
)
|
14329
|
+
@discount_amount = discount_amount
|
14330
|
+
@payment_method_options = payment_method_options
|
14331
|
+
@product_code = product_code
|
14332
|
+
@product_name = product_name
|
14333
|
+
@quantity = quantity
|
14334
|
+
@tax = tax
|
14335
|
+
@unit_cost = unit_cost
|
14336
|
+
@unit_of_measure = unit_of_measure
|
14337
|
+
end
|
14338
|
+
end
|
14339
|
+
|
14340
|
+
class Shipping < Stripe::RequestParams
|
14341
|
+
# Portion of the amount that is for shipping.
|
14342
|
+
attr_accessor :amount
|
14343
|
+
# The postal code that represents the shipping source.
|
14344
|
+
attr_accessor :from_postal_code
|
14345
|
+
# The postal code that represents the shipping destination.
|
14346
|
+
attr_accessor :to_postal_code
|
14347
|
+
|
14348
|
+
def initialize(amount: nil, from_postal_code: nil, to_postal_code: nil)
|
14349
|
+
@amount = amount
|
14350
|
+
@from_postal_code = from_postal_code
|
14351
|
+
@to_postal_code = to_postal_code
|
14352
|
+
end
|
14353
|
+
end
|
14354
|
+
|
14355
|
+
class Tax < Stripe::RequestParams
|
14356
|
+
# Total portion of the amount that is for tax.
|
14357
|
+
attr_accessor :total_tax_amount
|
14358
|
+
|
14359
|
+
def initialize(total_tax_amount: nil)
|
14360
|
+
@total_tax_amount = total_tax_amount
|
14361
|
+
end
|
14362
|
+
end
|
14363
|
+
# The amount an item was discounted for.
|
14364
|
+
attr_accessor :discount_amount
|
14365
|
+
# A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.
|
14366
|
+
attr_accessor :line_items
|
14367
|
+
# Contains information about the shipping portion of the amount.
|
14368
|
+
attr_accessor :shipping
|
14369
|
+
# Contains information about the tax portion of the amount.
|
14370
|
+
attr_accessor :tax
|
14371
|
+
|
14372
|
+
def initialize(discount_amount: nil, line_items: nil, shipping: nil, tax: nil)
|
14373
|
+
@discount_amount = discount_amount
|
14374
|
+
@line_items = line_items
|
14375
|
+
@shipping = shipping
|
14376
|
+
@tax = tax
|
14377
|
+
end
|
14378
|
+
end
|
14379
|
+
|
13599
14380
|
class Hooks < Stripe::RequestParams
|
13600
14381
|
class Inputs < Stripe::RequestParams
|
13601
14382
|
class Tax < Stripe::RequestParams
|
@@ -13621,6 +14402,18 @@ module Stripe
|
|
13621
14402
|
end
|
13622
14403
|
end
|
13623
14404
|
|
14405
|
+
class PaymentDetails < Stripe::RequestParams
|
14406
|
+
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
|
14407
|
+
attr_accessor :customer_reference
|
14408
|
+
# A unique value assigned by the business to identify the transaction.
|
14409
|
+
attr_accessor :order_reference
|
14410
|
+
|
14411
|
+
def initialize(customer_reference: nil, order_reference: nil)
|
14412
|
+
@customer_reference = customer_reference
|
14413
|
+
@order_reference = order_reference
|
14414
|
+
end
|
14415
|
+
end
|
14416
|
+
|
13624
14417
|
class PaymentMethodOptions < Stripe::RequestParams
|
13625
14418
|
class Card < Stripe::RequestParams
|
13626
14419
|
# Request partial authorization on this PaymentIntent.
|
@@ -13648,6 +14441,8 @@ module Stripe
|
|
13648
14441
|
end
|
13649
14442
|
# The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.
|
13650
14443
|
attr_accessor :amount
|
14444
|
+
# Provides industry-specific information about the amount.
|
14445
|
+
attr_accessor :amount_details
|
13651
14446
|
# 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. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
|
13652
14447
|
attr_accessor :application_fee_amount
|
13653
14448
|
# An arbitrary string attached to the object. Often useful for displaying to users.
|
@@ -13658,6 +14453,8 @@ module Stripe
|
|
13658
14453
|
attr_accessor :hooks
|
13659
14454
|
# Set of [key-value pairs](https://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`.
|
13660
14455
|
attr_accessor :metadata
|
14456
|
+
# Provides industry-specific information about the charge.
|
14457
|
+
attr_accessor :payment_details
|
13661
14458
|
# Payment method-specific configuration for this PaymentIntent.
|
13662
14459
|
attr_accessor :payment_method_options
|
13663
14460
|
# Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
|
@@ -13668,21 +14465,25 @@ module Stripe
|
|
13668
14465
|
|
13669
14466
|
def initialize(
|
13670
14467
|
amount: nil,
|
14468
|
+
amount_details: nil,
|
13671
14469
|
application_fee_amount: nil,
|
13672
14470
|
description: nil,
|
13673
14471
|
expand: nil,
|
13674
14472
|
hooks: nil,
|
13675
14473
|
metadata: nil,
|
14474
|
+
payment_details: nil,
|
13676
14475
|
payment_method_options: nil,
|
13677
14476
|
statement_descriptor: nil,
|
13678
14477
|
transfer_data: nil
|
13679
14478
|
)
|
13680
14479
|
@amount = amount
|
14480
|
+
@amount_details = amount_details
|
13681
14481
|
@application_fee_amount = application_fee_amount
|
13682
14482
|
@description = description
|
13683
14483
|
@expand = expand
|
13684
14484
|
@hooks = hooks
|
13685
14485
|
@metadata = metadata
|
14486
|
+
@payment_details = payment_details
|
13686
14487
|
@payment_method_options = payment_method_options
|
13687
14488
|
@statement_descriptor = statement_descriptor
|
13688
14489
|
@transfer_data = transfer_data
|
@@ -13916,6 +14717,7 @@ module Stripe
|
|
13916
14717
|
# Confirm that your customer intends to pay with current or provided
|
13917
14718
|
# payment method. Upon confirmation, the PaymentIntent will attempt to initiate
|
13918
14719
|
# a payment.
|
14720
|
+
#
|
13919
14721
|
# If the selected payment method requires additional authentication steps, the
|
13920
14722
|
# PaymentIntent will transition to the requires_action status and
|
13921
14723
|
# suggest additional actions via next_action. If payment fails,
|
@@ -13923,18 +14725,22 @@ module Stripe
|
|
13923
14725
|
# canceled status if the confirmation limit is reached. If
|
13924
14726
|
# payment succeeds, the PaymentIntent will transition to the succeeded
|
13925
14727
|
# status (or requires_capture, if capture_method is set to manual).
|
14728
|
+
#
|
13926
14729
|
# If the confirmation_method is automatic, payment may be attempted
|
13927
14730
|
# using our [client SDKs](https://docs.stripe.com/docs/stripe-js/reference#stripe-handle-card-payment)
|
13928
14731
|
# and the PaymentIntent's [client_secret](https://docs.stripe.com/api#payment_intent_object-client_secret).
|
13929
14732
|
# After next_actions are handled by the client, no additional
|
13930
14733
|
# confirmation is required to complete the payment.
|
14734
|
+
#
|
13931
14735
|
# If the confirmation_method is manual, all payment attempts must be
|
13932
14736
|
# initiated using a secret key.
|
14737
|
+
#
|
13933
14738
|
# If any actions are required for the payment, the PaymentIntent will
|
13934
14739
|
# return to the requires_confirmation state
|
13935
14740
|
# after those actions are completed. Your server needs to then
|
13936
14741
|
# explicitly re-confirm the PaymentIntent to initiate the next payment
|
13937
14742
|
# attempt.
|
14743
|
+
#
|
13938
14744
|
# There is a variable upper limit on how many times a PaymentIntent can be confirmed.
|
13939
14745
|
# After this limit is reached, any further calls to this endpoint will
|
13940
14746
|
# transition the PaymentIntent to the canceled state.
|
@@ -13950,6 +14756,7 @@ module Stripe
|
|
13950
14756
|
# Confirm that your customer intends to pay with current or provided
|
13951
14757
|
# payment method. Upon confirmation, the PaymentIntent will attempt to initiate
|
13952
14758
|
# a payment.
|
14759
|
+
#
|
13953
14760
|
# If the selected payment method requires additional authentication steps, the
|
13954
14761
|
# PaymentIntent will transition to the requires_action status and
|
13955
14762
|
# suggest additional actions via next_action. If payment fails,
|
@@ -13957,18 +14764,22 @@ module Stripe
|
|
13957
14764
|
# canceled status if the confirmation limit is reached. If
|
13958
14765
|
# payment succeeds, the PaymentIntent will transition to the succeeded
|
13959
14766
|
# status (or requires_capture, if capture_method is set to manual).
|
14767
|
+
#
|
13960
14768
|
# If the confirmation_method is automatic, payment may be attempted
|
13961
14769
|
# using our [client SDKs](https://docs.stripe.com/docs/stripe-js/reference#stripe-handle-card-payment)
|
13962
14770
|
# and the PaymentIntent's [client_secret](https://docs.stripe.com/api#payment_intent_object-client_secret).
|
13963
14771
|
# After next_actions are handled by the client, no additional
|
13964
14772
|
# confirmation is required to complete the payment.
|
14773
|
+
#
|
13965
14774
|
# If the confirmation_method is manual, all payment attempts must be
|
13966
14775
|
# initiated using a secret key.
|
14776
|
+
#
|
13967
14777
|
# If any actions are required for the payment, the PaymentIntent will
|
13968
14778
|
# return to the requires_confirmation state
|
13969
14779
|
# after those actions are completed. Your server needs to then
|
13970
14780
|
# explicitly re-confirm the PaymentIntent to initiate the next payment
|
13971
14781
|
# attempt.
|
14782
|
+
#
|
13972
14783
|
# There is a variable upper limit on how many times a PaymentIntent can be confirmed.
|
13973
14784
|
# After this limit is reached, any further calls to this endpoint will
|
13974
14785
|
# transition the PaymentIntent to the canceled state.
|