stripe 13.4.1 → 13.5.0.pre.beta.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (743) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +1427 -645
  3. data/OPENAPI_VERSION +1 -1
  4. data/VERSION +1 -1
  5. data/lib/stripe/api_operations/request.rb +1 -0
  6. data/lib/stripe/api_requestor.rb +1 -0
  7. data/lib/stripe/object_types.rb +32 -0
  8. data/lib/stripe/request_params.rb +24 -0
  9. data/lib/stripe/request_signing_authenticator.rb +79 -0
  10. data/lib/stripe/resources/account.rb +5165 -0
  11. data/lib/stripe/resources/account_link.rb +54 -0
  12. data/lib/stripe/resources/account_notice.rb +132 -0
  13. data/lib/stripe/resources/account_session.rb +985 -0
  14. data/lib/stripe/resources/apple_pay_domain.rb +63 -0
  15. data/lib/stripe/resources/application.rb +20 -0
  16. data/lib/stripe/resources/application_fee.rb +96 -0
  17. data/lib/stripe/resources/application_fee_refund.rb +17 -0
  18. data/lib/stripe/resources/apps/secret.rb +141 -0
  19. data/lib/stripe/resources/balance.rb +131 -0
  20. data/lib/stripe/resources/balance_transaction.rb +112 -0
  21. data/lib/stripe/resources/bank_account.rb +84 -2
  22. data/lib/stripe/resources/billing/alert.rb +144 -0
  23. data/lib/stripe/resources/billing/alert_triggered.rb +26 -0
  24. data/lib/stripe/resources/billing/credit_balance_summary.rb +88 -0
  25. data/lib/stripe/resources/billing/credit_balance_transaction.rb +116 -0
  26. data/lib/stripe/resources/billing/credit_grant.rb +220 -0
  27. data/lib/stripe/resources/billing/meter.rb +178 -0
  28. data/lib/stripe/resources/billing/meter_error_report.rb +59 -0
  29. data/lib/stripe/resources/billing/meter_event.rb +35 -0
  30. data/lib/stripe/resources/billing/meter_event_adjustment.rb +43 -0
  31. data/lib/stripe/resources/billing/meter_event_summary.rb +17 -0
  32. data/lib/stripe/resources/billing_portal/configuration.rb +562 -0
  33. data/lib/stripe/resources/billing_portal/session.rb +271 -0
  34. data/lib/stripe/resources/capability.rb +84 -0
  35. data/lib/stripe/resources/capital/financing_offer.rb +188 -0
  36. data/lib/stripe/resources/capital/financing_summary.rb +64 -0
  37. data/lib/stripe/resources/capital/financing_transaction.rb +123 -0
  38. data/lib/stripe/resources/card.rb +79 -0
  39. data/lib/stripe/resources/cash_balance.rb +17 -0
  40. data/lib/stripe/resources/charge.rb +3034 -0
  41. data/lib/stripe/resources/checkout/session.rb +3690 -0
  42. data/lib/stripe/resources/climate/order.rb +176 -0
  43. data/lib/stripe/resources/climate/product.rb +56 -0
  44. data/lib/stripe/resources/climate/supplier.rb +54 -0
  45. data/lib/stripe/resources/confirmation_token.rb +1530 -0
  46. data/lib/stripe/resources/connect_collection_transfer.rb +24 -0
  47. data/lib/stripe/resources/country_spec.rb +63 -0
  48. data/lib/stripe/resources/coupon.rb +198 -0
  49. data/lib/stripe/resources/credit_note.rb +660 -0
  50. data/lib/stripe/resources/credit_note_line_item.rb +65 -0
  51. data/lib/stripe/resources/customer.rb +840 -0
  52. data/lib/stripe/resources/customer_balance_transaction.rb +27 -0
  53. data/lib/stripe/resources/customer_cash_balance_transaction.rb +109 -0
  54. data/lib/stripe/resources/customer_session.rb +159 -0
  55. data/lib/stripe/resources/discount.rb +29 -0
  56. data/lib/stripe/resources/dispute.rb +619 -0
  57. data/lib/stripe/resources/entitlements/active_entitlement.rb +46 -0
  58. data/lib/stripe/resources/entitlements/active_entitlement_summary.rb +23 -0
  59. data/lib/stripe/resources/entitlements/feature.rb +90 -0
  60. data/lib/stripe/resources/ephemeral_key.rb +21 -0
  61. data/lib/stripe/resources/event.rb +130 -0
  62. data/lib/stripe/resources/exchange_rate.rb +33 -0
  63. data/lib/stripe/resources/file.rb +111 -0
  64. data/lib/stripe/resources/file_link.rb +112 -0
  65. data/lib/stripe/resources/financial_connections/account.rb +260 -0
  66. data/lib/stripe/resources/financial_connections/account_inferred_balance.rb +27 -0
  67. data/lib/stripe/resources/financial_connections/account_owner.rb +17 -0
  68. data/lib/stripe/resources/financial_connections/account_ownership.rb +9 -0
  69. data/lib/stripe/resources/financial_connections/institution.rb +99 -0
  70. data/lib/stripe/resources/financial_connections/session.rb +159 -0
  71. data/lib/stripe/resources/financial_connections/transaction.rb +101 -0
  72. data/lib/stripe/resources/forwarding/request.rb +165 -0
  73. data/lib/stripe/resources/funding_instructions.rb +308 -0
  74. data/lib/stripe/resources/gift_cards/card.rb +217 -0
  75. data/lib/stripe/resources/gift_cards/transaction.rb +281 -0
  76. data/lib/stripe/resources/identity/verification_report.rb +266 -0
  77. data/lib/stripe/resources/identity/verification_session.rb +361 -0
  78. data/lib/stripe/resources/invoice.rb +8078 -0
  79. data/lib/stripe/resources/invoice_item.rb +445 -0
  80. data/lib/stripe/resources/invoice_line_item.rb +333 -0
  81. data/lib/stripe/resources/invoice_payment.rb +56 -0
  82. data/lib/stripe/resources/invoice_rendering_template.rb +67 -0
  83. data/lib/stripe/resources/issuing/authorization.rb +1113 -0
  84. data/lib/stripe/resources/issuing/card.rb +666 -0
  85. data/lib/stripe/resources/issuing/cardholder.rb +658 -0
  86. data/lib/stripe/resources/issuing/credit_underwriting_record.rb +611 -0
  87. data/lib/stripe/resources/issuing/dispute.rb +790 -0
  88. data/lib/stripe/resources/issuing/dispute_settlement_detail.rb +84 -0
  89. data/lib/stripe/resources/issuing/fraud_liability_debit.rb +95 -0
  90. data/lib/stripe/resources/issuing/personalization_design.rb +285 -0
  91. data/lib/stripe/resources/issuing/physical_bundle.rb +63 -0
  92. data/lib/stripe/resources/issuing/settlement.rb +49 -0
  93. data/lib/stripe/resources/issuing/token.rb +175 -0
  94. data/lib/stripe/resources/issuing/transaction.rb +927 -0
  95. data/lib/stripe/resources/line_item.rb +75 -0
  96. data/lib/stripe/resources/login_link.rb +7 -0
  97. data/lib/stripe/resources/mandate.rb +169 -0
  98. data/lib/stripe/resources/margin.rb +124 -0
  99. data/lib/stripe/resources/order.rb +2850 -0
  100. data/lib/stripe/resources/payment_attempt_record.rb +184 -0
  101. data/lib/stripe/resources/payment_intent.rb +12910 -0
  102. data/lib/stripe/resources/payment_link.rb +1563 -0
  103. data/lib/stripe/resources/payment_method.rb +1655 -0
  104. data/lib/stripe/resources/payment_method_configuration.rb +2903 -0
  105. data/lib/stripe/resources/payment_method_domain.rb +153 -0
  106. data/lib/stripe/resources/payment_record.rb +715 -0
  107. data/lib/stripe/resources/payout.rb +218 -0
  108. data/lib/stripe/resources/person.rb +263 -0
  109. data/lib/stripe/resources/plan.rb +317 -0
  110. data/lib/stripe/resources/price.rb +649 -0
  111. data/lib/stripe/resources/product.rb +536 -0
  112. data/lib/stripe/resources/product_feature.rb +12 -0
  113. data/lib/stripe/resources/promotion_code.rb +221 -0
  114. data/lib/stripe/resources/quote.rb +2946 -0
  115. data/lib/stripe/resources/quote_line.rb +274 -0
  116. data/lib/stripe/resources/quote_preview_invoice.rb +652 -0
  117. data/lib/stripe/resources/quote_preview_subscription_schedule.rb +362 -0
  118. data/lib/stripe/resources/radar/early_fraud_warning.rb +77 -0
  119. data/lib/stripe/resources/radar/value_list.rb +125 -0
  120. data/lib/stripe/resources/radar/value_list_item.rb +95 -0
  121. data/lib/stripe/resources/refund.rb +397 -0
  122. data/lib/stripe/resources/reporting/report_run.rb +150 -0
  123. data/lib/stripe/resources/reporting/report_type.rb +36 -0
  124. data/lib/stripe/resources/reserve_transaction.rb +22 -0
  125. data/lib/stripe/resources/reversal.rb +21 -0
  126. data/lib/stripe/resources/review.rb +108 -0
  127. data/lib/stripe/resources/setup_attempt.rb +373 -0
  128. data/lib/stripe/resources/setup_intent.rb +3855 -0
  129. data/lib/stripe/resources/shipping_rate.rb +259 -0
  130. data/lib/stripe/resources/sigma/scheduled_query_run.rb +54 -0
  131. data/lib/stripe/resources/source.rb +1239 -0
  132. data/lib/stripe/resources/source_mandate_notification.rb +66 -0
  133. data/lib/stripe/resources/source_transaction.rb +85 -0
  134. data/lib/stripe/resources/subscription.rb +2057 -0
  135. data/lib/stripe/resources/subscription_item.rb +433 -0
  136. data/lib/stripe/resources/subscription_schedule.rb +2402 -0
  137. data/lib/stripe/resources/tax/association.rb +89 -0
  138. data/lib/stripe/resources/tax/calculation.rb +387 -0
  139. data/lib/stripe/resources/tax/calculation_line_item.rb +56 -0
  140. data/lib/stripe/resources/tax/form.rb +220 -0
  141. data/lib/stripe/resources/tax/registration.rb +2382 -0
  142. data/lib/stripe/resources/tax/settings.rb +126 -0
  143. data/lib/stripe/resources/tax/transaction.rb +267 -0
  144. data/lib/stripe/resources/tax/transaction_line_item.rb +31 -0
  145. data/lib/stripe/resources/tax_code.rb +35 -0
  146. data/lib/stripe/resources/tax_deducted_at_source.rb +22 -0
  147. data/lib/stripe/resources/tax_id.rb +121 -0
  148. data/lib/stripe/resources/tax_rate.rb +202 -2
  149. data/lib/stripe/resources/terminal/configuration.rb +1060 -0
  150. data/lib/stripe/resources/terminal/connection_token.rb +18 -0
  151. data/lib/stripe/resources/terminal/location.rb +175 -0
  152. data/lib/stripe/resources/terminal/reader.rb +774 -0
  153. data/lib/stripe/resources/terminal/reader_collected_data.rb +40 -0
  154. data/lib/stripe/resources/test_helpers/test_clock.rb +86 -0
  155. data/lib/stripe/resources/token.rb +1168 -0
  156. data/lib/stripe/resources/topup.rb +174 -0
  157. data/lib/stripe/resources/transfer.rb +153 -0
  158. data/lib/stripe/resources/treasury/credit_reversal.rb +92 -0
  159. data/lib/stripe/resources/treasury/debit_reversal.rb +103 -0
  160. data/lib/stripe/resources/treasury/financial_account.rb +752 -0
  161. data/lib/stripe/resources/treasury/financial_account_features.rb +191 -0
  162. data/lib/stripe/resources/treasury/inbound_transfer.rb +235 -0
  163. data/lib/stripe/resources/treasury/outbound_payment.rb +495 -0
  164. data/lib/stripe/resources/treasury/outbound_transfer.rb +387 -0
  165. data/lib/stripe/resources/treasury/received_credit.rb +283 -0
  166. data/lib/stripe/resources/treasury/received_debit.rb +244 -0
  167. data/lib/stripe/resources/treasury/transaction.rb +176 -0
  168. data/lib/stripe/resources/treasury/transaction_entry.rb +157 -0
  169. data/lib/stripe/resources/usage_record.rb +13 -0
  170. data/lib/stripe/resources/usage_record_summary.rb +21 -0
  171. data/lib/stripe/resources/v2/amount.rb +9 -0
  172. data/lib/stripe/resources/v2/billing/meter_event.rb +18 -0
  173. data/lib/stripe/resources/v2/billing/meter_event_adjustment.rb +21 -0
  174. data/lib/stripe/resources/v2/billing/meter_event_session.rb +14 -0
  175. data/lib/stripe/resources/v2/event.rb +27 -0
  176. data/lib/stripe/resources/v2/event_destination.rb +59 -0
  177. data/lib/stripe/resources/webhook_endpoint.rb +122 -0
  178. data/lib/stripe/resources.rb +31 -0
  179. data/lib/stripe/services/account_capability_service.rb +32 -0
  180. data/lib/stripe/services/account_external_account_service.rb +250 -0
  181. data/lib/stripe/services/account_link_service.rb +46 -0
  182. data/lib/stripe/services/account_login_link_service.rb +9 -0
  183. data/lib/stripe/services/account_notice_service.rb +101 -0
  184. data/lib/stripe/services/account_person_service.rb +875 -0
  185. data/lib/stripe/services/account_service.rb +4441 -0
  186. data/lib/stripe/services/account_session_service.rb +700 -0
  187. data/lib/stripe/services/apple_pay_domain_service.rb +51 -0
  188. data/lib/stripe/services/application_fee_refund_service.rb +54 -0
  189. data/lib/stripe/services/application_fee_service.rb +57 -0
  190. data/lib/stripe/services/apps/secret_service.rb +116 -0
  191. data/lib/stripe/services/balance_service.rb +9 -0
  192. data/lib/stripe/services/balance_transaction_service.rb +69 -0
  193. data/lib/stripe/services/billing/alert_service.rb +113 -0
  194. data/lib/stripe/services/billing/credit_balance_summary_service.rb +48 -0
  195. data/lib/stripe/services/billing/credit_balance_transaction_service.rb +40 -0
  196. data/lib/stripe/services/billing/credit_grant_service.rb +162 -0
  197. data/lib/stripe/services/billing/meter_event_adjustment_service.rb +26 -0
  198. data/lib/stripe/services/billing/meter_event_service.rb +21 -0
  199. data/lib/stripe/services/billing/meter_event_summary_service.rb +39 -0
  200. data/lib/stripe/services/billing/meter_service.rb +130 -0
  201. data/lib/stripe/services/billing_portal/configuration_service.rb +444 -0
  202. data/lib/stripe/services/billing_portal/session_service.rb +173 -0
  203. data/lib/stripe/services/capital/financing_offer_service.rb +112 -0
  204. data/lib/stripe/services/capital/financing_summary_service.rb +28 -0
  205. data/lib/stripe/services/capital/financing_transaction_service.rb +79 -0
  206. data/lib/stripe/services/capital_service.rb +15 -0
  207. data/lib/stripe/services/charge_service.rb +1736 -0
  208. data/lib/stripe/services/checkout/session_line_item_service.rb +18 -0
  209. data/lib/stripe/services/checkout/session_service.rb +2485 -0
  210. data/lib/stripe/services/climate/order_service.rb +102 -0
  211. data/lib/stripe/services/climate/product_service.rb +27 -0
  212. data/lib/stripe/services/climate/supplier_service.rb +27 -0
  213. data/lib/stripe/services/confirmation_token_service.rb +9 -0
  214. data/lib/stripe/services/country_spec_service.rb +27 -0
  215. data/lib/stripe/services/coupon_service.rb +152 -0
  216. data/lib/stripe/services/credit_note_line_item_service.rb +18 -0
  217. data/lib/stripe/services/credit_note_preview_lines_service.rb +156 -0
  218. data/lib/stripe/services/credit_note_service.rb +373 -0
  219. data/lib/stripe/services/customer_balance_transaction_service.rb +63 -0
  220. data/lib/stripe/services/customer_cash_balance_service.rb +29 -0
  221. data/lib/stripe/services/customer_cash_balance_transaction_service.rb +27 -0
  222. data/lib/stripe/services/customer_funding_instructions_service.rb +42 -0
  223. data/lib/stripe/services/customer_payment_method_service.rb +40 -0
  224. data/lib/stripe/services/customer_payment_source_service.rb +179 -0
  225. data/lib/stripe/services/customer_service.rb +593 -0
  226. data/lib/stripe/services/customer_session_service.rb +96 -0
  227. data/lib/stripe/services/customer_tax_id_service.rb +45 -0
  228. data/lib/stripe/services/dispute_service.rb +374 -0
  229. data/lib/stripe/services/entitlements/active_entitlement_service.rb +36 -0
  230. data/lib/stripe/services/entitlements/feature_service.rb +76 -0
  231. data/lib/stripe/services/ephemeral_key_service.rb +36 -0
  232. data/lib/stripe/services/event_service.rb +65 -0
  233. data/lib/stripe/services/exchange_rate_service.rb +27 -0
  234. data/lib/stripe/services/file_link_service.rb +94 -0
  235. data/lib/stripe/services/file_service.rb +89 -0
  236. data/lib/stripe/services/financial_connections/account_inferred_balance_service.rb +37 -0
  237. data/lib/stripe/services/financial_connections/account_owner_service.rb +27 -0
  238. data/lib/stripe/services/financial_connections/account_service.rb +99 -1
  239. data/lib/stripe/services/financial_connections/institution_service.rb +57 -0
  240. data/lib/stripe/services/financial_connections/session_service.rb +97 -0
  241. data/lib/stripe/services/financial_connections/transaction_service.rb +70 -0
  242. data/lib/stripe/services/financial_connections_service.rb +2 -1
  243. data/lib/stripe/services/forwarding/request_service.rb +106 -0
  244. data/lib/stripe/services/gift_cards/card_service.rb +170 -0
  245. data/lib/stripe/services/gift_cards/transaction_service.rb +209 -0
  246. data/lib/stripe/services/gift_cards_service.rb +14 -0
  247. data/lib/stripe/services/identity/verification_report_service.rb +65 -0
  248. data/lib/stripe/services/identity/verification_session_service.rb +231 -0
  249. data/lib/stripe/services/invoice_item_service.rb +388 -0
  250. data/lib/stripe/services/invoice_line_item_service.rb +237 -0
  251. data/lib/stripe/services/invoice_payment_service.rb +55 -0
  252. data/lib/stripe/services/invoice_rendering_template_service.rb +51 -0
  253. data/lib/stripe/services/invoice_service.rb +5567 -1
  254. data/lib/stripe/services/invoice_upcoming_lines_service.rb +1864 -0
  255. data/lib/stripe/services/issuing/authorization_service.rb +104 -0
  256. data/lib/stripe/services/issuing/card_service.rb +455 -0
  257. data/lib/stripe/services/issuing/cardholder_service.rb +526 -0
  258. data/lib/stripe/services/issuing/credit_underwriting_record_service.rb +504 -0
  259. data/lib/stripe/services/issuing/dispute_service.rb +633 -0
  260. data/lib/stripe/services/issuing/dispute_settlement_detail_service.rb +66 -0
  261. data/lib/stripe/services/issuing/fraud_liability_debit_service.rb +83 -0
  262. data/lib/stripe/services/issuing/personalization_design_service.rb +193 -0
  263. data/lib/stripe/services/issuing/physical_bundle_service.rb +40 -0
  264. data/lib/stripe/services/issuing/token_service.rb +73 -0
  265. data/lib/stripe/services/issuing/transaction_service.rb +81 -0
  266. data/lib/stripe/services/issuing_service.rb +5 -1
  267. data/lib/stripe/services/mandate_service.rb +9 -0
  268. data/lib/stripe/services/margin_service.rb +119 -0
  269. data/lib/stripe/services/order_line_item_service.rb +35 -0
  270. data/lib/stripe/services/order_service.rb +2254 -0
  271. data/lib/stripe/services/payment_attempt_record_service.rb +49 -0
  272. data/lib/stripe/services/payment_intent_service.rb +10936 -0
  273. data/lib/stripe/services/payment_link_line_item_service.rb +18 -0
  274. data/lib/stripe/services/payment_link_service.rb +1223 -0
  275. data/lib/stripe/services/payment_method_configuration_service.rb +2088 -0
  276. data/lib/stripe/services/payment_method_domain_service.rb +76 -0
  277. data/lib/stripe/services/payment_method_service.rb +878 -0
  278. data/lib/stripe/services/payment_record_service.rb +542 -0
  279. data/lib/stripe/services/payout_service.rb +159 -0
  280. data/lib/stripe/services/plan_service.rb +253 -0
  281. data/lib/stripe/services/price_service.rb +516 -0
  282. data/lib/stripe/services/product_feature_service.rb +42 -0
  283. data/lib/stripe/services/product_service.rb +459 -0
  284. data/lib/stripe/services/promotion_code_service.rb +178 -0
  285. data/lib/stripe/services/quote_computed_upfront_line_items_service.rb +18 -0
  286. data/lib/stripe/services/quote_line_item_service.rb +18 -0
  287. data/lib/stripe/services/quote_line_service.rb +35 -0
  288. data/lib/stripe/services/quote_preview_invoice_service.rb +35 -0
  289. data/lib/stripe/services/quote_preview_subscription_schedule_service.rb +35 -0
  290. data/lib/stripe/services/quote_service.rb +2319 -1
  291. data/lib/stripe/services/radar/early_fraud_warning_service.rb +61 -0
  292. data/lib/stripe/services/radar/value_list_item_service.rb +79 -0
  293. data/lib/stripe/services/radar/value_list_service.rb +103 -0
  294. data/lib/stripe/services/refund_service.rb +137 -0
  295. data/lib/stripe/services/reporting/report_run_service.rb +106 -0
  296. data/lib/stripe/services/reporting/report_type_service.rb +18 -0
  297. data/lib/stripe/services/review_service.rb +56 -0
  298. data/lib/stripe/services/setup_attempt_service.rb +51 -0
  299. data/lib/stripe/services/setup_intent_service.rb +3497 -0
  300. data/lib/stripe/services/shipping_rate_service.rb +200 -0
  301. data/lib/stripe/services/sigma/scheduled_query_run_service.rb +27 -0
  302. data/lib/stripe/services/source_service.rb +601 -0
  303. data/lib/stripe/services/source_transaction_service.rb +18 -0
  304. data/lib/stripe/services/subscription_item_service.rb +383 -0
  305. data/lib/stripe/services/subscription_item_usage_record_service.rb +18 -0
  306. data/lib/stripe/services/subscription_item_usage_record_summary_service.rb +18 -0
  307. data/lib/stripe/services/subscription_schedule_service.rb +2053 -0
  308. data/lib/stripe/services/subscription_service.rb +1722 -0
  309. data/lib/stripe/services/tax/association_service.rb +31 -0
  310. data/lib/stripe/services/tax/calculation_line_item_service.rb +18 -0
  311. data/lib/stripe/services/tax/calculation_service.rb +205 -0
  312. data/lib/stripe/services/tax/form_service.rb +100 -0
  313. data/lib/stripe/services/tax/registration_service.rb +1564 -0
  314. data/lib/stripe/services/tax/settings_service.rb +74 -0
  315. data/lib/stripe/services/tax/transaction_line_item_service.rb +18 -0
  316. data/lib/stripe/services/tax/transaction_service.rb +111 -0
  317. data/lib/stripe/services/tax_code_service.rb +27 -0
  318. data/lib/stripe/services/tax_id_service.rb +79 -0
  319. data/lib/stripe/services/tax_rate_service.rb +155 -0
  320. data/lib/stripe/services/tax_service.rb +3 -1
  321. data/lib/stripe/services/terminal/configuration_service.rb +831 -0
  322. data/lib/stripe/services/terminal/connection_token_service.rb +12 -0
  323. data/lib/stripe/services/terminal/location_service.rb +144 -0
  324. data/lib/stripe/services/terminal/reader_collected_data_service.rb +28 -0
  325. data/lib/stripe/services/terminal/reader_service.rb +443 -0
  326. data/lib/stripe/services/terminal_service.rb +2 -1
  327. data/lib/stripe/services/test_helpers/confirmation_token_service.rb +680 -0
  328. data/lib/stripe/services/test_helpers/customer_service.rb +18 -0
  329. data/lib/stripe/services/test_helpers/issuing/authorization_service.rb +745 -0
  330. data/lib/stripe/services/test_helpers/issuing/card_service.rb +45 -0
  331. data/lib/stripe/services/test_helpers/issuing/personalization_design_service.rb +41 -0
  332. data/lib/stripe/services/test_helpers/issuing/transaction_service.rb +632 -0
  333. data/lib/stripe/services/test_helpers/refund_service.rb +9 -0
  334. data/lib/stripe/services/test_helpers/terminal/reader_service.rb +44 -0
  335. data/lib/stripe/services/test_helpers/test_clock_service.rb +57 -0
  336. data/lib/stripe/services/test_helpers/treasury/inbound_transfer_service.rb +38 -0
  337. data/lib/stripe/services/test_helpers/treasury/outbound_payment_service.rb +87 -0
  338. data/lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb +87 -0
  339. data/lib/stripe/services/test_helpers/treasury/received_credit_service.rb +84 -0
  340. data/lib/stripe/services/test_helpers/treasury/received_debit_service.rb +84 -0
  341. data/lib/stripe/services/token_service.rb +1140 -0
  342. data/lib/stripe/services/topup_service.rb +142 -0
  343. data/lib/stripe/services/transfer_reversal_service.rb +66 -0
  344. data/lib/stripe/services/transfer_service.rb +119 -0
  345. data/lib/stripe/services/treasury/credit_reversal_service.rb +59 -0
  346. data/lib/stripe/services/treasury/debit_reversal_service.rb +63 -0
  347. data/lib/stripe/services/treasury/financial_account_features_service.rb +169 -0
  348. data/lib/stripe/services/treasury/financial_account_service.rb +498 -0
  349. data/lib/stripe/services/treasury/inbound_transfer_service.rb +88 -0
  350. data/lib/stripe/services/treasury/outbound_payment_service.rb +258 -0
  351. data/lib/stripe/services/treasury/outbound_transfer_service.rb +148 -0
  352. data/lib/stripe/services/treasury/received_credit_service.rb +52 -0
  353. data/lib/stripe/services/treasury/received_debit_service.rb +40 -0
  354. data/lib/stripe/services/treasury/transaction_entry_service.rb +87 -0
  355. data/lib/stripe/services/treasury/transaction_service.rb +95 -0
  356. data/lib/stripe/services/v1_services.rb +8 -1
  357. data/lib/stripe/services/v2/billing/meter_event_adjustment_service.rb +23 -0
  358. data/lib/stripe/services/v2/billing/meter_event_service.rb +25 -0
  359. data/lib/stripe/services/v2/billing/meter_event_session_service.rb +3 -0
  360. data/lib/stripe/services/v2/billing/meter_event_stream_service.rb +33 -0
  361. data/lib/stripe/services/v2/core/event_destination_service.rb +146 -0
  362. data/lib/stripe/services/v2/core/event_service.rb +18 -0
  363. data/lib/stripe/services/webhook_endpoint_service.rb +96 -0
  364. data/lib/stripe/services.rb +25 -0
  365. data/lib/stripe/stripe_client.rb +1 -1
  366. data/lib/stripe/stripe_configuration.rb +3 -1
  367. data/lib/stripe/stripe_object.rb +5 -0
  368. data/lib/stripe/util.rb +7 -1
  369. data/lib/stripe/version.rb +1 -1
  370. data/lib/stripe.rb +46 -0
  371. data/rbi/stripe/resources/account.rbi +5188 -0
  372. data/rbi/stripe/resources/account_link.rbi +74 -0
  373. data/rbi/stripe/resources/account_notice.rbi +139 -0
  374. data/rbi/stripe/resources/account_session.rbi +1143 -0
  375. data/rbi/stripe/resources/apple_pay_domain.rbi +97 -0
  376. data/rbi/stripe/resources/application.rbi +20 -0
  377. data/rbi/stripe/resources/application_fee.rbi +123 -0
  378. data/rbi/stripe/resources/application_fee_refund.rbi +37 -0
  379. data/rbi/stripe/resources/apps/secret.rbi +195 -0
  380. data/rbi/stripe/resources/balance.rbi +187 -0
  381. data/rbi/stripe/resources/balance_transaction.rbi +149 -0
  382. data/rbi/stripe/resources/bank_account.rbi +127 -0
  383. data/rbi/stripe/resources/billing/alert.rbi +206 -0
  384. data/rbi/stripe/resources/billing/alert_triggered.rbi +28 -0
  385. data/rbi/stripe/resources/billing/credit_balance_summary.rbi +116 -0
  386. data/rbi/stripe/resources/billing/credit_balance_transaction.rbi +154 -0
  387. data/rbi/stripe/resources/billing/credit_grant.rbi +291 -0
  388. data/rbi/stripe/resources/billing/meter.rbi +233 -0
  389. data/rbi/stripe/resources/billing/meter_error_report.rbi +71 -0
  390. data/rbi/stripe/resources/billing/meter_event.rbi +64 -0
  391. data/rbi/stripe/resources/billing/meter_event_adjustment.rbi +64 -0
  392. data/rbi/stripe/resources/billing/meter_event_summary.rbi +35 -0
  393. data/rbi/stripe/resources/billing_portal/configuration.rbi +640 -0
  394. data/rbi/stripe/resources/billing_portal/session.rbi +341 -0
  395. data/rbi/stripe/resources/capability.rbi +125 -0
  396. data/rbi/stripe/resources/capital/financing_offer.rbi +190 -0
  397. data/rbi/stripe/resources/capital/financing_summary.rbi +74 -0
  398. data/rbi/stripe/resources/capital/financing_transaction.rbi +130 -0
  399. data/rbi/stripe/resources/card.rbi +128 -0
  400. data/rbi/stripe/resources/cash_balance.rbi +32 -0
  401. data/rbi/stripe/resources/charge.rbi +3494 -0
  402. data/rbi/stripe/resources/checkout/session.rbi +4036 -0
  403. data/rbi/stripe/resources/climate/order.rbi +250 -0
  404. data/rbi/stripe/resources/climate/product.rbi +82 -0
  405. data/rbi/stripe/resources/climate/supplier.rbi +79 -0
  406. data/rbi/stripe/resources/confirmation_token.rbi +1787 -0
  407. data/rbi/stripe/resources/connect_collection_transfer.rbi +26 -0
  408. data/rbi/stripe/resources/country_spec.rbi +92 -0
  409. data/rbi/stripe/resources/coupon.rbi +257 -0
  410. data/rbi/stripe/resources/credit_note.rbi +759 -0
  411. data/rbi/stripe/resources/credit_note_line_item.rbi +99 -0
  412. data/rbi/stripe/resources/customer.rbi +1001 -0
  413. data/rbi/stripe/resources/customer_balance_transaction.rbi +53 -0
  414. data/rbi/stripe/resources/customer_cash_balance_transaction.rbi +151 -0
  415. data/rbi/stripe/resources/customer_session.rbi +196 -0
  416. data/rbi/stripe/resources/discount.rbi +53 -0
  417. data/rbi/stripe/resources/dispute.rbi +764 -0
  418. data/rbi/stripe/resources/entitlements/active_entitlement.rbi +65 -0
  419. data/rbi/stripe/resources/entitlements/active_entitlement_summary.rbi +23 -0
  420. data/rbi/stripe/resources/entitlements/feature.rbi +124 -0
  421. data/rbi/stripe/resources/ephemeral_key.rbi +44 -0
  422. data/rbi/stripe/resources/event.rbi +190 -0
  423. data/rbi/stripe/resources/exchange_rate.rbi +73 -0
  424. data/rbi/stripe/resources/file.rbi +148 -0
  425. data/rbi/stripe/resources/file_link.rbi +146 -0
  426. data/rbi/stripe/resources/financial_connections/account.rbi +358 -0
  427. data/rbi/stripe/resources/financial_connections/account_inferred_balance.rbi +27 -0
  428. data/rbi/stripe/resources/financial_connections/account_owner.rbi +35 -0
  429. data/rbi/stripe/resources/financial_connections/account_ownership.rbi +23 -0
  430. data/rbi/stripe/resources/financial_connections/institution.rbi +99 -0
  431. data/rbi/stripe/resources/financial_connections/session.rbi +186 -0
  432. data/rbi/stripe/resources/financial_connections/transaction.rbi +127 -0
  433. data/rbi/stripe/resources/forwarding/request.rbi +219 -0
  434. data/rbi/stripe/resources/funding_instructions.rbi +437 -0
  435. data/rbi/stripe/resources/gift_cards/card.rbi +206 -0
  436. data/rbi/stripe/resources/gift_cards/transaction.rbi +257 -0
  437. data/rbi/stripe/resources/identity/verification_report.rbi +354 -0
  438. data/rbi/stripe/resources/identity/verification_session.rbi +518 -0
  439. data/rbi/stripe/resources/invoice.rbi +8928 -0
  440. data/rbi/stripe/resources/invoice_item.rbi +514 -0
  441. data/rbi/stripe/resources/invoice_line_item.rbi +400 -0
  442. data/rbi/stripe/resources/invoice_payment.rbi +70 -0
  443. data/rbi/stripe/resources/invoice_rendering_template.rbi +114 -0
  444. data/rbi/stripe/resources/issuing/authorization.rbi +1266 -0
  445. data/rbi/stripe/resources/issuing/card.rbi +738 -0
  446. data/rbi/stripe/resources/issuing/cardholder.rbi +732 -0
  447. data/rbi/stripe/resources/issuing/credit_underwriting_record.rbi +622 -0
  448. data/rbi/stripe/resources/issuing/dispute.rbi +900 -0
  449. data/rbi/stripe/resources/issuing/dispute_settlement_detail.rbi +83 -0
  450. data/rbi/stripe/resources/issuing/fraud_liability_debit.rbi +90 -0
  451. data/rbi/stripe/resources/issuing/personalization_design.rbi +333 -0
  452. data/rbi/stripe/resources/issuing/physical_bundle.rbi +86 -0
  453. data/rbi/stripe/resources/issuing/settlement.rbi +62 -0
  454. data/rbi/stripe/resources/issuing/token.rbi +231 -0
  455. data/rbi/stripe/resources/issuing/transaction.rbi +1057 -0
  456. data/rbi/stripe/resources/line_item.rbi +108 -0
  457. data/rbi/stripe/resources/login_link.rbi +18 -0
  458. data/rbi/stripe/resources/mandate.rbi +219 -0
  459. data/rbi/stripe/resources/margin.rbi +127 -0
  460. data/rbi/stripe/resources/order.rbi +3016 -0
  461. data/rbi/stripe/resources/payment_attempt_record.rbi +215 -0
  462. data/rbi/stripe/resources/payment_intent.rbi +13895 -0
  463. data/rbi/stripe/resources/payment_link.rbi +1666 -0
  464. data/rbi/stripe/resources/payment_method.rbi +1926 -0
  465. data/rbi/stripe/resources/payment_method_configuration.rbi +3237 -0
  466. data/rbi/stripe/resources/payment_method_domain.rbi +217 -0
  467. data/rbi/stripe/resources/payment_record.rbi +722 -0
  468. data/rbi/stripe/resources/payout.rbi +299 -0
  469. data/rbi/stripe/resources/person.rbi +371 -0
  470. data/rbi/stripe/resources/plan.rbi +385 -0
  471. data/rbi/stripe/resources/price.rbi +731 -0
  472. data/rbi/stripe/resources/product.rbi +615 -0
  473. data/rbi/stripe/resources/product_feature.rbi +26 -0
  474. data/rbi/stripe/resources/promotion_code.rbi +266 -0
  475. data/rbi/stripe/resources/quote.rbi +3186 -0
  476. data/rbi/stripe/resources/quote_line.rbi +350 -0
  477. data/rbi/stripe/resources/quote_preview_invoice.rbi +850 -0
  478. data/rbi/stripe/resources/quote_preview_subscription_schedule.rbi +474 -0
  479. data/rbi/stripe/resources/radar/early_fraud_warning.rbi +101 -0
  480. data/rbi/stripe/resources/radar/value_list.rbi +175 -0
  481. data/rbi/stripe/resources/radar/value_list_item.rbi +134 -0
  482. data/rbi/stripe/resources/refund.rbi +515 -0
  483. data/rbi/stripe/resources/reporting/report_run.rbi +194 -0
  484. data/rbi/stripe/resources/reporting/report_type.rbi +64 -0
  485. data/rbi/stripe/resources/reserve_transaction.rbi +23 -0
  486. data/rbi/stripe/resources/reversal.rbi +51 -0
  487. data/rbi/stripe/resources/review.rbi +159 -0
  488. data/rbi/stripe/resources/setup_attempt.rbi +484 -0
  489. data/rbi/stripe/resources/setup_intent.rbi +4062 -0
  490. data/rbi/stripe/resources/shipping_rate.rbi +310 -0
  491. data/rbi/stripe/resources/sigma/scheduled_query_run.rbi +82 -0
  492. data/rbi/stripe/resources/source.rbi +1543 -0
  493. data/rbi/stripe/resources/source_mandate_notification.rbi +77 -0
  494. data/rbi/stripe/resources/source_transaction.rbi +127 -0
  495. data/rbi/stripe/resources/subscription.rbi +2308 -0
  496. data/rbi/stripe/resources/subscription_item.rbi +478 -0
  497. data/rbi/stripe/resources/subscription_schedule.rbi +2653 -0
  498. data/rbi/stripe/resources/tax/association.rbi +94 -0
  499. data/rbi/stripe/resources/tax/calculation.rbi +479 -0
  500. data/rbi/stripe/resources/tax/calculation_line_item.rbi +88 -0
  501. data/rbi/stripe/resources/tax/form.rbi +224 -0
  502. data/rbi/stripe/resources/tax/registration.rbi +2438 -0
  503. data/rbi/stripe/resources/tax/settings.rbi +148 -0
  504. data/rbi/stripe/resources/tax/transaction.rbi +356 -0
  505. data/rbi/stripe/resources/tax/transaction_line_item.rbi +54 -0
  506. data/rbi/stripe/resources/tax_code.rbi +51 -0
  507. data/rbi/stripe/resources/tax_deducted_at_source.rbi +23 -0
  508. data/rbi/stripe/resources/tax_id.rbi +174 -0
  509. data/rbi/stripe/resources/tax_rate.rbi +244 -0
  510. data/rbi/stripe/resources/terminal/configuration.rbi +1143 -0
  511. data/rbi/stripe/resources/terminal/connection_token.rbi +37 -0
  512. data/rbi/stripe/resources/terminal/location.rbi +231 -0
  513. data/rbi/stripe/resources/terminal/reader.rbi +940 -0
  514. data/rbi/stripe/resources/terminal/reader_collected_data.rbi +41 -0
  515. data/rbi/stripe/resources/test_helpers/test_clock.rbi +139 -0
  516. data/rbi/stripe/resources/token.rbi +1192 -0
  517. data/rbi/stripe/resources/topup.rbi +225 -0
  518. data/rbi/stripe/resources/transfer.rbi +204 -0
  519. data/rbi/stripe/resources/treasury/credit_reversal.rbi +126 -0
  520. data/rbi/stripe/resources/treasury/debit_reversal.rbi +138 -0
  521. data/rbi/stripe/resources/treasury/financial_account.rbi +870 -0
  522. data/rbi/stripe/resources/treasury/financial_account_features.rbi +263 -0
  523. data/rbi/stripe/resources/treasury/inbound_transfer.rbi +302 -0
  524. data/rbi/stripe/resources/treasury/outbound_payment.rbi +589 -0
  525. data/rbi/stripe/resources/treasury/outbound_transfer.rbi +473 -0
  526. data/rbi/stripe/resources/treasury/received_credit.rbi +348 -0
  527. data/rbi/stripe/resources/treasury/received_debit.rbi +305 -0
  528. data/rbi/stripe/resources/treasury/transaction.rbi +216 -0
  529. data/rbi/stripe/resources/treasury/transaction_entry.rbi +193 -0
  530. data/rbi/stripe/resources/usage_record.rbi +32 -0
  531. data/rbi/stripe/resources/usage_record_summary.rbi +38 -0
  532. data/rbi/stripe/resources/v2/amount.rbi +14 -0
  533. data/rbi/stripe/resources/v2/billing/meter_event.rbi +37 -0
  534. data/rbi/stripe/resources/v2/billing/meter_event_adjustment.rbi +41 -0
  535. data/rbi/stripe/resources/v2/billing/meter_event_session.rbi +31 -0
  536. data/rbi/stripe/resources/v2/event.rbi +47 -0
  537. data/rbi/stripe/resources/v2/event_destination.rbi +90 -0
  538. data/rbi/stripe/resources/webhook_endpoint.rbi +177 -0
  539. data/rbi/stripe/services/account_capability_service.rbi +51 -0
  540. data/rbi/stripe/services/account_external_account_service.rbi +306 -0
  541. data/rbi/stripe/services/account_link_service.rbi +58 -0
  542. data/rbi/stripe/services/account_login_link_service.rbi +22 -0
  543. data/rbi/stripe/services/account_notice_service.rbi +90 -0
  544. data/rbi/stripe/services/account_person_service.rbi +903 -0
  545. data/rbi/stripe/services/account_service.rbi +4267 -0
  546. data/rbi/stripe/services/account_session_service.rbi +803 -0
  547. data/rbi/stripe/services/apple_pay_domain_service.rbi +78 -0
  548. data/rbi/stripe/services/application_fee_refund_service.rbi +91 -0
  549. data/rbi/stripe/services/application_fee_service.rbi +74 -0
  550. data/rbi/stripe/services/apps/secret_service.rbi +151 -0
  551. data/rbi/stripe/services/apps_service.rbi +9 -0
  552. data/rbi/stripe/services/balance_service.rbi +21 -0
  553. data/rbi/stripe/services/balance_transaction_service.rbi +89 -0
  554. data/rbi/stripe/services/billing/alert_service.rbi +152 -0
  555. data/rbi/stripe/services/billing/credit_balance_summary_service.rbi +68 -0
  556. data/rbi/stripe/services/billing/credit_balance_transaction_service.rbi +59 -0
  557. data/rbi/stripe/services/billing/credit_grant_service.rbi +205 -0
  558. data/rbi/stripe/services/billing/meter_event_adjustment_service.rbi +40 -0
  559. data/rbi/stripe/services/billing/meter_event_service.rbi +42 -0
  560. data/rbi/stripe/services/billing/meter_event_summary_service.rbi +54 -0
  561. data/rbi/stripe/services/billing/meter_service.rbi +163 -0
  562. data/rbi/stripe/services/billing_portal/configuration_service.rbi +497 -0
  563. data/rbi/stripe/services/billing_portal/session_service.rbi +202 -0
  564. data/rbi/stripe/services/billing_portal_service.rbi +10 -0
  565. data/rbi/stripe/services/billing_service.rbi +15 -0
  566. data/rbi/stripe/services/capital/financing_offer_service.rbi +95 -0
  567. data/rbi/stripe/services/capital/financing_summary_service.rbi +22 -0
  568. data/rbi/stripe/services/capital/financing_transaction_service.rbi +68 -0
  569. data/rbi/stripe/services/capital_service.rbi +11 -0
  570. data/rbi/stripe/services/charge_service.rbi +1816 -0
  571. data/rbi/stripe/services/checkout/session_line_item_service.rbi +33 -0
  572. data/rbi/stripe/services/checkout/session_service.rbi +2604 -0
  573. data/rbi/stripe/services/checkout_service.rbi +9 -0
  574. data/rbi/stripe/services/climate/order_service.rbi +140 -0
  575. data/rbi/stripe/services/climate/product_service.rbi +46 -0
  576. data/rbi/stripe/services/climate/supplier_service.rbi +46 -0
  577. data/rbi/stripe/services/climate_service.rbi +11 -0
  578. data/rbi/stripe/services/confirmation_token_service.rbi +20 -0
  579. data/rbi/stripe/services/country_spec_service.rbi +44 -0
  580. data/rbi/stripe/services/coupon_service.rbi +190 -0
  581. data/rbi/stripe/services/credit_note_line_item_service.rbi +31 -0
  582. data/rbi/stripe/services/credit_note_preview_lines_service.rbi +167 -0
  583. data/rbi/stripe/services/credit_note_service.rbi +420 -0
  584. data/rbi/stripe/services/customer_balance_transaction_service.rbi +92 -0
  585. data/rbi/stripe/services/customer_cash_balance_service.rbi +45 -0
  586. data/rbi/stripe/services/customer_cash_balance_transaction_service.rbi +44 -0
  587. data/rbi/stripe/services/customer_funding_instructions_service.rbi +59 -0
  588. data/rbi/stripe/services/customer_payment_method_service.rbi +57 -0
  589. data/rbi/stripe/services/customer_payment_source_service.rbi +228 -0
  590. data/rbi/stripe/services/customer_service.rbi +647 -0
  591. data/rbi/stripe/services/customer_session_service.rbi +110 -0
  592. data/rbi/stripe/services/customer_tax_id_service.rbi +72 -0
  593. data/rbi/stripe/services/dispute_service.rbi +422 -0
  594. data/rbi/stripe/services/entitlements/active_entitlement_service.rbi +55 -0
  595. data/rbi/stripe/services/entitlements/feature_service.rbi +107 -0
  596. data/rbi/stripe/services/entitlements_service.rbi +10 -0
  597. data/rbi/stripe/services/ephemeral_key_service.rbi +53 -0
  598. data/rbi/stripe/services/event_service.rbi +81 -0
  599. data/rbi/stripe/services/exchange_rate_service.rbi +44 -0
  600. data/rbi/stripe/services/file_link_service.rbi +122 -0
  601. data/rbi/stripe/services/file_service.rbi +114 -0
  602. data/rbi/stripe/services/financial_connections/account_inferred_balance_service.rbi +33 -0
  603. data/rbi/stripe/services/financial_connections/account_owner_service.rbi +42 -0
  604. data/rbi/stripe/services/financial_connections/account_service.rbi +132 -0
  605. data/rbi/stripe/services/financial_connections/institution_service.rbi +46 -0
  606. data/rbi/stripe/services/financial_connections/session_service.rbi +111 -0
  607. data/rbi/stripe/services/financial_connections/transaction_service.rbi +90 -0
  608. data/rbi/stripe/services/financial_connections_service.rbi +12 -0
  609. data/rbi/stripe/services/forwarding/request_service.rbi +132 -0
  610. data/rbi/stripe/services/forwarding_service.rbi +9 -0
  611. data/rbi/stripe/services/gift_cards/card_service.rbi +142 -0
  612. data/rbi/stripe/services/gift_cards/transaction_service.rbi +174 -0
  613. data/rbi/stripe/services/gift_cards_service.rbi +10 -0
  614. data/rbi/stripe/services/identity/verification_report_service.rbi +85 -0
  615. data/rbi/stripe/services/identity/verification_session_service.rbi +317 -0
  616. data/rbi/stripe/services/identity_service.rbi +10 -0
  617. data/rbi/stripe/services/invoice_item_service.rbi +424 -0
  618. data/rbi/stripe/services/invoice_line_item_service.rbi +270 -0
  619. data/rbi/stripe/services/invoice_payment_service.rbi +44 -0
  620. data/rbi/stripe/services/invoice_rendering_template_service.rbi +82 -0
  621. data/rbi/stripe/services/invoice_service.rbi +6040 -0
  622. data/rbi/stripe/services/invoice_upcoming_lines_service.rbi +2023 -0
  623. data/rbi/stripe/services/issuing/authorization_service.rbi +140 -0
  624. data/rbi/stripe/services/issuing/card_service.rbi +479 -0
  625. data/rbi/stripe/services/issuing/cardholder_service.rbi +568 -0
  626. data/rbi/stripe/services/issuing/credit_underwriting_record_service.rbi +498 -0
  627. data/rbi/stripe/services/issuing/dispute_service.rbi +701 -0
  628. data/rbi/stripe/services/issuing/dispute_settlement_detail_service.rbi +55 -0
  629. data/rbi/stripe/services/issuing/fraud_liability_debit_service.rbi +73 -0
  630. data/rbi/stripe/services/issuing/personalization_design_service.rbi +233 -0
  631. data/rbi/stripe/services/issuing/physical_bundle_service.rbi +59 -0
  632. data/rbi/stripe/services/issuing/token_service.rbi +95 -0
  633. data/rbi/stripe/services/issuing/transaction_service.rbi +103 -0
  634. data/rbi/stripe/services/issuing_service.rbi +19 -0
  635. data/rbi/stripe/services/mandate_service.rbi +20 -0
  636. data/rbi/stripe/services/margin_service.rbi +104 -0
  637. data/rbi/stripe/services/order_line_item_service.rbi +31 -0
  638. data/rbi/stripe/services/order_service.rbi +2306 -0
  639. data/rbi/stripe/services/payment_attempt_record_service.rbi +36 -0
  640. data/rbi/stripe/services/payment_intent_service.rbi +11477 -0
  641. data/rbi/stripe/services/payment_link_line_item_service.rbi +31 -0
  642. data/rbi/stripe/services/payment_link_service.rbi +1250 -0
  643. data/rbi/stripe/services/payment_method_configuration_service.rbi +2215 -0
  644. data/rbi/stripe/services/payment_method_domain_service.rbi +110 -0
  645. data/rbi/stripe/services/payment_method_service.rbi +897 -0
  646. data/rbi/stripe/services/payment_record_service.rbi +521 -0
  647. data/rbi/stripe/services/payout_service.rbi +197 -0
  648. data/rbi/stripe/services/plan_service.rbi +286 -0
  649. data/rbi/stripe/services/price_service.rbi +551 -0
  650. data/rbi/stripe/services/product_feature_service.rbi +69 -0
  651. data/rbi/stripe/services/product_service.rbi +503 -0
  652. data/rbi/stripe/services/promotion_code_service.rbi +210 -0
  653. data/rbi/stripe/services/quote_computed_upfront_line_items_service.rbi +31 -0
  654. data/rbi/stripe/services/quote_line_item_service.rbi +31 -0
  655. data/rbi/stripe/services/quote_line_service.rbi +31 -0
  656. data/rbi/stripe/services/quote_preview_invoice_service.rbi +31 -0
  657. data/rbi/stripe/services/quote_preview_subscription_schedule_service.rbi +31 -0
  658. data/rbi/stripe/services/quote_service.rbi +2390 -0
  659. data/rbi/stripe/services/radar/early_fraud_warning_service.rbi +83 -0
  660. data/rbi/stripe/services/radar/value_list_item_service.rbi +107 -0
  661. data/rbi/stripe/services/radar/value_list_service.rbi +139 -0
  662. data/rbi/stripe/services/radar_service.rbi +11 -0
  663. data/rbi/stripe/services/refund_service.rbi +181 -0
  664. data/rbi/stripe/services/reporting/report_run_service.rbi +131 -0
  665. data/rbi/stripe/services/reporting/report_type_service.rbi +35 -0
  666. data/rbi/stripe/services/reporting_service.rbi +10 -0
  667. data/rbi/stripe/services/review_service.rbi +82 -0
  668. data/rbi/stripe/services/setup_attempt_service.rbi +63 -0
  669. data/rbi/stripe/services/setup_intent_service.rbi +3630 -0
  670. data/rbi/stripe/services/shipping_rate_service.rbi +235 -0
  671. data/rbi/stripe/services/sigma/scheduled_query_run_service.rbi +46 -0
  672. data/rbi/stripe/services/sigma_service.rbi +9 -0
  673. data/rbi/stripe/services/source_service.rbi +647 -0
  674. data/rbi/stripe/services/source_transaction_service.rbi +31 -0
  675. data/rbi/stripe/services/subscription_item_service.rbi +422 -0
  676. data/rbi/stripe/services/subscription_item_usage_record_service.rbi +37 -0
  677. data/rbi/stripe/services/subscription_item_usage_record_summary_service.rbi +33 -0
  678. data/rbi/stripe/services/subscription_schedule_service.rbi +2208 -0
  679. data/rbi/stripe/services/subscription_service.rbi +1870 -0
  680. data/rbi/stripe/services/tax/association_service.rbi +25 -0
  681. data/rbi/stripe/services/tax/calculation_line_item_service.rbi +33 -0
  682. data/rbi/stripe/services/tax/calculation_service.rbi +228 -0
  683. data/rbi/stripe/services/tax/form_service.rbi +85 -0
  684. data/rbi/stripe/services/tax/registration_service.rbi +1517 -0
  685. data/rbi/stripe/services/tax/settings_service.rbi +93 -0
  686. data/rbi/stripe/services/tax/transaction_line_item_service.rbi +33 -0
  687. data/rbi/stripe/services/tax/transaction_service.rbi +142 -0
  688. data/rbi/stripe/services/tax_code_service.rbi +44 -0
  689. data/rbi/stripe/services/tax_id_service.rbi +112 -0
  690. data/rbi/stripe/services/tax_rate_service.rbi +183 -0
  691. data/rbi/stripe/services/tax_service.rbi +14 -0
  692. data/rbi/stripe/services/terminal/configuration_service.rbi +860 -0
  693. data/rbi/stripe/services/terminal/connection_token_service.rbi +25 -0
  694. data/rbi/stripe/services/terminal/location_service.rbi +184 -0
  695. data/rbi/stripe/services/terminal/reader_collected_data_service.rbi +22 -0
  696. data/rbi/stripe/services/terminal/reader_service.rbi +513 -0
  697. data/rbi/stripe/services/terminal_service.rbi +13 -0
  698. data/rbi/stripe/services/test_helpers/confirmation_token_service.rbi +787 -0
  699. data/rbi/stripe/services/test_helpers/customer_service.rbi +33 -0
  700. data/rbi/stripe/services/test_helpers/issuing/authorization_service.rbi +836 -0
  701. data/rbi/stripe/services/test_helpers/issuing/card_service.rbi +76 -0
  702. data/rbi/stripe/services/test_helpers/issuing/personalization_design_service.rbi +67 -0
  703. data/rbi/stripe/services/test_helpers/issuing/transaction_service.rbi +705 -0
  704. data/rbi/stripe/services/test_helpers/issuing_service.rbi +14 -0
  705. data/rbi/stripe/services/test_helpers/refund_service.rbi +22 -0
  706. data/rbi/stripe/services/test_helpers/terminal/reader_service.rbi +62 -0
  707. data/rbi/stripe/services/test_helpers/terminal_service.rbi +11 -0
  708. data/rbi/stripe/services/test_helpers/test_clock_service.rbi +90 -0
  709. data/rbi/stripe/services/test_helpers/treasury/inbound_transfer_service.rbi +64 -0
  710. data/rbi/stripe/services/test_helpers/treasury/outbound_payment_service.rbi +123 -0
  711. data/rbi/stripe/services/test_helpers/treasury/outbound_transfer_service.rbi +123 -0
  712. data/rbi/stripe/services/test_helpers/treasury/received_credit_service.rbi +114 -0
  713. data/rbi/stripe/services/test_helpers/treasury/received_debit_service.rbi +114 -0
  714. data/rbi/stripe/services/test_helpers/treasury_service.rbi +15 -0
  715. data/rbi/stripe/services/test_helpers_service.rbi +15 -0
  716. data/rbi/stripe/services/token_service.rbi +1155 -0
  717. data/rbi/stripe/services/topup_service.rbi +172 -0
  718. data/rbi/stripe/services/transfer_reversal_service.rbi +99 -0
  719. data/rbi/stripe/services/transfer_service.rbi +150 -0
  720. data/rbi/stripe/services/treasury/credit_reversal_service.rbi +84 -0
  721. data/rbi/stripe/services/treasury/debit_reversal_service.rbi +88 -0
  722. data/rbi/stripe/services/treasury/financial_account_features_service.rbi +201 -0
  723. data/rbi/stripe/services/treasury/financial_account_service.rbi +566 -0
  724. data/rbi/stripe/services/treasury/inbound_transfer_service.rbi +117 -0
  725. data/rbi/stripe/services/treasury/outbound_payment_service.rbi +300 -0
  726. data/rbi/stripe/services/treasury/outbound_transfer_service.rbi +182 -0
  727. data/rbi/stripe/services/treasury/received_credit_service.rbi +70 -0
  728. data/rbi/stripe/services/treasury/received_debit_service.rbi +59 -0
  729. data/rbi/stripe/services/treasury/transaction_entry_service.rbi +107 -0
  730. data/rbi/stripe/services/treasury/transaction_service.rbi +114 -0
  731. data/rbi/stripe/services/treasury_service.rbi +18 -0
  732. data/rbi/stripe/services/v1_services.rbi +83 -0
  733. data/rbi/stripe/services/v2/billing/meter_event_adjustment_service.rbi +39 -0
  734. data/rbi/stripe/services/v2/billing/meter_event_service.rbi +42 -0
  735. data/rbi/stripe/services/v2/billing/meter_event_session_service.rbi +20 -0
  736. data/rbi/stripe/services/v2/billing/meter_event_stream_service.rbi +55 -0
  737. data/rbi/stripe/services/v2/billing_service.rbi +14 -0
  738. data/rbi/stripe/services/v2/core/event_destination_service.rbi +203 -0
  739. data/rbi/stripe/services/v2/core/event_service.rbi +39 -0
  740. data/rbi/stripe/services/v2/core_service.rbi +12 -0
  741. data/rbi/stripe/services/v2_services.rbi +10 -0
  742. data/rbi/stripe/services/webhook_endpoint_service.rbi +131 -0
  743. metadata +435 -4
@@ -27,6 +27,3696 @@ module Stripe
27
27
  "checkout.session"
28
28
  end
29
29
 
30
+ class AdaptivePricing < Stripe::StripeObject
31
+ # Whether Adaptive Pricing is enabled.
32
+ attr_reader :enabled
33
+ end
34
+
35
+ class AfterExpiration < Stripe::StripeObject
36
+ class Recovery < Stripe::StripeObject
37
+ # Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
38
+ attr_reader :allow_promotion_codes
39
+ # If `true`, a recovery url will be generated to recover this Checkout Session if it
40
+ # expires before a transaction is completed. It will be attached to the
41
+ # Checkout Session object upon expiration.
42
+ attr_reader :enabled
43
+ # The timestamp at which the recovery URL will expire.
44
+ attr_reader :expires_at
45
+ # URL that creates a new Checkout Session when clicked that is a copy of this expired Checkout Session
46
+ attr_reader :url
47
+ end
48
+ # When set, configuration used to recover the Checkout Session on expiry.
49
+ attr_reader :recovery
50
+ end
51
+
52
+ class AutomaticTax < Stripe::StripeObject
53
+ class Liability < Stripe::StripeObject
54
+ # The connected account being referenced when `type` is `account`.
55
+ attr_reader :account
56
+ # Type of the account referenced.
57
+ attr_reader :type
58
+ end
59
+ # Indicates whether automatic tax is enabled for the session
60
+ attr_reader :enabled
61
+ # The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
62
+ attr_reader :liability
63
+ # The status of the most recent automated tax calculation for this session.
64
+ attr_reader :status
65
+ end
66
+
67
+ class CollectedInformation < Stripe::StripeObject
68
+ class ShippingDetails < Stripe::StripeObject
69
+ class Address < Stripe::StripeObject
70
+ # City, district, suburb, town, or village.
71
+ attr_reader :city
72
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
73
+ attr_reader :country
74
+ # Address line 1 (e.g., street, PO Box, or company name).
75
+ attr_reader :line1
76
+ # Address line 2 (e.g., apartment, suite, unit, or building).
77
+ attr_reader :line2
78
+ # ZIP or postal code.
79
+ attr_reader :postal_code
80
+ # State, county, province, or region.
81
+ attr_reader :state
82
+ end
83
+ # Attribute for field address
84
+ attr_reader :address
85
+ # The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
86
+ attr_reader :carrier
87
+ # Recipient name.
88
+ attr_reader :name
89
+ # Recipient phone (including extension).
90
+ attr_reader :phone
91
+ # The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
92
+ attr_reader :tracking_number
93
+ end
94
+
95
+ class TaxId < Stripe::StripeObject
96
+ # The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, or `unknown`
97
+ attr_reader :type
98
+ # The value of the tax ID.
99
+ attr_reader :value
100
+ end
101
+ # Customer’s business name for this Checkout Session
102
+ attr_reader :business_name
103
+ # Customer’s email for this Checkout Session
104
+ attr_reader :email
105
+ # Customer’s phone number for this Checkout Session
106
+ attr_reader :phone
107
+ # Shipping information for this Checkout Session.
108
+ attr_reader :shipping_details
109
+ # Customer’s tax ids for this Checkout Session.
110
+ attr_reader :tax_ids
111
+ end
112
+
113
+ class Consent < Stripe::StripeObject
114
+ # If `opt_in`, the customer consents to receiving promotional communications
115
+ # from the merchant about this Checkout Session.
116
+ attr_reader :promotions
117
+ # If `accepted`, the customer in this Checkout Session has agreed to the merchant's terms of service.
118
+ attr_reader :terms_of_service
119
+ end
120
+
121
+ class ConsentCollection < Stripe::StripeObject
122
+ class PaymentMethodReuseAgreement < Stripe::StripeObject
123
+ # Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.
124
+ #
125
+ # When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
126
+ attr_reader :position
127
+ end
128
+ # If set to `hidden`, it will hide legal text related to the reuse of a payment method.
129
+ attr_reader :payment_method_reuse_agreement
130
+ # If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
131
+ # Session will determine whether to display an option to opt into promotional communication
132
+ # from the merchant depending on the customer's locale. Only available to US merchants.
133
+ attr_reader :promotions
134
+ # If set to `required`, it requires customers to accept the terms of service before being able to pay.
135
+ attr_reader :terms_of_service
136
+ end
137
+
138
+ class CurrencyConversion < Stripe::StripeObject
139
+ # Total of all items in source currency before discounts or taxes are applied.
140
+ attr_reader :amount_subtotal
141
+ # Total of all items in source currency after discounts and taxes are applied.
142
+ attr_reader :amount_total
143
+ # Exchange rate used to convert source currency amounts to customer currency amounts
144
+ attr_reader :fx_rate
145
+ # Creation currency of the CheckoutSession before localization
146
+ attr_reader :source_currency
147
+ end
148
+
149
+ class CustomField < Stripe::StripeObject
150
+ class Dropdown < Stripe::StripeObject
151
+ class Option < Stripe::StripeObject
152
+ # The label for the option, displayed to the customer. Up to 100 characters.
153
+ attr_reader :label
154
+ # The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
155
+ attr_reader :value
156
+ end
157
+ # The value that will pre-fill on the payment page.
158
+ attr_reader :default_value
159
+ # The options available for the customer to select. Up to 200 options allowed.
160
+ attr_reader :options
161
+ # The option selected by the customer. This will be the `value` for the option.
162
+ attr_reader :value
163
+ end
164
+
165
+ class Label < Stripe::StripeObject
166
+ # Custom text for the label, displayed to the customer. Up to 50 characters.
167
+ attr_reader :custom
168
+ # The type of the label.
169
+ attr_reader :type
170
+ end
171
+
172
+ class Numeric < Stripe::StripeObject
173
+ # The value that will pre-fill the field on the payment page.
174
+ attr_reader :default_value
175
+ # The maximum character length constraint for the customer's input.
176
+ attr_reader :maximum_length
177
+ # The minimum character length requirement for the customer's input.
178
+ attr_reader :minimum_length
179
+ # The value entered by the customer, containing only digits.
180
+ attr_reader :value
181
+ end
182
+
183
+ class Text < Stripe::StripeObject
184
+ # The value that will pre-fill the field on the payment page.
185
+ attr_reader :default_value
186
+ # The maximum character length constraint for the customer's input.
187
+ attr_reader :maximum_length
188
+ # The minimum character length requirement for the customer's input.
189
+ attr_reader :minimum_length
190
+ # The value entered by the customer.
191
+ attr_reader :value
192
+ end
193
+ # Attribute for field dropdown
194
+ attr_reader :dropdown
195
+ # String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
196
+ attr_reader :key
197
+ # Attribute for field label
198
+ attr_reader :label
199
+ # Attribute for field numeric
200
+ attr_reader :numeric
201
+ # Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
202
+ attr_reader :optional
203
+ # Attribute for field text
204
+ attr_reader :text
205
+ # The type of the field.
206
+ attr_reader :type
207
+ end
208
+
209
+ class CustomText < Stripe::StripeObject
210
+ class AfterSubmit < Stripe::StripeObject
211
+ # Text may be up to 1200 characters in length.
212
+ attr_reader :message
213
+ end
214
+
215
+ class ShippingAddress < Stripe::StripeObject
216
+ # Text may be up to 1200 characters in length.
217
+ attr_reader :message
218
+ end
219
+
220
+ class Submit < Stripe::StripeObject
221
+ # Text may be up to 1200 characters in length.
222
+ attr_reader :message
223
+ end
224
+
225
+ class TermsOfServiceAcceptance < Stripe::StripeObject
226
+ # Text may be up to 1200 characters in length.
227
+ attr_reader :message
228
+ end
229
+ # Custom text that should be displayed after the payment confirmation button.
230
+ attr_reader :after_submit
231
+ # Custom text that should be displayed alongside shipping address collection.
232
+ attr_reader :shipping_address
233
+ # Custom text that should be displayed alongside the payment confirmation button.
234
+ attr_reader :submit
235
+ # Custom text that should be displayed in place of the default terms of service agreement text.
236
+ attr_reader :terms_of_service_acceptance
237
+ end
238
+
239
+ class CustomerDetails < Stripe::StripeObject
240
+ class Address < Stripe::StripeObject
241
+ # City, district, suburb, town, or village.
242
+ attr_reader :city
243
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
244
+ attr_reader :country
245
+ # Address line 1 (e.g., street, PO Box, or company name).
246
+ attr_reader :line1
247
+ # Address line 2 (e.g., apartment, suite, unit, or building).
248
+ attr_reader :line2
249
+ # ZIP or postal code.
250
+ attr_reader :postal_code
251
+ # State, county, province, or region.
252
+ attr_reader :state
253
+ end
254
+
255
+ class TaxId < Stripe::StripeObject
256
+ # The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, or `unknown`
257
+ attr_reader :type
258
+ # The value of the tax ID.
259
+ attr_reader :value
260
+ end
261
+ # The customer's address after a completed Checkout Session. Note: This property is populated only for sessions on or after March 30, 2022.
262
+ attr_reader :address
263
+ # The email associated with the Customer, if one exists, on the Checkout Session after a completed Checkout Session or at time of session expiry.
264
+ # Otherwise, if the customer has consented to promotional content, this value is the most recent valid email provided by the customer on the Checkout form.
265
+ attr_reader :email
266
+ # The customer's name after a completed Checkout Session. Note: This property is populated only for sessions on or after March 30, 2022.
267
+ attr_reader :name
268
+ # The customer's phone number after a completed Checkout Session.
269
+ attr_reader :phone
270
+ # The customer’s tax exempt status after a completed Checkout Session.
271
+ attr_reader :tax_exempt
272
+ # The customer’s tax IDs after a completed Checkout Session.
273
+ attr_reader :tax_ids
274
+ end
275
+
276
+ class Discount < Stripe::StripeObject
277
+ # Coupon attached to the Checkout Session.
278
+ attr_reader :coupon
279
+ # Promotion code attached to the Checkout Session.
280
+ attr_reader :promotion_code
281
+ end
282
+
283
+ class InvoiceCreation < Stripe::StripeObject
284
+ class InvoiceData < Stripe::StripeObject
285
+ class CustomField < Stripe::StripeObject
286
+ # The name of the custom field.
287
+ attr_reader :name
288
+ # The value of the custom field.
289
+ attr_reader :value
290
+ end
291
+
292
+ class Issuer < Stripe::StripeObject
293
+ # The connected account being referenced when `type` is `account`.
294
+ attr_reader :account
295
+ # Type of the account referenced.
296
+ attr_reader :type
297
+ end
298
+
299
+ class RenderingOptions < Stripe::StripeObject
300
+ # How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.
301
+ attr_reader :amount_tax_display
302
+ end
303
+ # The account tax IDs associated with the invoice.
304
+ attr_reader :account_tax_ids
305
+ # Custom fields displayed on the invoice.
306
+ attr_reader :custom_fields
307
+ # An arbitrary string attached to the object. Often useful for displaying to users.
308
+ attr_reader :description
309
+ # Footer displayed on the invoice.
310
+ attr_reader :footer
311
+ # The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
312
+ attr_reader :issuer
313
+ # 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.
314
+ attr_reader :metadata
315
+ # Options for invoice PDF rendering.
316
+ attr_reader :rendering_options
317
+ end
318
+ # Indicates whether invoice creation is enabled for the Checkout Session.
319
+ attr_reader :enabled
320
+ # Attribute for field invoice_data
321
+ attr_reader :invoice_data
322
+ end
323
+
324
+ class PaymentMethodConfigurationDetails < Stripe::StripeObject
325
+ # ID of the payment method configuration used.
326
+ attr_reader :id
327
+ # ID of the parent payment method configuration used.
328
+ attr_reader :parent
329
+ end
330
+
331
+ class PaymentMethodOptions < Stripe::StripeObject
332
+ class AcssDebit < Stripe::StripeObject
333
+ class MandateOptions < Stripe::StripeObject
334
+ # A URL for custom mandate text
335
+ attr_reader :custom_mandate_url
336
+ # List of Stripe products where this mandate can be selected automatically. Returned when the Session is in `setup` mode.
337
+ attr_reader :default_for
338
+ # Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.
339
+ attr_reader :interval_description
340
+ # Payment schedule for the mandate.
341
+ attr_reader :payment_schedule
342
+ # Transaction type of the mandate.
343
+ attr_reader :transaction_type
344
+ end
345
+ # Currency supported by the bank account. Returned when the Session is in `setup` mode.
346
+ attr_reader :currency
347
+ # Attribute for field mandate_options
348
+ attr_reader :mandate_options
349
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
350
+ #
351
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
352
+ #
353
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
354
+ #
355
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
356
+ attr_reader :setup_future_usage
357
+ # Bank account verification method.
358
+ attr_reader :verification_method
359
+ end
360
+
361
+ class Affirm < Stripe::StripeObject
362
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
363
+ #
364
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
365
+ #
366
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
367
+ #
368
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
369
+ attr_reader :setup_future_usage
370
+ end
371
+
372
+ class AfterpayClearpay < Stripe::StripeObject
373
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
374
+ #
375
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
376
+ #
377
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
378
+ #
379
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
380
+ attr_reader :setup_future_usage
381
+ end
382
+
383
+ class Alipay < Stripe::StripeObject
384
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
385
+ #
386
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
387
+ #
388
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
389
+ #
390
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
391
+ attr_reader :setup_future_usage
392
+ end
393
+
394
+ class AmazonPay < Stripe::StripeObject
395
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
396
+ #
397
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
398
+ #
399
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
400
+ #
401
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
402
+ attr_reader :setup_future_usage
403
+ end
404
+
405
+ class AuBecsDebit < Stripe::StripeObject
406
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
407
+ #
408
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
409
+ #
410
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
411
+ #
412
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
413
+ attr_reader :setup_future_usage
414
+ end
415
+
416
+ class BacsDebit < Stripe::StripeObject
417
+ class MandateOptions < Stripe::StripeObject
418
+ # Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
419
+ attr_reader :reference_prefix
420
+ end
421
+ # Attribute for field mandate_options
422
+ attr_reader :mandate_options
423
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
424
+ #
425
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
426
+ #
427
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
428
+ #
429
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
430
+ attr_reader :setup_future_usage
431
+ end
432
+
433
+ class Bancontact < Stripe::StripeObject
434
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
435
+ #
436
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
437
+ #
438
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
439
+ #
440
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
441
+ attr_reader :setup_future_usage
442
+ end
443
+
444
+ class Boleto < Stripe::StripeObject
445
+ # The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto voucher will expire on Wednesday at 23:59 America/Sao_Paulo time.
446
+ attr_reader :expires_after_days
447
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
448
+ #
449
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
450
+ #
451
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
452
+ #
453
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
454
+ attr_reader :setup_future_usage
455
+ end
456
+
457
+ class Card < Stripe::StripeObject
458
+ class Installments < Stripe::StripeObject
459
+ # Indicates if installments are enabled
460
+ attr_reader :enabled
461
+ end
462
+
463
+ class Restrictions < Stripe::StripeObject
464
+ # Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
465
+ attr_reader :brands_blocked
466
+ end
467
+ # Attribute for field installments
468
+ attr_reader :installments
469
+ # Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
470
+ attr_reader :request_decremental_authorization
471
+ # Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
472
+ attr_reader :request_extended_authorization
473
+ # Request ability to [increment the authorization](/payments/incremental-authorization) for this CheckoutSession.
474
+ attr_reader :request_incremental_authorization
475
+ # Request ability to make [multiple captures](/payments/multicapture) for this CheckoutSession.
476
+ attr_reader :request_multicapture
477
+ # Request ability to [overcapture](/payments/overcapture) for this CheckoutSession.
478
+ attr_reader :request_overcapture
479
+ # We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
480
+ attr_reader :request_three_d_secure
481
+ # Attribute for field restrictions
482
+ attr_reader :restrictions
483
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
484
+ #
485
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
486
+ #
487
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
488
+ #
489
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
490
+ attr_reader :setup_future_usage
491
+ # Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
492
+ attr_reader :statement_descriptor_suffix_kana
493
+ # Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
494
+ attr_reader :statement_descriptor_suffix_kanji
495
+ end
496
+
497
+ class Cashapp < Stripe::StripeObject
498
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
499
+ #
500
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
501
+ #
502
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
503
+ #
504
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
505
+ attr_reader :setup_future_usage
506
+ end
507
+
508
+ class CustomerBalance < Stripe::StripeObject
509
+ class BankTransfer < Stripe::StripeObject
510
+ class EuBankTransfer < Stripe::StripeObject
511
+ # The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
512
+ attr_reader :country
513
+ end
514
+ # Attribute for field eu_bank_transfer
515
+ attr_reader :eu_bank_transfer
516
+ # List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
517
+ #
518
+ # Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
519
+ attr_reader :requested_address_types
520
+ # The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
521
+ attr_reader :type
522
+ end
523
+ # Attribute for field bank_transfer
524
+ attr_reader :bank_transfer
525
+ # The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
526
+ attr_reader :funding_type
527
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
528
+ #
529
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
530
+ #
531
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
532
+ #
533
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
534
+ attr_reader :setup_future_usage
535
+ end
536
+
537
+ class Eps < Stripe::StripeObject
538
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
539
+ #
540
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
541
+ #
542
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
543
+ #
544
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
545
+ attr_reader :setup_future_usage
546
+ end
547
+
548
+ class Fpx < Stripe::StripeObject
549
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
550
+ #
551
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
552
+ #
553
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
554
+ #
555
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
556
+ attr_reader :setup_future_usage
557
+ end
558
+
559
+ class Giropay < Stripe::StripeObject
560
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
561
+ #
562
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
563
+ #
564
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
565
+ #
566
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
567
+ attr_reader :setup_future_usage
568
+ end
569
+
570
+ class Grabpay < Stripe::StripeObject
571
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
572
+ #
573
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
574
+ #
575
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
576
+ #
577
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
578
+ attr_reader :setup_future_usage
579
+ end
580
+
581
+ class Ideal < Stripe::StripeObject
582
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
583
+ #
584
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
585
+ #
586
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
587
+ #
588
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
589
+ attr_reader :setup_future_usage
590
+ end
591
+
592
+ class KakaoPay < Stripe::StripeObject
593
+ # Controls when the funds will be captured from the customer's account.
594
+ attr_reader :capture_method
595
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
596
+ #
597
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
598
+ #
599
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
600
+ #
601
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
602
+ attr_reader :setup_future_usage
603
+ end
604
+
605
+ class Klarna < Stripe::StripeObject
606
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
607
+ #
608
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
609
+ #
610
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
611
+ #
612
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
613
+ attr_reader :setup_future_usage
614
+ end
615
+
616
+ class Konbini < Stripe::StripeObject
617
+ # The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST.
618
+ attr_reader :expires_after_days
619
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
620
+ #
621
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
622
+ #
623
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
624
+ #
625
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
626
+ attr_reader :setup_future_usage
627
+ end
628
+
629
+ class KrCard < Stripe::StripeObject
630
+ # Controls when the funds will be captured from the customer's account.
631
+ attr_reader :capture_method
632
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
633
+ #
634
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
635
+ #
636
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
637
+ #
638
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
639
+ attr_reader :setup_future_usage
640
+ end
641
+
642
+ class Link < Stripe::StripeObject
643
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
644
+ #
645
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
646
+ #
647
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
648
+ #
649
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
650
+ attr_reader :setup_future_usage
651
+ end
652
+
653
+ class Mobilepay < Stripe::StripeObject
654
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
655
+ #
656
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
657
+ #
658
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
659
+ #
660
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
661
+ attr_reader :setup_future_usage
662
+ end
663
+
664
+ class Multibanco < Stripe::StripeObject
665
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
666
+ #
667
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
668
+ #
669
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
670
+ #
671
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
672
+ attr_reader :setup_future_usage
673
+ end
674
+
675
+ class NaverPay < Stripe::StripeObject
676
+ # Controls when the funds will be captured from the customer's account.
677
+ attr_reader :capture_method
678
+ end
679
+
680
+ class Oxxo < Stripe::StripeObject
681
+ # The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
682
+ attr_reader :expires_after_days
683
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
684
+ #
685
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
686
+ #
687
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
688
+ #
689
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
690
+ attr_reader :setup_future_usage
691
+ end
692
+
693
+ class P24 < Stripe::StripeObject
694
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
695
+ #
696
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
697
+ #
698
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
699
+ #
700
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
701
+ attr_reader :setup_future_usage
702
+ end
703
+
704
+ class Payco < Stripe::StripeObject
705
+ # Controls when the funds will be captured from the customer's account.
706
+ attr_reader :capture_method
707
+ end
708
+
709
+ class Paynow < Stripe::StripeObject
710
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
711
+ #
712
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
713
+ #
714
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
715
+ #
716
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
717
+ attr_reader :setup_future_usage
718
+ end
719
+
720
+ class Paypal < Stripe::StripeObject
721
+ # Controls when the funds will be captured from the customer's account.
722
+ attr_reader :capture_method
723
+ # Preferred locale of the PayPal checkout page that the customer is redirected to.
724
+ attr_reader :preferred_locale
725
+ # A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
726
+ attr_reader :reference
727
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
728
+ #
729
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
730
+ #
731
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
732
+ #
733
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
734
+ attr_reader :setup_future_usage
735
+ # The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
736
+ attr_reader :subsellers
737
+ end
738
+
739
+ class Payto < Stripe::StripeObject
740
+ class MandateOptions < Stripe::StripeObject
741
+ # Amount that will be collected. It is required when `amount_type` is `fixed`.
742
+ attr_reader :amount
743
+ # The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
744
+ attr_reader :amount_type
745
+ # Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
746
+ attr_reader :end_date
747
+ # The periodicity at which payments will be collected.
748
+ attr_reader :payment_schedule
749
+ # The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
750
+ attr_reader :payments_per_period
751
+ # The purpose for which payments are made. Defaults to retail.
752
+ attr_reader :purpose
753
+ # Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
754
+ attr_reader :start_date
755
+ end
756
+ # Attribute for field mandate_options
757
+ attr_reader :mandate_options
758
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
759
+ #
760
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
761
+ #
762
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
763
+ #
764
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
765
+ attr_reader :setup_future_usage
766
+ end
767
+
768
+ class Pix < Stripe::StripeObject
769
+ # The number of seconds after which Pix payment will expire.
770
+ attr_reader :expires_after_seconds
771
+ end
772
+
773
+ class RevolutPay < Stripe::StripeObject
774
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
775
+ #
776
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
777
+ #
778
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
779
+ #
780
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
781
+ attr_reader :setup_future_usage
782
+ end
783
+
784
+ class SamsungPay < Stripe::StripeObject
785
+ # Controls when the funds will be captured from the customer's account.
786
+ attr_reader :capture_method
787
+ end
788
+
789
+ class SepaDebit < Stripe::StripeObject
790
+ class MandateOptions < Stripe::StripeObject
791
+ # Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
792
+ attr_reader :reference_prefix
793
+ end
794
+ # Attribute for field mandate_options
795
+ attr_reader :mandate_options
796
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
797
+ #
798
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
799
+ #
800
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
801
+ #
802
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
803
+ attr_reader :setup_future_usage
804
+ end
805
+
806
+ class Sofort < Stripe::StripeObject
807
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
808
+ #
809
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
810
+ #
811
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
812
+ #
813
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
814
+ attr_reader :setup_future_usage
815
+ end
816
+
817
+ class Swish < Stripe::StripeObject
818
+ # The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
819
+ attr_reader :reference
820
+ end
821
+
822
+ class UsBankAccount < Stripe::StripeObject
823
+ class FinancialConnections < Stripe::StripeObject
824
+ class Filters < Stripe::StripeObject
825
+ # The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
826
+ attr_reader :account_subcategories
827
+ # The institution to use to filter for possible accounts to link.
828
+ attr_reader :institution
829
+ end
830
+
831
+ class ManualEntry < Stripe::StripeObject
832
+ # Settings for configuring manual entry of account details.
833
+ attr_reader :mode
834
+ end
835
+ # Attribute for field filters
836
+ attr_reader :filters
837
+ # Attribute for field manual_entry
838
+ attr_reader :manual_entry
839
+ # The list of permissions to request. The `payment_method` permission must be included.
840
+ attr_reader :permissions
841
+ # Data features requested to be retrieved upon account creation.
842
+ attr_reader :prefetch
843
+ # For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
844
+ attr_reader :return_url
845
+ end
846
+ # Attribute for field financial_connections
847
+ attr_reader :financial_connections
848
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
849
+ #
850
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
851
+ #
852
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
853
+ #
854
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
855
+ attr_reader :setup_future_usage
856
+ # Bank account verification method.
857
+ attr_reader :verification_method
858
+ end
859
+ # Attribute for field acss_debit
860
+ attr_reader :acss_debit
861
+ # Attribute for field affirm
862
+ attr_reader :affirm
863
+ # Attribute for field afterpay_clearpay
864
+ attr_reader :afterpay_clearpay
865
+ # Attribute for field alipay
866
+ attr_reader :alipay
867
+ # Attribute for field amazon_pay
868
+ attr_reader :amazon_pay
869
+ # Attribute for field au_becs_debit
870
+ attr_reader :au_becs_debit
871
+ # Attribute for field bacs_debit
872
+ attr_reader :bacs_debit
873
+ # Attribute for field bancontact
874
+ attr_reader :bancontact
875
+ # Attribute for field boleto
876
+ attr_reader :boleto
877
+ # Attribute for field card
878
+ attr_reader :card
879
+ # Attribute for field cashapp
880
+ attr_reader :cashapp
881
+ # Attribute for field customer_balance
882
+ attr_reader :customer_balance
883
+ # Attribute for field eps
884
+ attr_reader :eps
885
+ # Attribute for field fpx
886
+ attr_reader :fpx
887
+ # Attribute for field giropay
888
+ attr_reader :giropay
889
+ # Attribute for field grabpay
890
+ attr_reader :grabpay
891
+ # Attribute for field ideal
892
+ attr_reader :ideal
893
+ # Attribute for field kakao_pay
894
+ attr_reader :kakao_pay
895
+ # Attribute for field klarna
896
+ attr_reader :klarna
897
+ # Attribute for field konbini
898
+ attr_reader :konbini
899
+ # Attribute for field kr_card
900
+ attr_reader :kr_card
901
+ # Attribute for field link
902
+ attr_reader :link
903
+ # Attribute for field mobilepay
904
+ attr_reader :mobilepay
905
+ # Attribute for field multibanco
906
+ attr_reader :multibanco
907
+ # Attribute for field naver_pay
908
+ attr_reader :naver_pay
909
+ # Attribute for field oxxo
910
+ attr_reader :oxxo
911
+ # Attribute for field p24
912
+ attr_reader :p24
913
+ # Attribute for field payco
914
+ attr_reader :payco
915
+ # Attribute for field paynow
916
+ attr_reader :paynow
917
+ # Attribute for field paypal
918
+ attr_reader :paypal
919
+ # Attribute for field payto
920
+ attr_reader :payto
921
+ # Attribute for field pix
922
+ attr_reader :pix
923
+ # Attribute for field revolut_pay
924
+ attr_reader :revolut_pay
925
+ # Attribute for field samsung_pay
926
+ attr_reader :samsung_pay
927
+ # Attribute for field sepa_debit
928
+ attr_reader :sepa_debit
929
+ # Attribute for field sofort
930
+ attr_reader :sofort
931
+ # Attribute for field swish
932
+ attr_reader :swish
933
+ # Attribute for field us_bank_account
934
+ attr_reader :us_bank_account
935
+ end
936
+
937
+ class Permissions < Stripe::StripeObject
938
+ class Update < Stripe::StripeObject
939
+ # Determines which entity is allowed to update the line items.
940
+ #
941
+ # Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
942
+ #
943
+ # When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
944
+ attr_reader :line_items
945
+ # Determines which entity is allowed to update the shipping details.
946
+ #
947
+ # Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
948
+ #
949
+ # When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
950
+ attr_reader :shipping_details
951
+ end
952
+ # Permissions for updating the Checkout Session.
953
+ attr_reader :update
954
+ end
955
+
956
+ class PhoneNumberCollection < Stripe::StripeObject
957
+ # Indicates whether phone number collection is enabled for the session
958
+ attr_reader :enabled
959
+ end
960
+
961
+ class SavedPaymentMethodOptions < Stripe::StripeObject
962
+ # Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with ’allow_redisplay: ‘always’ are shown in Checkout.
963
+ attr_reader :allow_redisplay_filters
964
+ # Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
965
+ attr_reader :payment_method_remove
966
+ # Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
967
+ attr_reader :payment_method_save
968
+ end
969
+
970
+ class ShippingAddressCollection < Stripe::StripeObject
971
+ # An array of two-letter ISO country codes representing which countries Checkout should provide as options for
972
+ # shipping locations. Unsupported country codes: `AS, CX, CC, CU, HM, IR, KP, MH, FM, NF, MP, PW, SY, UM, VI`.
973
+ attr_reader :allowed_countries
974
+ end
975
+
976
+ class ShippingCost < Stripe::StripeObject
977
+ class Tax < Stripe::StripeObject
978
+ # Amount of tax applied for this rate.
979
+ attr_reader :amount
980
+ # Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
981
+ #
982
+ # Related guide: [Tax rates](/billing/taxes/tax-rates)
983
+ attr_reader :rate
984
+ # The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.
985
+ attr_reader :taxability_reason
986
+ # The amount on which tax is calculated, in cents (or local equivalent).
987
+ attr_reader :taxable_amount
988
+ end
989
+ # Total shipping cost before any discounts or taxes are applied.
990
+ attr_reader :amount_subtotal
991
+ # Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.
992
+ attr_reader :amount_tax
993
+ # Total shipping cost after discounts and taxes are applied.
994
+ attr_reader :amount_total
995
+ # The ID of the ShippingRate for this order.
996
+ attr_reader :shipping_rate
997
+ # The taxes applied to the shipping rate.
998
+ attr_reader :taxes
999
+ end
1000
+
1001
+ class ShippingDetails < Stripe::StripeObject
1002
+ class Address < Stripe::StripeObject
1003
+ # City, district, suburb, town, or village.
1004
+ attr_reader :city
1005
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
1006
+ attr_reader :country
1007
+ # Address line 1 (e.g., street, PO Box, or company name).
1008
+ attr_reader :line1
1009
+ # Address line 2 (e.g., apartment, suite, unit, or building).
1010
+ attr_reader :line2
1011
+ # ZIP or postal code.
1012
+ attr_reader :postal_code
1013
+ # State, county, province, or region.
1014
+ attr_reader :state
1015
+ end
1016
+ # Attribute for field address
1017
+ attr_reader :address
1018
+ # The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
1019
+ attr_reader :carrier
1020
+ # Recipient name.
1021
+ attr_reader :name
1022
+ # Recipient phone (including extension).
1023
+ attr_reader :phone
1024
+ # The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
1025
+ attr_reader :tracking_number
1026
+ end
1027
+
1028
+ class ShippingOption < Stripe::StripeObject
1029
+ # A non-negative integer in cents representing how much to charge.
1030
+ attr_reader :shipping_amount
1031
+ # The shipping rate.
1032
+ attr_reader :shipping_rate
1033
+ end
1034
+
1035
+ class TaxIdCollection < Stripe::StripeObject
1036
+ # Indicates whether tax ID collection is enabled for the session
1037
+ attr_reader :enabled
1038
+ # Indicates whether a tax ID is required on the payment page
1039
+ attr_reader :required
1040
+ end
1041
+
1042
+ class TotalDetails < Stripe::StripeObject
1043
+ class Breakdown < Stripe::StripeObject
1044
+ class Discount < Stripe::StripeObject
1045
+ # The amount discounted.
1046
+ attr_reader :amount
1047
+ # A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
1048
+ # It contains information about when the discount began, when it will end, and what it is applied to.
1049
+ #
1050
+ # Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
1051
+ attr_reader :discount
1052
+ end
1053
+
1054
+ class Tax < Stripe::StripeObject
1055
+ # Amount of tax applied for this rate.
1056
+ attr_reader :amount
1057
+ # Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
1058
+ #
1059
+ # Related guide: [Tax rates](/billing/taxes/tax-rates)
1060
+ attr_reader :rate
1061
+ # The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.
1062
+ attr_reader :taxability_reason
1063
+ # The amount on which tax is calculated, in cents (or local equivalent).
1064
+ attr_reader :taxable_amount
1065
+ end
1066
+ # The aggregated discounts.
1067
+ attr_reader :discounts
1068
+ # The aggregated tax amounts by rate.
1069
+ attr_reader :taxes
1070
+ end
1071
+ # This is the sum of all the discounts.
1072
+ attr_reader :amount_discount
1073
+ # This is the sum of all the shipping amounts.
1074
+ attr_reader :amount_shipping
1075
+ # This is the sum of all the tax amounts.
1076
+ attr_reader :amount_tax
1077
+ # Attribute for field breakdown
1078
+ attr_reader :breakdown
1079
+ end
1080
+
1081
+ class ListParams < Stripe::RequestParams
1082
+ class Created < Stripe::RequestParams
1083
+ # Minimum value to filter by (exclusive)
1084
+ attr_accessor :gt
1085
+ # Minimum value to filter by (inclusive)
1086
+ attr_accessor :gte
1087
+ # Maximum value to filter by (exclusive)
1088
+ attr_accessor :lt
1089
+ # Maximum value to filter by (inclusive)
1090
+ attr_accessor :lte
1091
+
1092
+ def initialize(gt: nil, gte: nil, lt: nil, lte: nil)
1093
+ @gt = gt
1094
+ @gte = gte
1095
+ @lt = lt
1096
+ @lte = lte
1097
+ end
1098
+ end
1099
+
1100
+ class CustomerDetails < Stripe::RequestParams
1101
+ # Customer's email address.
1102
+ attr_accessor :email
1103
+
1104
+ def initialize(email: nil)
1105
+ @email = email
1106
+ end
1107
+ end
1108
+ # Only return Checkout Sessions that were created during the given date interval.
1109
+ attr_accessor :created
1110
+ # Only return the Checkout Sessions for the Customer specified.
1111
+ attr_accessor :customer
1112
+ # Only return the Checkout Sessions for the Customer details specified.
1113
+ attr_accessor :customer_details
1114
+ # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
1115
+ attr_accessor :ending_before
1116
+ # Specifies which fields in the response should be expanded.
1117
+ attr_accessor :expand
1118
+ # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
1119
+ attr_accessor :limit
1120
+ # Only return the Checkout Session for the PaymentIntent specified.
1121
+ attr_accessor :payment_intent
1122
+ # Only return the Checkout Sessions for the Payment Link specified.
1123
+ attr_accessor :payment_link
1124
+ # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
1125
+ attr_accessor :starting_after
1126
+ # Only return the Checkout Sessions matching the given status.
1127
+ attr_accessor :status
1128
+ # Only return the Checkout Session for the subscription specified.
1129
+ attr_accessor :subscription
1130
+
1131
+ def initialize(
1132
+ created: nil,
1133
+ customer: nil,
1134
+ customer_details: nil,
1135
+ ending_before: nil,
1136
+ expand: nil,
1137
+ limit: nil,
1138
+ payment_intent: nil,
1139
+ payment_link: nil,
1140
+ starting_after: nil,
1141
+ status: nil,
1142
+ subscription: nil
1143
+ )
1144
+ @created = created
1145
+ @customer = customer
1146
+ @customer_details = customer_details
1147
+ @ending_before = ending_before
1148
+ @expand = expand
1149
+ @limit = limit
1150
+ @payment_intent = payment_intent
1151
+ @payment_link = payment_link
1152
+ @starting_after = starting_after
1153
+ @status = status
1154
+ @subscription = subscription
1155
+ end
1156
+ end
1157
+
1158
+ class CreateParams < Stripe::RequestParams
1159
+ class AdaptivePricing < Stripe::RequestParams
1160
+ # Set to `true` to enable [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing). Defaults to your [dashboard setting](https://dashboard.stripe.com/settings/adaptive-pricing).
1161
+ attr_accessor :enabled
1162
+
1163
+ def initialize(enabled: nil)
1164
+ @enabled = enabled
1165
+ end
1166
+ end
1167
+
1168
+ class AfterExpiration < Stripe::RequestParams
1169
+ class Recovery < Stripe::RequestParams
1170
+ # Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
1171
+ attr_accessor :allow_promotion_codes
1172
+ # If `true`, a recovery URL will be generated to recover this Checkout Session if it
1173
+ # expires before a successful transaction is completed. It will be attached to the
1174
+ # Checkout Session object upon expiration.
1175
+ attr_accessor :enabled
1176
+
1177
+ def initialize(allow_promotion_codes: nil, enabled: nil)
1178
+ @allow_promotion_codes = allow_promotion_codes
1179
+ @enabled = enabled
1180
+ end
1181
+ end
1182
+ # Configure a Checkout Session that can be used to recover an expired session.
1183
+ attr_accessor :recovery
1184
+
1185
+ def initialize(recovery: nil)
1186
+ @recovery = recovery
1187
+ end
1188
+ end
1189
+
1190
+ class AutomaticTax < Stripe::RequestParams
1191
+ class Liability < Stripe::RequestParams
1192
+ # The connected account being referenced when `type` is `account`.
1193
+ attr_accessor :account
1194
+ # Type of the account referenced in the request.
1195
+ attr_accessor :type
1196
+
1197
+ def initialize(account: nil, type: nil)
1198
+ @account = account
1199
+ @type = type
1200
+ end
1201
+ end
1202
+ # Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
1203
+ #
1204
+ # Enabling this parameter causes Checkout to collect any billing address information necessary for tax calculation.
1205
+ attr_accessor :enabled
1206
+ # The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
1207
+ attr_accessor :liability
1208
+
1209
+ def initialize(enabled: nil, liability: nil)
1210
+ @enabled = enabled
1211
+ @liability = liability
1212
+ end
1213
+ end
1214
+
1215
+ class ConsentCollection < Stripe::RequestParams
1216
+ class PaymentMethodReuseAgreement < Stripe::RequestParams
1217
+ # Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
1218
+ # defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
1219
+ attr_accessor :position
1220
+
1221
+ def initialize(position: nil)
1222
+ @position = position
1223
+ end
1224
+ end
1225
+ # Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
1226
+ attr_accessor :payment_method_reuse_agreement
1227
+ # If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
1228
+ # Session will determine whether to display an option to opt into promotional communication
1229
+ # from the merchant depending on the customer's locale. Only available to US merchants.
1230
+ attr_accessor :promotions
1231
+ # If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
1232
+ # There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
1233
+ attr_accessor :terms_of_service
1234
+
1235
+ def initialize(
1236
+ payment_method_reuse_agreement: nil,
1237
+ promotions: nil,
1238
+ terms_of_service: nil
1239
+ )
1240
+ @payment_method_reuse_agreement = payment_method_reuse_agreement
1241
+ @promotions = promotions
1242
+ @terms_of_service = terms_of_service
1243
+ end
1244
+ end
1245
+
1246
+ class CustomField < Stripe::RequestParams
1247
+ class Dropdown < Stripe::RequestParams
1248
+ class Option < Stripe::RequestParams
1249
+ # The label for the option, displayed to the customer. Up to 100 characters.
1250
+ attr_accessor :label
1251
+ # The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
1252
+ attr_accessor :value
1253
+
1254
+ def initialize(label: nil, value: nil)
1255
+ @label = label
1256
+ @value = value
1257
+ end
1258
+ end
1259
+ # The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
1260
+ attr_accessor :default_value
1261
+ # The options available for the customer to select. Up to 200 options allowed.
1262
+ attr_accessor :options
1263
+
1264
+ def initialize(default_value: nil, options: nil)
1265
+ @default_value = default_value
1266
+ @options = options
1267
+ end
1268
+ end
1269
+
1270
+ class Label < Stripe::RequestParams
1271
+ # Custom text for the label, displayed to the customer. Up to 50 characters.
1272
+ attr_accessor :custom
1273
+ # The type of the label.
1274
+ attr_accessor :type
1275
+
1276
+ def initialize(custom: nil, type: nil)
1277
+ @custom = custom
1278
+ @type = type
1279
+ end
1280
+ end
1281
+
1282
+ class Numeric < Stripe::RequestParams
1283
+ # The value that will pre-fill the field on the payment page.
1284
+ attr_accessor :default_value
1285
+ # The maximum character length constraint for the customer's input.
1286
+ attr_accessor :maximum_length
1287
+ # The minimum character length requirement for the customer's input.
1288
+ attr_accessor :minimum_length
1289
+
1290
+ def initialize(default_value: nil, maximum_length: nil, minimum_length: nil)
1291
+ @default_value = default_value
1292
+ @maximum_length = maximum_length
1293
+ @minimum_length = minimum_length
1294
+ end
1295
+ end
1296
+
1297
+ class Text < Stripe::RequestParams
1298
+ # The value that will pre-fill the field on the payment page.
1299
+ attr_accessor :default_value
1300
+ # The maximum character length constraint for the customer's input.
1301
+ attr_accessor :maximum_length
1302
+ # The minimum character length requirement for the customer's input.
1303
+ attr_accessor :minimum_length
1304
+
1305
+ def initialize(default_value: nil, maximum_length: nil, minimum_length: nil)
1306
+ @default_value = default_value
1307
+ @maximum_length = maximum_length
1308
+ @minimum_length = minimum_length
1309
+ end
1310
+ end
1311
+ # Configuration for `type=dropdown` fields.
1312
+ attr_accessor :dropdown
1313
+ # String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
1314
+ attr_accessor :key
1315
+ # The label for the field, displayed to the customer.
1316
+ attr_accessor :label
1317
+ # Configuration for `type=numeric` fields.
1318
+ attr_accessor :numeric
1319
+ # Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
1320
+ attr_accessor :optional
1321
+ # Configuration for `type=text` fields.
1322
+ attr_accessor :text
1323
+ # The type of the field.
1324
+ attr_accessor :type
1325
+
1326
+ def initialize(
1327
+ dropdown: nil,
1328
+ key: nil,
1329
+ label: nil,
1330
+ numeric: nil,
1331
+ optional: nil,
1332
+ text: nil,
1333
+ type: nil
1334
+ )
1335
+ @dropdown = dropdown
1336
+ @key = key
1337
+ @label = label
1338
+ @numeric = numeric
1339
+ @optional = optional
1340
+ @text = text
1341
+ @type = type
1342
+ end
1343
+ end
1344
+
1345
+ class CustomText < Stripe::RequestParams
1346
+ class AfterSubmit < Stripe::RequestParams
1347
+ # Text may be up to 1200 characters in length.
1348
+ attr_accessor :message
1349
+
1350
+ def initialize(message: nil)
1351
+ @message = message
1352
+ end
1353
+ end
1354
+
1355
+ class ShippingAddress < Stripe::RequestParams
1356
+ # Text may be up to 1200 characters in length.
1357
+ attr_accessor :message
1358
+
1359
+ def initialize(message: nil)
1360
+ @message = message
1361
+ end
1362
+ end
1363
+
1364
+ class Submit < Stripe::RequestParams
1365
+ # Text may be up to 1200 characters in length.
1366
+ attr_accessor :message
1367
+
1368
+ def initialize(message: nil)
1369
+ @message = message
1370
+ end
1371
+ end
1372
+
1373
+ class TermsOfServiceAcceptance < Stripe::RequestParams
1374
+ # Text may be up to 1200 characters in length.
1375
+ attr_accessor :message
1376
+
1377
+ def initialize(message: nil)
1378
+ @message = message
1379
+ end
1380
+ end
1381
+ # Custom text that should be displayed after the payment confirmation button.
1382
+ attr_accessor :after_submit
1383
+ # Custom text that should be displayed alongside shipping address collection.
1384
+ attr_accessor :shipping_address
1385
+ # Custom text that should be displayed alongside the payment confirmation button.
1386
+ attr_accessor :submit
1387
+ # Custom text that should be displayed in place of the default terms of service agreement text.
1388
+ attr_accessor :terms_of_service_acceptance
1389
+
1390
+ def initialize(
1391
+ after_submit: nil,
1392
+ shipping_address: nil,
1393
+ submit: nil,
1394
+ terms_of_service_acceptance: nil
1395
+ )
1396
+ @after_submit = after_submit
1397
+ @shipping_address = shipping_address
1398
+ @submit = submit
1399
+ @terms_of_service_acceptance = terms_of_service_acceptance
1400
+ end
1401
+ end
1402
+
1403
+ class CustomerUpdate < Stripe::RequestParams
1404
+ # Describes whether Checkout saves the billing address onto `customer.address`.
1405
+ # To always collect a full billing address, use `billing_address_collection`. Defaults to `never`.
1406
+ attr_accessor :address
1407
+ # Describes whether Checkout saves the name onto `customer.name`. Defaults to `never`.
1408
+ attr_accessor :name
1409
+ # Describes whether Checkout saves shipping information onto `customer.shipping`.
1410
+ # To collect shipping information, use `shipping_address_collection`. Defaults to `never`.
1411
+ attr_accessor :shipping
1412
+
1413
+ def initialize(address: nil, name: nil, shipping: nil)
1414
+ @address = address
1415
+ @name = name
1416
+ @shipping = shipping
1417
+ end
1418
+ end
1419
+
1420
+ class Discount < Stripe::RequestParams
1421
+ # The ID of the coupon to apply to this Session.
1422
+ attr_accessor :coupon
1423
+ # The ID of a promotion code to apply to this Session.
1424
+ attr_accessor :promotion_code
1425
+
1426
+ def initialize(coupon: nil, promotion_code: nil)
1427
+ @coupon = coupon
1428
+ @promotion_code = promotion_code
1429
+ end
1430
+ end
1431
+
1432
+ class InvoiceCreation < Stripe::RequestParams
1433
+ class InvoiceData < Stripe::RequestParams
1434
+ class CustomField < Stripe::RequestParams
1435
+ # The name of the custom field. This may be up to 40 characters.
1436
+ attr_accessor :name
1437
+ # The value of the custom field. This may be up to 140 characters.
1438
+ attr_accessor :value
1439
+
1440
+ def initialize(name: nil, value: nil)
1441
+ @name = name
1442
+ @value = value
1443
+ end
1444
+ end
1445
+
1446
+ class Issuer < Stripe::RequestParams
1447
+ # The connected account being referenced when `type` is `account`.
1448
+ attr_accessor :account
1449
+ # Type of the account referenced in the request.
1450
+ attr_accessor :type
1451
+
1452
+ def initialize(account: nil, type: nil)
1453
+ @account = account
1454
+ @type = type
1455
+ end
1456
+ end
1457
+
1458
+ class RenderingOptions < Stripe::RequestParams
1459
+ # How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
1460
+ attr_accessor :amount_tax_display
1461
+
1462
+ def initialize(amount_tax_display: nil)
1463
+ @amount_tax_display = amount_tax_display
1464
+ end
1465
+ end
1466
+ # The account tax IDs associated with the invoice.
1467
+ attr_accessor :account_tax_ids
1468
+ # Default custom fields to be displayed on invoices for this customer.
1469
+ attr_accessor :custom_fields
1470
+ # An arbitrary string attached to the object. Often useful for displaying to users.
1471
+ attr_accessor :description
1472
+ # Default footer to be displayed on invoices for this customer.
1473
+ attr_accessor :footer
1474
+ # The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
1475
+ attr_accessor :issuer
1476
+ # 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`.
1477
+ attr_accessor :metadata
1478
+ # Default options for invoice PDF rendering for this customer.
1479
+ attr_accessor :rendering_options
1480
+
1481
+ def initialize(
1482
+ account_tax_ids: nil,
1483
+ custom_fields: nil,
1484
+ description: nil,
1485
+ footer: nil,
1486
+ issuer: nil,
1487
+ metadata: nil,
1488
+ rendering_options: nil
1489
+ )
1490
+ @account_tax_ids = account_tax_ids
1491
+ @custom_fields = custom_fields
1492
+ @description = description
1493
+ @footer = footer
1494
+ @issuer = issuer
1495
+ @metadata = metadata
1496
+ @rendering_options = rendering_options
1497
+ end
1498
+ end
1499
+ # Set to `true` to enable invoice creation.
1500
+ attr_accessor :enabled
1501
+ # Parameters passed when creating invoices for payment-mode Checkout Sessions.
1502
+ attr_accessor :invoice_data
1503
+
1504
+ def initialize(enabled: nil, invoice_data: nil)
1505
+ @enabled = enabled
1506
+ @invoice_data = invoice_data
1507
+ end
1508
+ end
1509
+
1510
+ class LineItem < Stripe::RequestParams
1511
+ class AdjustableQuantity < Stripe::RequestParams
1512
+ # Set to true if the quantity can be adjusted to any non-negative integer.
1513
+ attr_accessor :enabled
1514
+ # The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
1515
+ attr_accessor :maximum
1516
+ # The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
1517
+ attr_accessor :minimum
1518
+
1519
+ def initialize(enabled: nil, maximum: nil, minimum: nil)
1520
+ @enabled = enabled
1521
+ @maximum = maximum
1522
+ @minimum = minimum
1523
+ end
1524
+ end
1525
+
1526
+ class PriceData < Stripe::RequestParams
1527
+ class ProductData < Stripe::RequestParams
1528
+ # The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
1529
+ attr_accessor :description
1530
+ # A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
1531
+ attr_accessor :images
1532
+ # 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`.
1533
+ attr_accessor :metadata
1534
+ # The product's name, meant to be displayable to the customer.
1535
+ attr_accessor :name
1536
+ # A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
1537
+ attr_accessor :tax_code
1538
+
1539
+ def initialize(description: nil, images: nil, metadata: nil, name: nil, tax_code: nil)
1540
+ @description = description
1541
+ @images = images
1542
+ @metadata = metadata
1543
+ @name = name
1544
+ @tax_code = tax_code
1545
+ end
1546
+ end
1547
+
1548
+ class Recurring < Stripe::RequestParams
1549
+ # Specifies billing frequency. Either `day`, `week`, `month` or `year`.
1550
+ attr_accessor :interval
1551
+ # The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
1552
+ attr_accessor :interval_count
1553
+
1554
+ def initialize(interval: nil, interval_count: nil)
1555
+ @interval = interval
1556
+ @interval_count = interval_count
1557
+ end
1558
+ end
1559
+ # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
1560
+ attr_accessor :currency
1561
+ # The ID of the product that this price will belong to. One of `product` or `product_data` is required.
1562
+ attr_accessor :product
1563
+ # Data used to generate a new product object inline. One of `product` or `product_data` is required.
1564
+ attr_accessor :product_data
1565
+ # The recurring components of a price such as `interval` and `interval_count`.
1566
+ attr_accessor :recurring
1567
+ # Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
1568
+ attr_accessor :tax_behavior
1569
+ # A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
1570
+ attr_accessor :unit_amount
1571
+ # Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
1572
+ attr_accessor :unit_amount_decimal
1573
+
1574
+ def initialize(
1575
+ currency: nil,
1576
+ product: nil,
1577
+ product_data: nil,
1578
+ recurring: nil,
1579
+ tax_behavior: nil,
1580
+ unit_amount: nil,
1581
+ unit_amount_decimal: nil
1582
+ )
1583
+ @currency = currency
1584
+ @product = product
1585
+ @product_data = product_data
1586
+ @recurring = recurring
1587
+ @tax_behavior = tax_behavior
1588
+ @unit_amount = unit_amount
1589
+ @unit_amount_decimal = unit_amount_decimal
1590
+ end
1591
+ end
1592
+ # When set, provides configuration for this item’s quantity to be adjusted by the customer during Checkout.
1593
+ attr_accessor :adjustable_quantity
1594
+ # The [tax rates](https://stripe.com/docs/api/tax_rates) that will be applied to this line item depending on the customer's billing/shipping address. We currently support the following countries: US, GB, AU, and all countries in the EU.
1595
+ attr_accessor :dynamic_tax_rates
1596
+ # 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`.
1597
+ attr_accessor :metadata
1598
+ # The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
1599
+ attr_accessor :price
1600
+ # Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
1601
+ attr_accessor :price_data
1602
+ # The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
1603
+ attr_accessor :quantity
1604
+ # The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
1605
+ attr_accessor :tax_rates
1606
+
1607
+ def initialize(
1608
+ adjustable_quantity: nil,
1609
+ dynamic_tax_rates: nil,
1610
+ metadata: nil,
1611
+ price: nil,
1612
+ price_data: nil,
1613
+ quantity: nil,
1614
+ tax_rates: nil
1615
+ )
1616
+ @adjustable_quantity = adjustable_quantity
1617
+ @dynamic_tax_rates = dynamic_tax_rates
1618
+ @metadata = metadata
1619
+ @price = price
1620
+ @price_data = price_data
1621
+ @quantity = quantity
1622
+ @tax_rates = tax_rates
1623
+ end
1624
+ end
1625
+
1626
+ class PaymentIntentData < Stripe::RequestParams
1627
+ class Shipping < Stripe::RequestParams
1628
+ class Address < Stripe::RequestParams
1629
+ # City, district, suburb, town, or village.
1630
+ attr_accessor :city
1631
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
1632
+ attr_accessor :country
1633
+ # Address line 1 (e.g., street, PO Box, or company name).
1634
+ attr_accessor :line1
1635
+ # Address line 2 (e.g., apartment, suite, unit, or building).
1636
+ attr_accessor :line2
1637
+ # ZIP or postal code.
1638
+ attr_accessor :postal_code
1639
+ # State, county, province, or region.
1640
+ attr_accessor :state
1641
+
1642
+ def initialize(
1643
+ city: nil,
1644
+ country: nil,
1645
+ line1: nil,
1646
+ line2: nil,
1647
+ postal_code: nil,
1648
+ state: nil
1649
+ )
1650
+ @city = city
1651
+ @country = country
1652
+ @line1 = line1
1653
+ @line2 = line2
1654
+ @postal_code = postal_code
1655
+ @state = state
1656
+ end
1657
+ end
1658
+ # Shipping address.
1659
+ attr_accessor :address
1660
+ # The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
1661
+ attr_accessor :carrier
1662
+ # Recipient name.
1663
+ attr_accessor :name
1664
+ # Recipient phone (including extension).
1665
+ attr_accessor :phone
1666
+ # The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
1667
+ attr_accessor :tracking_number
1668
+
1669
+ def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil)
1670
+ @address = address
1671
+ @carrier = carrier
1672
+ @name = name
1673
+ @phone = phone
1674
+ @tracking_number = tracking_number
1675
+ end
1676
+ end
1677
+
1678
+ class TransferData < Stripe::RequestParams
1679
+ # The amount that will be transferred automatically when a charge succeeds.
1680
+ attr_accessor :amount
1681
+ # If specified, successful charges will be attributed to the destination
1682
+ # account for tax reporting, and the funds from charges will be transferred
1683
+ # to the destination account. The ID of the resulting transfer will be
1684
+ # returned on the successful charge's `transfer` field.
1685
+ attr_accessor :destination
1686
+
1687
+ def initialize(amount: nil, destination: nil)
1688
+ @amount = amount
1689
+ @destination = destination
1690
+ end
1691
+ end
1692
+ # 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 payment amount. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
1693
+ attr_accessor :application_fee_amount
1694
+ # Controls when the funds will be captured from the customer's account.
1695
+ attr_accessor :capture_method
1696
+ # An arbitrary string attached to the object. Often useful for displaying to users.
1697
+ attr_accessor :description
1698
+ # 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`.
1699
+ attr_accessor :metadata
1700
+ # The Stripe account ID for which these funds are intended. For details,
1701
+ # see the PaymentIntents [use case for connected
1702
+ # accounts](/docs/payments/connected-accounts).
1703
+ attr_accessor :on_behalf_of
1704
+ # Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
1705
+ attr_accessor :receipt_email
1706
+ # Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment
1707
+ # method collected by this Checkout Session.
1708
+ #
1709
+ # When setting this to `on_session`, Checkout will show a notice to the
1710
+ # customer that their payment details will be saved.
1711
+ #
1712
+ # When setting this to `off_session`, Checkout will show a notice to the
1713
+ # customer that their payment details will be saved and used for future
1714
+ # payments.
1715
+ #
1716
+ # If a Customer has been provided or Checkout creates a new Customer,
1717
+ # Checkout will attach the payment method to the Customer.
1718
+ #
1719
+ # If Checkout does not create a Customer, the payment method is not attached
1720
+ # to a Customer. To reuse the payment method, you can retrieve it from the
1721
+ # Checkout Session's PaymentIntent.
1722
+ #
1723
+ # When processing card payments, Checkout also uses `setup_future_usage`
1724
+ # to dynamically optimize your payment flow and comply with regional
1725
+ # legislation and network rules, such as SCA.
1726
+ attr_accessor :setup_future_usage
1727
+ # Shipping information for this payment.
1728
+ attr_accessor :shipping
1729
+ # Text that appears on the customer's statement as the statement descriptor for a non-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).
1730
+ #
1731
+ # Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
1732
+ attr_accessor :statement_descriptor
1733
+ # Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
1734
+ attr_accessor :statement_descriptor_suffix
1735
+ # The parameters used to automatically create a Transfer when the payment succeeds.
1736
+ # For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
1737
+ attr_accessor :transfer_data
1738
+ # A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
1739
+ attr_accessor :transfer_group
1740
+
1741
+ def initialize(
1742
+ application_fee_amount: nil,
1743
+ capture_method: nil,
1744
+ description: nil,
1745
+ metadata: nil,
1746
+ on_behalf_of: nil,
1747
+ receipt_email: nil,
1748
+ setup_future_usage: nil,
1749
+ shipping: nil,
1750
+ statement_descriptor: nil,
1751
+ statement_descriptor_suffix: nil,
1752
+ transfer_data: nil,
1753
+ transfer_group: nil
1754
+ )
1755
+ @application_fee_amount = application_fee_amount
1756
+ @capture_method = capture_method
1757
+ @description = description
1758
+ @metadata = metadata
1759
+ @on_behalf_of = on_behalf_of
1760
+ @receipt_email = receipt_email
1761
+ @setup_future_usage = setup_future_usage
1762
+ @shipping = shipping
1763
+ @statement_descriptor = statement_descriptor
1764
+ @statement_descriptor_suffix = statement_descriptor_suffix
1765
+ @transfer_data = transfer_data
1766
+ @transfer_group = transfer_group
1767
+ end
1768
+ end
1769
+
1770
+ class PaymentMethodData < Stripe::RequestParams
1771
+ # Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.
1772
+ attr_accessor :allow_redisplay
1773
+
1774
+ def initialize(allow_redisplay: nil)
1775
+ @allow_redisplay = allow_redisplay
1776
+ end
1777
+ end
1778
+
1779
+ class PaymentMethodOptions < Stripe::RequestParams
1780
+ class AcssDebit < Stripe::RequestParams
1781
+ class MandateOptions < Stripe::RequestParams
1782
+ # A URL for custom mandate text to render during confirmation step.
1783
+ # The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
1784
+ # or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
1785
+ attr_accessor :custom_mandate_url
1786
+ # List of Stripe products where this mandate can be selected automatically. Only usable in `setup` mode.
1787
+ attr_accessor :default_for
1788
+ # Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
1789
+ attr_accessor :interval_description
1790
+ # Payment schedule for the mandate.
1791
+ attr_accessor :payment_schedule
1792
+ # Transaction type of the mandate.
1793
+ attr_accessor :transaction_type
1794
+
1795
+ def initialize(
1796
+ custom_mandate_url: nil,
1797
+ default_for: nil,
1798
+ interval_description: nil,
1799
+ payment_schedule: nil,
1800
+ transaction_type: nil
1801
+ )
1802
+ @custom_mandate_url = custom_mandate_url
1803
+ @default_for = default_for
1804
+ @interval_description = interval_description
1805
+ @payment_schedule = payment_schedule
1806
+ @transaction_type = transaction_type
1807
+ end
1808
+ end
1809
+ # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). This is only accepted for Checkout Sessions in `setup` mode.
1810
+ attr_accessor :currency
1811
+ # Additional fields for Mandate creation
1812
+ attr_accessor :mandate_options
1813
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1814
+ #
1815
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1816
+ #
1817
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1818
+ #
1819
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1820
+ attr_accessor :setup_future_usage
1821
+ # Verification method for the intent
1822
+ attr_accessor :verification_method
1823
+
1824
+ def initialize(
1825
+ currency: nil,
1826
+ mandate_options: nil,
1827
+ setup_future_usage: nil,
1828
+ verification_method: nil
1829
+ )
1830
+ @currency = currency
1831
+ @mandate_options = mandate_options
1832
+ @setup_future_usage = setup_future_usage
1833
+ @verification_method = verification_method
1834
+ end
1835
+ end
1836
+
1837
+ class Affirm < Stripe::RequestParams
1838
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1839
+ #
1840
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1841
+ #
1842
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1843
+ #
1844
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1845
+ attr_accessor :setup_future_usage
1846
+
1847
+ def initialize(setup_future_usage: nil)
1848
+ @setup_future_usage = setup_future_usage
1849
+ end
1850
+ end
1851
+
1852
+ class AfterpayClearpay < Stripe::RequestParams
1853
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1854
+ #
1855
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1856
+ #
1857
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1858
+ #
1859
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1860
+ attr_accessor :setup_future_usage
1861
+
1862
+ def initialize(setup_future_usage: nil)
1863
+ @setup_future_usage = setup_future_usage
1864
+ end
1865
+ end
1866
+
1867
+ class Alipay < Stripe::RequestParams
1868
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1869
+ #
1870
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1871
+ #
1872
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1873
+ #
1874
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1875
+ attr_accessor :setup_future_usage
1876
+
1877
+ def initialize(setup_future_usage: nil)
1878
+ @setup_future_usage = setup_future_usage
1879
+ end
1880
+ end
1881
+
1882
+ class AmazonPay < Stripe::RequestParams
1883
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1884
+ #
1885
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1886
+ #
1887
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1888
+ #
1889
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1890
+ attr_accessor :setup_future_usage
1891
+
1892
+ def initialize(setup_future_usage: nil)
1893
+ @setup_future_usage = setup_future_usage
1894
+ end
1895
+ end
1896
+
1897
+ class AuBecsDebit < Stripe::RequestParams
1898
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1899
+ #
1900
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1901
+ #
1902
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1903
+ #
1904
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1905
+ attr_accessor :setup_future_usage
1906
+
1907
+ def initialize(setup_future_usage: nil)
1908
+ @setup_future_usage = setup_future_usage
1909
+ end
1910
+ end
1911
+
1912
+ class BacsDebit < Stripe::RequestParams
1913
+ class MandateOptions < Stripe::RequestParams
1914
+ # Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
1915
+ attr_accessor :reference_prefix
1916
+
1917
+ def initialize(reference_prefix: nil)
1918
+ @reference_prefix = reference_prefix
1919
+ end
1920
+ end
1921
+ # Additional fields for Mandate creation
1922
+ attr_accessor :mandate_options
1923
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1924
+ #
1925
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1926
+ #
1927
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1928
+ #
1929
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1930
+ attr_accessor :setup_future_usage
1931
+
1932
+ def initialize(mandate_options: nil, setup_future_usage: nil)
1933
+ @mandate_options = mandate_options
1934
+ @setup_future_usage = setup_future_usage
1935
+ end
1936
+ end
1937
+
1938
+ class Bancontact < Stripe::RequestParams
1939
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1940
+ #
1941
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1942
+ #
1943
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1944
+ #
1945
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1946
+ attr_accessor :setup_future_usage
1947
+
1948
+ def initialize(setup_future_usage: nil)
1949
+ @setup_future_usage = setup_future_usage
1950
+ end
1951
+ end
1952
+
1953
+ class Boleto < Stripe::RequestParams
1954
+ # The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
1955
+ attr_accessor :expires_after_days
1956
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
1957
+ #
1958
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
1959
+ #
1960
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
1961
+ #
1962
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
1963
+ attr_accessor :setup_future_usage
1964
+
1965
+ def initialize(expires_after_days: nil, setup_future_usage: nil)
1966
+ @expires_after_days = expires_after_days
1967
+ @setup_future_usage = setup_future_usage
1968
+ end
1969
+ end
1970
+
1971
+ class Card < Stripe::RequestParams
1972
+ class Installments < Stripe::RequestParams
1973
+ # Setting to true enables installments for this Checkout Session.
1974
+ # Setting to false will prevent any installment plan from applying to a payment.
1975
+ attr_accessor :enabled
1976
+
1977
+ def initialize(enabled: nil)
1978
+ @enabled = enabled
1979
+ end
1980
+ end
1981
+
1982
+ class Restrictions < Stripe::RequestParams
1983
+ # Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
1984
+ attr_accessor :brands_blocked
1985
+
1986
+ def initialize(brands_blocked: nil)
1987
+ @brands_blocked = brands_blocked
1988
+ end
1989
+ end
1990
+ # Installment options for card payments
1991
+ attr_accessor :installments
1992
+ # Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
1993
+ attr_accessor :request_decremental_authorization
1994
+ # Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
1995
+ attr_accessor :request_extended_authorization
1996
+ # Request ability to [increment the authorization](/payments/incremental-authorization) for this CheckoutSession.
1997
+ attr_accessor :request_incremental_authorization
1998
+ # Request ability to make [multiple captures](/payments/multicapture) for this CheckoutSession.
1999
+ attr_accessor :request_multicapture
2000
+ # Request ability to [overcapture](/payments/overcapture) for this CheckoutSession.
2001
+ attr_accessor :request_overcapture
2002
+ # We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
2003
+ attr_accessor :request_three_d_secure
2004
+ # Restrictions to apply to the card payment method. For example, you can block specific card brands.
2005
+ attr_accessor :restrictions
2006
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2007
+ #
2008
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2009
+ #
2010
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2011
+ #
2012
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2013
+ attr_accessor :setup_future_usage
2014
+ # Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
2015
+ attr_accessor :statement_descriptor_suffix_kana
2016
+ # Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
2017
+ attr_accessor :statement_descriptor_suffix_kanji
2018
+
2019
+ def initialize(
2020
+ installments: nil,
2021
+ request_decremental_authorization: nil,
2022
+ request_extended_authorization: nil,
2023
+ request_incremental_authorization: nil,
2024
+ request_multicapture: nil,
2025
+ request_overcapture: nil,
2026
+ request_three_d_secure: nil,
2027
+ restrictions: nil,
2028
+ setup_future_usage: nil,
2029
+ statement_descriptor_suffix_kana: nil,
2030
+ statement_descriptor_suffix_kanji: nil
2031
+ )
2032
+ @installments = installments
2033
+ @request_decremental_authorization = request_decremental_authorization
2034
+ @request_extended_authorization = request_extended_authorization
2035
+ @request_incremental_authorization = request_incremental_authorization
2036
+ @request_multicapture = request_multicapture
2037
+ @request_overcapture = request_overcapture
2038
+ @request_three_d_secure = request_three_d_secure
2039
+ @restrictions = restrictions
2040
+ @setup_future_usage = setup_future_usage
2041
+ @statement_descriptor_suffix_kana = statement_descriptor_suffix_kana
2042
+ @statement_descriptor_suffix_kanji = statement_descriptor_suffix_kanji
2043
+ end
2044
+ end
2045
+
2046
+ class Cashapp < Stripe::RequestParams
2047
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2048
+ #
2049
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2050
+ #
2051
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2052
+ #
2053
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2054
+ attr_accessor :setup_future_usage
2055
+
2056
+ def initialize(setup_future_usage: nil)
2057
+ @setup_future_usage = setup_future_usage
2058
+ end
2059
+ end
2060
+
2061
+ class CustomerBalance < Stripe::RequestParams
2062
+ class BankTransfer < Stripe::RequestParams
2063
+ class EuBankTransfer < Stripe::RequestParams
2064
+ # The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
2065
+ attr_accessor :country
2066
+
2067
+ def initialize(country: nil)
2068
+ @country = country
2069
+ end
2070
+ end
2071
+ # Configuration for eu_bank_transfer funding type.
2072
+ attr_accessor :eu_bank_transfer
2073
+ # List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
2074
+ #
2075
+ # Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
2076
+ attr_accessor :requested_address_types
2077
+ # The list of bank transfer types that this PaymentIntent is allowed to use for funding.
2078
+ attr_accessor :type
2079
+
2080
+ def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil)
2081
+ @eu_bank_transfer = eu_bank_transfer
2082
+ @requested_address_types = requested_address_types
2083
+ @type = type
2084
+ end
2085
+ end
2086
+ # Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
2087
+ attr_accessor :bank_transfer
2088
+ # The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
2089
+ attr_accessor :funding_type
2090
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2091
+ #
2092
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2093
+ #
2094
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2095
+ #
2096
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2097
+ attr_accessor :setup_future_usage
2098
+
2099
+ def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil)
2100
+ @bank_transfer = bank_transfer
2101
+ @funding_type = funding_type
2102
+ @setup_future_usage = setup_future_usage
2103
+ end
2104
+ end
2105
+
2106
+ class Eps < Stripe::RequestParams
2107
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2108
+ #
2109
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2110
+ #
2111
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2112
+ #
2113
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2114
+ attr_accessor :setup_future_usage
2115
+
2116
+ def initialize(setup_future_usage: nil)
2117
+ @setup_future_usage = setup_future_usage
2118
+ end
2119
+ end
2120
+
2121
+ class Fpx < Stripe::RequestParams
2122
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2123
+ #
2124
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2125
+ #
2126
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2127
+ #
2128
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2129
+ attr_accessor :setup_future_usage
2130
+
2131
+ def initialize(setup_future_usage: nil)
2132
+ @setup_future_usage = setup_future_usage
2133
+ end
2134
+ end
2135
+
2136
+ class Giropay < Stripe::RequestParams
2137
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2138
+ #
2139
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2140
+ #
2141
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2142
+ #
2143
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2144
+ attr_accessor :setup_future_usage
2145
+
2146
+ def initialize(setup_future_usage: nil)
2147
+ @setup_future_usage = setup_future_usage
2148
+ end
2149
+ end
2150
+
2151
+ class Grabpay < Stripe::RequestParams
2152
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2153
+ #
2154
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2155
+ #
2156
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2157
+ #
2158
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2159
+ attr_accessor :setup_future_usage
2160
+
2161
+ def initialize(setup_future_usage: nil)
2162
+ @setup_future_usage = setup_future_usage
2163
+ end
2164
+ end
2165
+
2166
+ class Ideal < Stripe::RequestParams
2167
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2168
+ #
2169
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2170
+ #
2171
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2172
+ #
2173
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2174
+ attr_accessor :setup_future_usage
2175
+
2176
+ def initialize(setup_future_usage: nil)
2177
+ @setup_future_usage = setup_future_usage
2178
+ end
2179
+ end
2180
+
2181
+ class KakaoPay < Stripe::RequestParams
2182
+ # Controls when the funds will be captured from the customer's account.
2183
+ attr_accessor :capture_method
2184
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2185
+ #
2186
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2187
+ #
2188
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2189
+ #
2190
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2191
+ attr_accessor :setup_future_usage
2192
+
2193
+ def initialize(capture_method: nil, setup_future_usage: nil)
2194
+ @capture_method = capture_method
2195
+ @setup_future_usage = setup_future_usage
2196
+ end
2197
+ end
2198
+
2199
+ class Klarna < Stripe::RequestParams
2200
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2201
+ #
2202
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2203
+ #
2204
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2205
+ #
2206
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2207
+ attr_accessor :setup_future_usage
2208
+
2209
+ def initialize(setup_future_usage: nil)
2210
+ @setup_future_usage = setup_future_usage
2211
+ end
2212
+ end
2213
+
2214
+ class Konbini < Stripe::RequestParams
2215
+ # The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
2216
+ attr_accessor :expires_after_days
2217
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2218
+ #
2219
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2220
+ #
2221
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2222
+ #
2223
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2224
+ attr_accessor :setup_future_usage
2225
+
2226
+ def initialize(expires_after_days: nil, setup_future_usage: nil)
2227
+ @expires_after_days = expires_after_days
2228
+ @setup_future_usage = setup_future_usage
2229
+ end
2230
+ end
2231
+
2232
+ class KrCard < Stripe::RequestParams
2233
+ # Controls when the funds will be captured from the customer's account.
2234
+ attr_accessor :capture_method
2235
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2236
+ #
2237
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2238
+ #
2239
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2240
+ #
2241
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2242
+ attr_accessor :setup_future_usage
2243
+
2244
+ def initialize(capture_method: nil, setup_future_usage: nil)
2245
+ @capture_method = capture_method
2246
+ @setup_future_usage = setup_future_usage
2247
+ end
2248
+ end
2249
+
2250
+ class Link < Stripe::RequestParams
2251
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2252
+ #
2253
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2254
+ #
2255
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2256
+ #
2257
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2258
+ attr_accessor :setup_future_usage
2259
+
2260
+ def initialize(setup_future_usage: nil)
2261
+ @setup_future_usage = setup_future_usage
2262
+ end
2263
+ end
2264
+
2265
+ class Mobilepay < Stripe::RequestParams
2266
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2267
+ #
2268
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2269
+ #
2270
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2271
+ #
2272
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2273
+ attr_accessor :setup_future_usage
2274
+
2275
+ def initialize(setup_future_usage: nil)
2276
+ @setup_future_usage = setup_future_usage
2277
+ end
2278
+ end
2279
+
2280
+ class Multibanco < Stripe::RequestParams
2281
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2282
+ #
2283
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2284
+ #
2285
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2286
+ #
2287
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2288
+ attr_accessor :setup_future_usage
2289
+
2290
+ def initialize(setup_future_usage: nil)
2291
+ @setup_future_usage = setup_future_usage
2292
+ end
2293
+ end
2294
+
2295
+ class NaverPay < Stripe::RequestParams
2296
+ # Controls when the funds will be captured from the customer's account.
2297
+ attr_accessor :capture_method
2298
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2299
+ #
2300
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2301
+ #
2302
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2303
+ #
2304
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2305
+ attr_accessor :setup_future_usage
2306
+
2307
+ def initialize(capture_method: nil, setup_future_usage: nil)
2308
+ @capture_method = capture_method
2309
+ @setup_future_usage = setup_future_usage
2310
+ end
2311
+ end
2312
+
2313
+ class Oxxo < Stripe::RequestParams
2314
+ # The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
2315
+ attr_accessor :expires_after_days
2316
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2317
+ #
2318
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2319
+ #
2320
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2321
+ #
2322
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2323
+ attr_accessor :setup_future_usage
2324
+
2325
+ def initialize(expires_after_days: nil, setup_future_usage: nil)
2326
+ @expires_after_days = expires_after_days
2327
+ @setup_future_usage = setup_future_usage
2328
+ end
2329
+ end
2330
+
2331
+ class P24 < Stripe::RequestParams
2332
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2333
+ #
2334
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2335
+ #
2336
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2337
+ #
2338
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2339
+ attr_accessor :setup_future_usage
2340
+ # Confirm that the payer has accepted the P24 terms and conditions.
2341
+ attr_accessor :tos_shown_and_accepted
2342
+
2343
+ def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil)
2344
+ @setup_future_usage = setup_future_usage
2345
+ @tos_shown_and_accepted = tos_shown_and_accepted
2346
+ end
2347
+ end
2348
+
2349
+ class PayByBank < Stripe::RequestParams
2350
+ end
2351
+
2352
+ class Payco < Stripe::RequestParams
2353
+ # Controls when the funds will be captured from the customer's account.
2354
+ attr_accessor :capture_method
2355
+
2356
+ def initialize(capture_method: nil)
2357
+ @capture_method = capture_method
2358
+ end
2359
+ end
2360
+
2361
+ class Paynow < Stripe::RequestParams
2362
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2363
+ #
2364
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2365
+ #
2366
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2367
+ #
2368
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2369
+ attr_accessor :setup_future_usage
2370
+
2371
+ def initialize(setup_future_usage: nil)
2372
+ @setup_future_usage = setup_future_usage
2373
+ end
2374
+ end
2375
+
2376
+ class Paypal < Stripe::RequestParams
2377
+ # Controls when the funds will be captured from the customer's account.
2378
+ attr_accessor :capture_method
2379
+ # [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
2380
+ attr_accessor :preferred_locale
2381
+ # A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
2382
+ attr_accessor :reference
2383
+ # A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
2384
+ attr_accessor :reference_id
2385
+ # The risk correlation ID for an on-session payment using a saved PayPal payment method.
2386
+ attr_accessor :risk_correlation_id
2387
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2388
+ #
2389
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2390
+ #
2391
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2392
+ #
2393
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2394
+ #
2395
+ # If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
2396
+ attr_accessor :setup_future_usage
2397
+ # The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
2398
+ attr_accessor :subsellers
2399
+
2400
+ def initialize(
2401
+ capture_method: nil,
2402
+ preferred_locale: nil,
2403
+ reference: nil,
2404
+ reference_id: nil,
2405
+ risk_correlation_id: nil,
2406
+ setup_future_usage: nil,
2407
+ subsellers: nil
2408
+ )
2409
+ @capture_method = capture_method
2410
+ @preferred_locale = preferred_locale
2411
+ @reference = reference
2412
+ @reference_id = reference_id
2413
+ @risk_correlation_id = risk_correlation_id
2414
+ @setup_future_usage = setup_future_usage
2415
+ @subsellers = subsellers
2416
+ end
2417
+ end
2418
+
2419
+ class Payto < Stripe::RequestParams
2420
+ class MandateOptions < Stripe::RequestParams
2421
+ # Amount that will be collected. It is required when `amount_type` is `fixed`.
2422
+ attr_accessor :amount
2423
+ # The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
2424
+ attr_accessor :amount_type
2425
+ # Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
2426
+ attr_accessor :end_date
2427
+ # The periodicity at which payments will be collected.
2428
+ attr_accessor :payment_schedule
2429
+ # The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
2430
+ attr_accessor :payments_per_period
2431
+ # The purpose for which payments are made. Defaults to retail.
2432
+ attr_accessor :purpose
2433
+ # Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
2434
+ attr_accessor :start_date
2435
+
2436
+ def initialize(
2437
+ amount: nil,
2438
+ amount_type: nil,
2439
+ end_date: nil,
2440
+ payment_schedule: nil,
2441
+ payments_per_period: nil,
2442
+ purpose: nil,
2443
+ start_date: nil
2444
+ )
2445
+ @amount = amount
2446
+ @amount_type = amount_type
2447
+ @end_date = end_date
2448
+ @payment_schedule = payment_schedule
2449
+ @payments_per_period = payments_per_period
2450
+ @purpose = purpose
2451
+ @start_date = start_date
2452
+ end
2453
+ end
2454
+ # Additional fields for Mandate creation
2455
+ attr_accessor :mandate_options
2456
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2457
+ #
2458
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2459
+ #
2460
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2461
+ #
2462
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2463
+ attr_accessor :setup_future_usage
2464
+
2465
+ def initialize(mandate_options: nil, setup_future_usage: nil)
2466
+ @mandate_options = mandate_options
2467
+ @setup_future_usage = setup_future_usage
2468
+ end
2469
+ end
2470
+
2471
+ class Pix < Stripe::RequestParams
2472
+ # The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
2473
+ attr_accessor :expires_after_seconds
2474
+
2475
+ def initialize(expires_after_seconds: nil)
2476
+ @expires_after_seconds = expires_after_seconds
2477
+ end
2478
+ end
2479
+
2480
+ class RevolutPay < Stripe::RequestParams
2481
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2482
+ #
2483
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2484
+ #
2485
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2486
+ #
2487
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2488
+ attr_accessor :setup_future_usage
2489
+
2490
+ def initialize(setup_future_usage: nil)
2491
+ @setup_future_usage = setup_future_usage
2492
+ end
2493
+ end
2494
+
2495
+ class SamsungPay < Stripe::RequestParams
2496
+ # Controls when the funds will be captured from the customer's account.
2497
+ attr_accessor :capture_method
2498
+
2499
+ def initialize(capture_method: nil)
2500
+ @capture_method = capture_method
2501
+ end
2502
+ end
2503
+
2504
+ class SepaDebit < Stripe::RequestParams
2505
+ class MandateOptions < Stripe::RequestParams
2506
+ # Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
2507
+ attr_accessor :reference_prefix
2508
+
2509
+ def initialize(reference_prefix: nil)
2510
+ @reference_prefix = reference_prefix
2511
+ end
2512
+ end
2513
+ # Additional fields for Mandate creation
2514
+ attr_accessor :mandate_options
2515
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2516
+ #
2517
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2518
+ #
2519
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2520
+ #
2521
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2522
+ attr_accessor :setup_future_usage
2523
+
2524
+ def initialize(mandate_options: nil, setup_future_usage: nil)
2525
+ @mandate_options = mandate_options
2526
+ @setup_future_usage = setup_future_usage
2527
+ end
2528
+ end
2529
+
2530
+ class Sofort < Stripe::RequestParams
2531
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2532
+ #
2533
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2534
+ #
2535
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2536
+ #
2537
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2538
+ attr_accessor :setup_future_usage
2539
+
2540
+ def initialize(setup_future_usage: nil)
2541
+ @setup_future_usage = setup_future_usage
2542
+ end
2543
+ end
2544
+
2545
+ class Swish < Stripe::RequestParams
2546
+ # The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
2547
+ attr_accessor :reference
2548
+
2549
+ def initialize(reference: nil)
2550
+ @reference = reference
2551
+ end
2552
+ end
2553
+
2554
+ class UsBankAccount < Stripe::RequestParams
2555
+ class FinancialConnections < Stripe::RequestParams
2556
+ # The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
2557
+ attr_accessor :permissions
2558
+ # List of data features that you would like to retrieve upon account creation.
2559
+ attr_accessor :prefetch
2560
+
2561
+ def initialize(permissions: nil, prefetch: nil)
2562
+ @permissions = permissions
2563
+ @prefetch = prefetch
2564
+ end
2565
+ end
2566
+ # Additional fields for Financial Connections Session creation
2567
+ attr_accessor :financial_connections
2568
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2569
+ #
2570
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2571
+ #
2572
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2573
+ #
2574
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2575
+ attr_accessor :setup_future_usage
2576
+ # Verification method for the intent
2577
+ attr_accessor :verification_method
2578
+
2579
+ def initialize(
2580
+ financial_connections: nil,
2581
+ setup_future_usage: nil,
2582
+ verification_method: nil
2583
+ )
2584
+ @financial_connections = financial_connections
2585
+ @setup_future_usage = setup_future_usage
2586
+ @verification_method = verification_method
2587
+ end
2588
+ end
2589
+
2590
+ class WechatPay < Stripe::RequestParams
2591
+ # The app ID registered with WeChat Pay. Only required when client is ios or android.
2592
+ attr_accessor :app_id
2593
+ # The client type that the end customer will pay from
2594
+ attr_accessor :client
2595
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
2596
+ #
2597
+ # If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
2598
+ #
2599
+ # If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
2600
+ #
2601
+ # When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
2602
+ attr_accessor :setup_future_usage
2603
+
2604
+ def initialize(app_id: nil, client: nil, setup_future_usage: nil)
2605
+ @app_id = app_id
2606
+ @client = client
2607
+ @setup_future_usage = setup_future_usage
2608
+ end
2609
+ end
2610
+ # contains details about the ACSS Debit payment method options.
2611
+ attr_accessor :acss_debit
2612
+ # contains details about the Affirm payment method options.
2613
+ attr_accessor :affirm
2614
+ # contains details about the Afterpay Clearpay payment method options.
2615
+ attr_accessor :afterpay_clearpay
2616
+ # contains details about the Alipay payment method options.
2617
+ attr_accessor :alipay
2618
+ # contains details about the AmazonPay payment method options.
2619
+ attr_accessor :amazon_pay
2620
+ # contains details about the AU Becs Debit payment method options.
2621
+ attr_accessor :au_becs_debit
2622
+ # contains details about the Bacs Debit payment method options.
2623
+ attr_accessor :bacs_debit
2624
+ # contains details about the Bancontact payment method options.
2625
+ attr_accessor :bancontact
2626
+ # contains details about the Boleto payment method options.
2627
+ attr_accessor :boleto
2628
+ # contains details about the Card payment method options.
2629
+ attr_accessor :card
2630
+ # contains details about the Cashapp Pay payment method options.
2631
+ attr_accessor :cashapp
2632
+ # contains details about the Customer Balance payment method options.
2633
+ attr_accessor :customer_balance
2634
+ # contains details about the EPS payment method options.
2635
+ attr_accessor :eps
2636
+ # contains details about the FPX payment method options.
2637
+ attr_accessor :fpx
2638
+ # contains details about the Giropay payment method options.
2639
+ attr_accessor :giropay
2640
+ # contains details about the Grabpay payment method options.
2641
+ attr_accessor :grabpay
2642
+ # contains details about the Ideal payment method options.
2643
+ attr_accessor :ideal
2644
+ # contains details about the Kakao Pay payment method options.
2645
+ attr_accessor :kakao_pay
2646
+ # contains details about the Klarna payment method options.
2647
+ attr_accessor :klarna
2648
+ # contains details about the Konbini payment method options.
2649
+ attr_accessor :konbini
2650
+ # contains details about the Korean card payment method options.
2651
+ attr_accessor :kr_card
2652
+ # contains details about the Link payment method options.
2653
+ attr_accessor :link
2654
+ # contains details about the Mobilepay payment method options.
2655
+ attr_accessor :mobilepay
2656
+ # contains details about the Multibanco payment method options.
2657
+ attr_accessor :multibanco
2658
+ # contains details about the Naver Pay payment method options.
2659
+ attr_accessor :naver_pay
2660
+ # contains details about the OXXO payment method options.
2661
+ attr_accessor :oxxo
2662
+ # contains details about the P24 payment method options.
2663
+ attr_accessor :p24
2664
+ # contains details about the Pay By Bank payment method options.
2665
+ attr_accessor :pay_by_bank
2666
+ # contains details about the PAYCO payment method options.
2667
+ attr_accessor :payco
2668
+ # contains details about the PayNow payment method options.
2669
+ attr_accessor :paynow
2670
+ # contains details about the PayPal payment method options.
2671
+ attr_accessor :paypal
2672
+ # contains details about the PayTo payment method options.
2673
+ attr_accessor :payto
2674
+ # contains details about the Pix payment method options.
2675
+ attr_accessor :pix
2676
+ # contains details about the RevolutPay payment method options.
2677
+ attr_accessor :revolut_pay
2678
+ # contains details about the Samsung Pay payment method options.
2679
+ attr_accessor :samsung_pay
2680
+ # contains details about the Sepa Debit payment method options.
2681
+ attr_accessor :sepa_debit
2682
+ # contains details about the Sofort payment method options.
2683
+ attr_accessor :sofort
2684
+ # contains details about the Swish payment method options.
2685
+ attr_accessor :swish
2686
+ # contains details about the Us Bank Account payment method options.
2687
+ attr_accessor :us_bank_account
2688
+ # contains details about the WeChat Pay payment method options.
2689
+ attr_accessor :wechat_pay
2690
+
2691
+ def initialize(
2692
+ acss_debit: nil,
2693
+ affirm: nil,
2694
+ afterpay_clearpay: nil,
2695
+ alipay: nil,
2696
+ amazon_pay: nil,
2697
+ au_becs_debit: nil,
2698
+ bacs_debit: nil,
2699
+ bancontact: nil,
2700
+ boleto: nil,
2701
+ card: nil,
2702
+ cashapp: nil,
2703
+ customer_balance: nil,
2704
+ eps: nil,
2705
+ fpx: nil,
2706
+ giropay: nil,
2707
+ grabpay: nil,
2708
+ ideal: nil,
2709
+ kakao_pay: nil,
2710
+ klarna: nil,
2711
+ konbini: nil,
2712
+ kr_card: nil,
2713
+ link: nil,
2714
+ mobilepay: nil,
2715
+ multibanco: nil,
2716
+ naver_pay: nil,
2717
+ oxxo: nil,
2718
+ p24: nil,
2719
+ pay_by_bank: nil,
2720
+ payco: nil,
2721
+ paynow: nil,
2722
+ paypal: nil,
2723
+ payto: nil,
2724
+ pix: nil,
2725
+ revolut_pay: nil,
2726
+ samsung_pay: nil,
2727
+ sepa_debit: nil,
2728
+ sofort: nil,
2729
+ swish: nil,
2730
+ us_bank_account: nil,
2731
+ wechat_pay: nil
2732
+ )
2733
+ @acss_debit = acss_debit
2734
+ @affirm = affirm
2735
+ @afterpay_clearpay = afterpay_clearpay
2736
+ @alipay = alipay
2737
+ @amazon_pay = amazon_pay
2738
+ @au_becs_debit = au_becs_debit
2739
+ @bacs_debit = bacs_debit
2740
+ @bancontact = bancontact
2741
+ @boleto = boleto
2742
+ @card = card
2743
+ @cashapp = cashapp
2744
+ @customer_balance = customer_balance
2745
+ @eps = eps
2746
+ @fpx = fpx
2747
+ @giropay = giropay
2748
+ @grabpay = grabpay
2749
+ @ideal = ideal
2750
+ @kakao_pay = kakao_pay
2751
+ @klarna = klarna
2752
+ @konbini = konbini
2753
+ @kr_card = kr_card
2754
+ @link = link
2755
+ @mobilepay = mobilepay
2756
+ @multibanco = multibanco
2757
+ @naver_pay = naver_pay
2758
+ @oxxo = oxxo
2759
+ @p24 = p24
2760
+ @pay_by_bank = pay_by_bank
2761
+ @payco = payco
2762
+ @paynow = paynow
2763
+ @paypal = paypal
2764
+ @payto = payto
2765
+ @pix = pix
2766
+ @revolut_pay = revolut_pay
2767
+ @samsung_pay = samsung_pay
2768
+ @sepa_debit = sepa_debit
2769
+ @sofort = sofort
2770
+ @swish = swish
2771
+ @us_bank_account = us_bank_account
2772
+ @wechat_pay = wechat_pay
2773
+ end
2774
+ end
2775
+
2776
+ class Permissions < Stripe::RequestParams
2777
+ class Update < Stripe::RequestParams
2778
+ # Determines which entity is allowed to update the line items.
2779
+ #
2780
+ # Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
2781
+ #
2782
+ # When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
2783
+ attr_accessor :line_items
2784
+ # Determines which entity is allowed to update the shipping details.
2785
+ #
2786
+ # Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
2787
+ #
2788
+ # When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
2789
+ attr_accessor :shipping_details
2790
+
2791
+ def initialize(line_items: nil, shipping_details: nil)
2792
+ @line_items = line_items
2793
+ @shipping_details = shipping_details
2794
+ end
2795
+ end
2796
+ # Permissions for updating the Checkout Session.
2797
+ attr_accessor :update
2798
+
2799
+ def initialize(update: nil)
2800
+ @update = update
2801
+ end
2802
+ end
2803
+
2804
+ class PhoneNumberCollection < Stripe::RequestParams
2805
+ # Set to `true` to enable phone number collection.
2806
+ #
2807
+ # Can only be set in `payment` and `subscription` mode.
2808
+ attr_accessor :enabled
2809
+
2810
+ def initialize(enabled: nil)
2811
+ @enabled = enabled
2812
+ end
2813
+ end
2814
+
2815
+ class SavedPaymentMethodOptions < Stripe::RequestParams
2816
+ # Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with ’allow_redisplay: ‘always’ are shown in Checkout.
2817
+ attr_accessor :allow_redisplay_filters
2818
+ # Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
2819
+ attr_accessor :payment_method_save
2820
+
2821
+ def initialize(allow_redisplay_filters: nil, payment_method_save: nil)
2822
+ @allow_redisplay_filters = allow_redisplay_filters
2823
+ @payment_method_save = payment_method_save
2824
+ end
2825
+ end
2826
+
2827
+ class SetupIntentData < Stripe::RequestParams
2828
+ # An arbitrary string attached to the object. Often useful for displaying to users.
2829
+ attr_accessor :description
2830
+ # 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`.
2831
+ attr_accessor :metadata
2832
+ # The Stripe account for which the setup is intended.
2833
+ attr_accessor :on_behalf_of
2834
+
2835
+ def initialize(description: nil, metadata: nil, on_behalf_of: nil)
2836
+ @description = description
2837
+ @metadata = metadata
2838
+ @on_behalf_of = on_behalf_of
2839
+ end
2840
+ end
2841
+
2842
+ class ShippingAddressCollection < Stripe::RequestParams
2843
+ # An array of two-letter ISO country codes representing which countries Checkout should provide as options for
2844
+ # shipping locations.
2845
+ attr_accessor :allowed_countries
2846
+
2847
+ def initialize(allowed_countries: nil)
2848
+ @allowed_countries = allowed_countries
2849
+ end
2850
+ end
2851
+
2852
+ class ShippingOption < Stripe::RequestParams
2853
+ class ShippingRateData < Stripe::RequestParams
2854
+ class DeliveryEstimate < Stripe::RequestParams
2855
+ class Maximum < Stripe::RequestParams
2856
+ # A unit of time.
2857
+ attr_accessor :unit
2858
+ # Must be greater than 0.
2859
+ attr_accessor :value
2860
+
2861
+ def initialize(unit: nil, value: nil)
2862
+ @unit = unit
2863
+ @value = value
2864
+ end
2865
+ end
2866
+
2867
+ class Minimum < Stripe::RequestParams
2868
+ # A unit of time.
2869
+ attr_accessor :unit
2870
+ # Must be greater than 0.
2871
+ attr_accessor :value
2872
+
2873
+ def initialize(unit: nil, value: nil)
2874
+ @unit = unit
2875
+ @value = value
2876
+ end
2877
+ end
2878
+ # The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
2879
+ attr_accessor :maximum
2880
+ # The lower bound of the estimated range. If empty, represents no lower bound.
2881
+ attr_accessor :minimum
2882
+
2883
+ def initialize(maximum: nil, minimum: nil)
2884
+ @maximum = maximum
2885
+ @minimum = minimum
2886
+ end
2887
+ end
2888
+
2889
+ class FixedAmount < Stripe::RequestParams
2890
+ class CurrencyOptions < Stripe::RequestParams
2891
+ # A non-negative integer in cents representing how much to charge.
2892
+ attr_accessor :amount
2893
+ # Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
2894
+ attr_accessor :tax_behavior
2895
+
2896
+ def initialize(amount: nil, tax_behavior: nil)
2897
+ @amount = amount
2898
+ @tax_behavior = tax_behavior
2899
+ end
2900
+ end
2901
+ # A non-negative integer in cents representing how much to charge.
2902
+ attr_accessor :amount
2903
+ # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
2904
+ attr_accessor :currency
2905
+ # Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
2906
+ attr_accessor :currency_options
2907
+
2908
+ def initialize(amount: nil, currency: nil, currency_options: nil)
2909
+ @amount = amount
2910
+ @currency = currency
2911
+ @currency_options = currency_options
2912
+ end
2913
+ end
2914
+ # The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
2915
+ attr_accessor :delivery_estimate
2916
+ # The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
2917
+ attr_accessor :display_name
2918
+ # Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
2919
+ attr_accessor :fixed_amount
2920
+ # 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`.
2921
+ attr_accessor :metadata
2922
+ # Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
2923
+ attr_accessor :tax_behavior
2924
+ # A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
2925
+ attr_accessor :tax_code
2926
+ # The type of calculation to use on the shipping rate.
2927
+ attr_accessor :type
2928
+
2929
+ def initialize(
2930
+ delivery_estimate: nil,
2931
+ display_name: nil,
2932
+ fixed_amount: nil,
2933
+ metadata: nil,
2934
+ tax_behavior: nil,
2935
+ tax_code: nil,
2936
+ type: nil
2937
+ )
2938
+ @delivery_estimate = delivery_estimate
2939
+ @display_name = display_name
2940
+ @fixed_amount = fixed_amount
2941
+ @metadata = metadata
2942
+ @tax_behavior = tax_behavior
2943
+ @tax_code = tax_code
2944
+ @type = type
2945
+ end
2946
+ end
2947
+ # The ID of the Shipping Rate to use for this shipping option.
2948
+ attr_accessor :shipping_rate
2949
+ # Parameters to be passed to Shipping Rate creation for this shipping option.
2950
+ attr_accessor :shipping_rate_data
2951
+
2952
+ def initialize(shipping_rate: nil, shipping_rate_data: nil)
2953
+ @shipping_rate = shipping_rate
2954
+ @shipping_rate_data = shipping_rate_data
2955
+ end
2956
+ end
2957
+
2958
+ class SubscriptionData < Stripe::RequestParams
2959
+ class InvoiceSettings < Stripe::RequestParams
2960
+ class Issuer < Stripe::RequestParams
2961
+ # The connected account being referenced when `type` is `account`.
2962
+ attr_accessor :account
2963
+ # Type of the account referenced in the request.
2964
+ attr_accessor :type
2965
+
2966
+ def initialize(account: nil, type: nil)
2967
+ @account = account
2968
+ @type = type
2969
+ end
2970
+ end
2971
+ # The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
2972
+ attr_accessor :issuer
2973
+
2974
+ def initialize(issuer: nil)
2975
+ @issuer = issuer
2976
+ end
2977
+ end
2978
+
2979
+ class TransferData < Stripe::RequestParams
2980
+ # 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 destination account. By default, the entire amount is transferred to the destination.
2981
+ attr_accessor :amount_percent
2982
+ # ID of an existing, connected Stripe account.
2983
+ attr_accessor :destination
2984
+
2985
+ def initialize(amount_percent: nil, destination: nil)
2986
+ @amount_percent = amount_percent
2987
+ @destination = destination
2988
+ end
2989
+ end
2990
+
2991
+ class TrialSettings < Stripe::RequestParams
2992
+ class EndBehavior < Stripe::RequestParams
2993
+ # Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
2994
+ attr_accessor :missing_payment_method
2995
+
2996
+ def initialize(missing_payment_method: nil)
2997
+ @missing_payment_method = missing_payment_method
2998
+ end
2999
+ end
3000
+ # Defines how the subscription should behave when the user's free trial ends.
3001
+ attr_accessor :end_behavior
3002
+
3003
+ def initialize(end_behavior: nil)
3004
+ @end_behavior = end_behavior
3005
+ end
3006
+ end
3007
+ # 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. To use an application fee percent, the request must be made on behalf of another account, using the `Stripe-Account` header or an OAuth key. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
3008
+ attr_accessor :application_fee_percent
3009
+ # A future timestamp to anchor the subscription's billing cycle for new subscriptions.
3010
+ attr_accessor :billing_cycle_anchor
3011
+ # The tax rates that will apply to any subscription item that does not have
3012
+ # `tax_rates` set. Invoices created will have their `default_tax_rates` populated
3013
+ # from the subscription.
3014
+ attr_accessor :default_tax_rates
3015
+ # The subscription's description, meant to be displayable to the customer.
3016
+ # Use this field to optionally store an explanation of the subscription
3017
+ # for rendering in the [customer portal](https://stripe.com/docs/customer-management).
3018
+ attr_accessor :description
3019
+ # All invoices will be billed using the specified settings.
3020
+ attr_accessor :invoice_settings
3021
+ # 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`.
3022
+ attr_accessor :metadata
3023
+ # The account on behalf of which to charge, for each of the subscription's invoices.
3024
+ attr_accessor :on_behalf_of
3025
+ # Determines how to handle prorations resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
3026
+ attr_accessor :proration_behavior
3027
+ # If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
3028
+ attr_accessor :transfer_data
3029
+ # Unix timestamp representing the end of the trial period the customer
3030
+ # will get before being charged for the first time. Has to be at least
3031
+ # 48 hours in the future.
3032
+ attr_accessor :trial_end
3033
+ # Integer representing the number of trial period days before the
3034
+ # customer is charged for the first time. Has to be at least 1.
3035
+ attr_accessor :trial_period_days
3036
+ # Settings related to subscription trials.
3037
+ attr_accessor :trial_settings
3038
+
3039
+ def initialize(
3040
+ application_fee_percent: nil,
3041
+ billing_cycle_anchor: nil,
3042
+ default_tax_rates: nil,
3043
+ description: nil,
3044
+ invoice_settings: nil,
3045
+ metadata: nil,
3046
+ on_behalf_of: nil,
3047
+ proration_behavior: nil,
3048
+ transfer_data: nil,
3049
+ trial_end: nil,
3050
+ trial_period_days: nil,
3051
+ trial_settings: nil
3052
+ )
3053
+ @application_fee_percent = application_fee_percent
3054
+ @billing_cycle_anchor = billing_cycle_anchor
3055
+ @default_tax_rates = default_tax_rates
3056
+ @description = description
3057
+ @invoice_settings = invoice_settings
3058
+ @metadata = metadata
3059
+ @on_behalf_of = on_behalf_of
3060
+ @proration_behavior = proration_behavior
3061
+ @transfer_data = transfer_data
3062
+ @trial_end = trial_end
3063
+ @trial_period_days = trial_period_days
3064
+ @trial_settings = trial_settings
3065
+ end
3066
+ end
3067
+
3068
+ class TaxIdCollection < Stripe::RequestParams
3069
+ # Enable tax ID collection during checkout. Defaults to `false`.
3070
+ attr_accessor :enabled
3071
+ # Describes whether a tax ID is required during checkout. Defaults to `never`.
3072
+ attr_accessor :required
3073
+
3074
+ def initialize(enabled: nil, required: nil)
3075
+ @enabled = enabled
3076
+ @required = required
3077
+ end
3078
+ end
3079
+ # Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
3080
+ attr_accessor :adaptive_pricing
3081
+ # Configure actions after a Checkout Session has expired.
3082
+ attr_accessor :after_expiration
3083
+ # Enables user redeemable promotion codes.
3084
+ attr_accessor :allow_promotion_codes
3085
+ # Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.
3086
+ attr_accessor :automatic_tax
3087
+ # Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.
3088
+ attr_accessor :billing_address_collection
3089
+ # If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded` or `custom`.
3090
+ attr_accessor :cancel_url
3091
+ # A unique string to reference the Checkout Session. This can be a
3092
+ # customer ID, a cart ID, or similar, and can be used to reconcile the
3093
+ # session with your internal systems.
3094
+ attr_accessor :client_reference_id
3095
+ # Configure fields for the Checkout Session to gather active consent from customers.
3096
+ attr_accessor :consent_collection
3097
+ # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Required in `setup` mode when `payment_method_types` is not set.
3098
+ attr_accessor :currency
3099
+ # Collect additional information from your customer using custom fields. Up to 3 fields are supported.
3100
+ attr_accessor :custom_fields
3101
+ # Display additional text for your customers using custom text.
3102
+ attr_accessor :custom_text
3103
+ # ID of an existing Customer, if one exists. In `payment` mode, the customer’s most recently saved card
3104
+ # payment method will be used to prefill the email, name, card details, and billing address
3105
+ # on the Checkout page. In `subscription` mode, the customer’s [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
3106
+ # will be used if it’s a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.
3107
+ #
3108
+ # If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
3109
+ # If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
3110
+ #
3111
+ # If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
3112
+ #
3113
+ # You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
3114
+ attr_accessor :customer
3115
+ # Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.
3116
+ #
3117
+ # When a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout
3118
+ # with [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).
3119
+ #
3120
+ # Sessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)
3121
+ # in the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.
3122
+ #
3123
+ # Can only be set in `payment` and `setup` mode.
3124
+ attr_accessor :customer_creation
3125
+ # If provided, this value will be used when the Customer object is created.
3126
+ # If not provided, customers will be asked to enter their email address.
3127
+ # Use this parameter to prefill customer data if you already have an email
3128
+ # on file. To access information about the customer once a session is
3129
+ # complete, use the `customer` field.
3130
+ attr_accessor :customer_email
3131
+ # Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.
3132
+ attr_accessor :customer_update
3133
+ # The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.
3134
+ attr_accessor :discounts
3135
+ # Specifies which fields in the response should be expanded.
3136
+ attr_accessor :expand
3137
+ # The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.
3138
+ attr_accessor :expires_at
3139
+ # Generate a post-purchase Invoice for one-time payments.
3140
+ attr_accessor :invoice_creation
3141
+ # A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
3142
+ #
3143
+ # For `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.
3144
+ #
3145
+ # For `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.
3146
+ attr_accessor :line_items
3147
+ # The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
3148
+ attr_accessor :locale
3149
+ # 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`.
3150
+ attr_accessor :metadata
3151
+ # The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.
3152
+ attr_accessor :mode
3153
+ # A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
3154
+ attr_accessor :payment_intent_data
3155
+ # Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.
3156
+ # This may occur if the Checkout Session includes a free trial or a discount.
3157
+ #
3158
+ # Can only be set in `subscription` mode. Defaults to `always`.
3159
+ #
3160
+ # If you'd like information on how to collect a payment method outside of Checkout, read the guide on configuring [subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
3161
+ attr_accessor :payment_method_collection
3162
+ # The ID of the payment method configuration to use with this Checkout session.
3163
+ attr_accessor :payment_method_configuration
3164
+ # This parameter allows you to set some attributes on the payment method created during a Checkout session.
3165
+ attr_accessor :payment_method_data
3166
+ # Payment-method-specific configuration.
3167
+ attr_accessor :payment_method_options
3168
+ # A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.
3169
+ #
3170
+ # You can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
3171
+ # See [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.
3172
+ #
3173
+ # Read more about the supported payment methods and their requirements in our [payment
3174
+ # method details guide](/docs/payments/checkout/payment-methods).
3175
+ #
3176
+ # If multiple payment methods are passed, Checkout will dynamically reorder them to
3177
+ # prioritize the most relevant payment methods based on the customer's location and
3178
+ # other characteristics.
3179
+ attr_accessor :payment_method_types
3180
+ # This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object.
3181
+ #
3182
+ # For specific permissions, please refer to their dedicated subsections, such as `permissions.update.shipping_details`.
3183
+ attr_accessor :permissions
3184
+ # Controls phone number collection settings for the session.
3185
+ #
3186
+ # We recommend that you review your privacy policy and check with your legal contacts
3187
+ # before using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).
3188
+ attr_accessor :phone_number_collection
3189
+ # This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
3190
+ attr_accessor :redirect_on_completion
3191
+ # The URL to redirect your customer back to after they authenticate or cancel their payment on the
3192
+ # payment method's app or site. This parameter is required if `ui_mode` is `embedded` or `custom`
3193
+ # and redirect-based payment methods are enabled on the session.
3194
+ attr_accessor :return_url
3195
+ # Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
3196
+ attr_accessor :saved_payment_method_options
3197
+ # A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.
3198
+ attr_accessor :setup_intent_data
3199
+ # When set, provides configuration for Checkout to collect a shipping address from a customer.
3200
+ attr_accessor :shipping_address_collection
3201
+ # The shipping rate options to apply to this Session. Up to a maximum of 5.
3202
+ attr_accessor :shipping_options
3203
+ # Describes the type of transaction being performed by Checkout in order to customize
3204
+ # relevant text on the page, such as the submit button. `submit_type` can only be
3205
+ # specified on Checkout Sessions in `payment` mode. If blank or `auto`, `pay` is used.
3206
+ attr_accessor :submit_type
3207
+ # A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.
3208
+ attr_accessor :subscription_data
3209
+ # The URL to which Stripe should send customers when payment or setup
3210
+ # is complete.
3211
+ # This parameter is not allowed if ui_mode is `embedded` or `custom`. If you'd like to use
3212
+ # information from the successful Checkout Session on your page, read the
3213
+ # guide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).
3214
+ attr_accessor :success_url
3215
+ # Controls tax ID collection during checkout.
3216
+ attr_accessor :tax_id_collection
3217
+ # The UI mode of the Session. Defaults to `hosted`.
3218
+ attr_accessor :ui_mode
3219
+
3220
+ def initialize(
3221
+ adaptive_pricing: nil,
3222
+ after_expiration: nil,
3223
+ allow_promotion_codes: nil,
3224
+ automatic_tax: nil,
3225
+ billing_address_collection: nil,
3226
+ cancel_url: nil,
3227
+ client_reference_id: nil,
3228
+ consent_collection: nil,
3229
+ currency: nil,
3230
+ custom_fields: nil,
3231
+ custom_text: nil,
3232
+ customer: nil,
3233
+ customer_creation: nil,
3234
+ customer_email: nil,
3235
+ customer_update: nil,
3236
+ discounts: nil,
3237
+ expand: nil,
3238
+ expires_at: nil,
3239
+ invoice_creation: nil,
3240
+ line_items: nil,
3241
+ locale: nil,
3242
+ metadata: nil,
3243
+ mode: nil,
3244
+ payment_intent_data: nil,
3245
+ payment_method_collection: nil,
3246
+ payment_method_configuration: nil,
3247
+ payment_method_data: nil,
3248
+ payment_method_options: nil,
3249
+ payment_method_types: nil,
3250
+ permissions: nil,
3251
+ phone_number_collection: nil,
3252
+ redirect_on_completion: nil,
3253
+ return_url: nil,
3254
+ saved_payment_method_options: nil,
3255
+ setup_intent_data: nil,
3256
+ shipping_address_collection: nil,
3257
+ shipping_options: nil,
3258
+ submit_type: nil,
3259
+ subscription_data: nil,
3260
+ success_url: nil,
3261
+ tax_id_collection: nil,
3262
+ ui_mode: nil
3263
+ )
3264
+ @adaptive_pricing = adaptive_pricing
3265
+ @after_expiration = after_expiration
3266
+ @allow_promotion_codes = allow_promotion_codes
3267
+ @automatic_tax = automatic_tax
3268
+ @billing_address_collection = billing_address_collection
3269
+ @cancel_url = cancel_url
3270
+ @client_reference_id = client_reference_id
3271
+ @consent_collection = consent_collection
3272
+ @currency = currency
3273
+ @custom_fields = custom_fields
3274
+ @custom_text = custom_text
3275
+ @customer = customer
3276
+ @customer_creation = customer_creation
3277
+ @customer_email = customer_email
3278
+ @customer_update = customer_update
3279
+ @discounts = discounts
3280
+ @expand = expand
3281
+ @expires_at = expires_at
3282
+ @invoice_creation = invoice_creation
3283
+ @line_items = line_items
3284
+ @locale = locale
3285
+ @metadata = metadata
3286
+ @mode = mode
3287
+ @payment_intent_data = payment_intent_data
3288
+ @payment_method_collection = payment_method_collection
3289
+ @payment_method_configuration = payment_method_configuration
3290
+ @payment_method_data = payment_method_data
3291
+ @payment_method_options = payment_method_options
3292
+ @payment_method_types = payment_method_types
3293
+ @permissions = permissions
3294
+ @phone_number_collection = phone_number_collection
3295
+ @redirect_on_completion = redirect_on_completion
3296
+ @return_url = return_url
3297
+ @saved_payment_method_options = saved_payment_method_options
3298
+ @setup_intent_data = setup_intent_data
3299
+ @shipping_address_collection = shipping_address_collection
3300
+ @shipping_options = shipping_options
3301
+ @submit_type = submit_type
3302
+ @subscription_data = subscription_data
3303
+ @success_url = success_url
3304
+ @tax_id_collection = tax_id_collection
3305
+ @ui_mode = ui_mode
3306
+ end
3307
+ end
3308
+
3309
+ class RetrieveParams < Stripe::RequestParams
3310
+ # Specifies which fields in the response should be expanded.
3311
+ attr_accessor :expand
3312
+
3313
+ def initialize(expand: nil)
3314
+ @expand = expand
3315
+ end
3316
+ end
3317
+
3318
+ class UpdateParams < Stripe::RequestParams
3319
+ class CollectedInformation < Stripe::RequestParams
3320
+ class ShippingDetails < Stripe::RequestParams
3321
+ class Address < Stripe::RequestParams
3322
+ # City, district, suburb, town, or village.
3323
+ attr_accessor :city
3324
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
3325
+ attr_accessor :country
3326
+ # Address line 1 (e.g., street, PO Box, or company name).
3327
+ attr_accessor :line1
3328
+ # Address line 2 (e.g., apartment, suite, unit, or building).
3329
+ attr_accessor :line2
3330
+ # ZIP or postal code.
3331
+ attr_accessor :postal_code
3332
+ # State, county, province, or region.
3333
+ attr_accessor :state
3334
+
3335
+ def initialize(
3336
+ city: nil,
3337
+ country: nil,
3338
+ line1: nil,
3339
+ line2: nil,
3340
+ postal_code: nil,
3341
+ state: nil
3342
+ )
3343
+ @city = city
3344
+ @country = country
3345
+ @line1 = line1
3346
+ @line2 = line2
3347
+ @postal_code = postal_code
3348
+ @state = state
3349
+ end
3350
+ end
3351
+ # The address of the customer
3352
+ attr_accessor :address
3353
+ # The name of customer
3354
+ attr_accessor :name
3355
+
3356
+ def initialize(address: nil, name: nil)
3357
+ @address = address
3358
+ @name = name
3359
+ end
3360
+ end
3361
+ # The shipping details to apply to this Session.
3362
+ attr_accessor :shipping_details
3363
+
3364
+ def initialize(shipping_details: nil)
3365
+ @shipping_details = shipping_details
3366
+ end
3367
+ end
3368
+
3369
+ class LineItem < Stripe::RequestParams
3370
+ class AdjustableQuantity < Stripe::RequestParams
3371
+ # Set to true if the quantity can be adjusted to any positive integer. Setting to false will remove any previously specified constraints on quantity.
3372
+ attr_accessor :enabled
3373
+ # The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
3374
+ attr_accessor :maximum
3375
+ # The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
3376
+ attr_accessor :minimum
3377
+
3378
+ def initialize(enabled: nil, maximum: nil, minimum: nil)
3379
+ @enabled = enabled
3380
+ @maximum = maximum
3381
+ @minimum = minimum
3382
+ end
3383
+ end
3384
+ # When set, provides configuration for this item’s quantity to be adjusted by the customer during Checkout.
3385
+ attr_accessor :adjustable_quantity
3386
+ # ID of an existing line item.
3387
+ attr_accessor :id
3388
+ # 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`.
3389
+ attr_accessor :metadata
3390
+ # The ID of the [Price](https://stripe.com/docs/api/prices).
3391
+ attr_accessor :price
3392
+ # The quantity of the line item being purchased.
3393
+ attr_accessor :quantity
3394
+ # The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
3395
+ attr_accessor :tax_rates
3396
+
3397
+ def initialize(
3398
+ adjustable_quantity: nil,
3399
+ id: nil,
3400
+ metadata: nil,
3401
+ price: nil,
3402
+ quantity: nil,
3403
+ tax_rates: nil
3404
+ )
3405
+ @adjustable_quantity = adjustable_quantity
3406
+ @id = id
3407
+ @metadata = metadata
3408
+ @price = price
3409
+ @quantity = quantity
3410
+ @tax_rates = tax_rates
3411
+ end
3412
+ end
3413
+
3414
+ class ShippingOption < Stripe::RequestParams
3415
+ class ShippingRateData < Stripe::RequestParams
3416
+ class DeliveryEstimate < Stripe::RequestParams
3417
+ class Maximum < Stripe::RequestParams
3418
+ # A unit of time.
3419
+ attr_accessor :unit
3420
+ # Must be greater than 0.
3421
+ attr_accessor :value
3422
+
3423
+ def initialize(unit: nil, value: nil)
3424
+ @unit = unit
3425
+ @value = value
3426
+ end
3427
+ end
3428
+
3429
+ class Minimum < Stripe::RequestParams
3430
+ # A unit of time.
3431
+ attr_accessor :unit
3432
+ # Must be greater than 0.
3433
+ attr_accessor :value
3434
+
3435
+ def initialize(unit: nil, value: nil)
3436
+ @unit = unit
3437
+ @value = value
3438
+ end
3439
+ end
3440
+ # The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
3441
+ attr_accessor :maximum
3442
+ # The lower bound of the estimated range. If empty, represents no lower bound.
3443
+ attr_accessor :minimum
3444
+
3445
+ def initialize(maximum: nil, minimum: nil)
3446
+ @maximum = maximum
3447
+ @minimum = minimum
3448
+ end
3449
+ end
3450
+
3451
+ class FixedAmount < Stripe::RequestParams
3452
+ class CurrencyOptions < Stripe::RequestParams
3453
+ # A non-negative integer in cents representing how much to charge.
3454
+ attr_accessor :amount
3455
+ # Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
3456
+ attr_accessor :tax_behavior
3457
+
3458
+ def initialize(amount: nil, tax_behavior: nil)
3459
+ @amount = amount
3460
+ @tax_behavior = tax_behavior
3461
+ end
3462
+ end
3463
+ # A non-negative integer in cents representing how much to charge.
3464
+ attr_accessor :amount
3465
+ # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
3466
+ attr_accessor :currency
3467
+ # Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
3468
+ attr_accessor :currency_options
3469
+
3470
+ def initialize(amount: nil, currency: nil, currency_options: nil)
3471
+ @amount = amount
3472
+ @currency = currency
3473
+ @currency_options = currency_options
3474
+ end
3475
+ end
3476
+ # The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
3477
+ attr_accessor :delivery_estimate
3478
+ # The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
3479
+ attr_accessor :display_name
3480
+ # Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
3481
+ attr_accessor :fixed_amount
3482
+ # 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`.
3483
+ attr_accessor :metadata
3484
+ # Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
3485
+ attr_accessor :tax_behavior
3486
+ # A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
3487
+ attr_accessor :tax_code
3488
+ # The type of calculation to use on the shipping rate.
3489
+ attr_accessor :type
3490
+
3491
+ def initialize(
3492
+ delivery_estimate: nil,
3493
+ display_name: nil,
3494
+ fixed_amount: nil,
3495
+ metadata: nil,
3496
+ tax_behavior: nil,
3497
+ tax_code: nil,
3498
+ type: nil
3499
+ )
3500
+ @delivery_estimate = delivery_estimate
3501
+ @display_name = display_name
3502
+ @fixed_amount = fixed_amount
3503
+ @metadata = metadata
3504
+ @tax_behavior = tax_behavior
3505
+ @tax_code = tax_code
3506
+ @type = type
3507
+ end
3508
+ end
3509
+ # The ID of the Shipping Rate to use for this shipping option.
3510
+ attr_accessor :shipping_rate
3511
+ # Parameters to be passed to Shipping Rate creation for this shipping option.
3512
+ attr_accessor :shipping_rate_data
3513
+
3514
+ def initialize(shipping_rate: nil, shipping_rate_data: nil)
3515
+ @shipping_rate = shipping_rate
3516
+ @shipping_rate_data = shipping_rate_data
3517
+ end
3518
+ end
3519
+ # Information about the customer collected within the Checkout Session.
3520
+ attr_accessor :collected_information
3521
+ # Specifies which fields in the response should be expanded.
3522
+ attr_accessor :expand
3523
+ # A list of items the customer is purchasing.
3524
+ #
3525
+ # When updating line items, you must retransmit the entire array of line items.
3526
+ #
3527
+ # To retain an existing line item, specify its `id`.
3528
+ #
3529
+ # To update an existing line item, specify its `id` along with the new values of the fields to update.
3530
+ #
3531
+ # To add a new line item, specify a `price` and `quantity`. We don't currently support recurring prices.
3532
+ #
3533
+ # To remove an existing line item, omit the line item's ID from the retransmitted array.
3534
+ #
3535
+ # To reorder a line item, specify it at the desired position in the retransmitted array.
3536
+ attr_accessor :line_items
3537
+ # 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`.
3538
+ attr_accessor :metadata
3539
+ # The shipping rate options to apply to this Session. Up to a maximum of 5.
3540
+ attr_accessor :shipping_options
3541
+
3542
+ def initialize(
3543
+ collected_information: nil,
3544
+ expand: nil,
3545
+ line_items: nil,
3546
+ metadata: nil,
3547
+ shipping_options: nil
3548
+ )
3549
+ @collected_information = collected_information
3550
+ @expand = expand
3551
+ @line_items = line_items
3552
+ @metadata = metadata
3553
+ @shipping_options = shipping_options
3554
+ end
3555
+ end
3556
+
3557
+ class ListLineItemsParams < Stripe::RequestParams
3558
+ # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
3559
+ attr_accessor :ending_before
3560
+ # Specifies which fields in the response should be expanded.
3561
+ attr_accessor :expand
3562
+ # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
3563
+ attr_accessor :limit
3564
+ # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
3565
+ attr_accessor :starting_after
3566
+
3567
+ def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil)
3568
+ @ending_before = ending_before
3569
+ @expand = expand
3570
+ @limit = limit
3571
+ @starting_after = starting_after
3572
+ end
3573
+ end
3574
+
3575
+ class ExpireParams < Stripe::RequestParams
3576
+ # Specifies which fields in the response should be expanded.
3577
+ attr_accessor :expand
3578
+
3579
+ def initialize(expand: nil)
3580
+ @expand = expand
3581
+ end
3582
+ end
3583
+ # Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
3584
+ attr_reader :adaptive_pricing
3585
+ # When set, provides configuration for actions to take if this Checkout Session expires.
3586
+ attr_reader :after_expiration
3587
+ # Enables user redeemable promotion codes.
3588
+ attr_reader :allow_promotion_codes
3589
+ # Total of all items before discounts or taxes are applied.
3590
+ attr_reader :amount_subtotal
3591
+ # Total of all items after discounts and taxes are applied.
3592
+ attr_reader :amount_total
3593
+ # Attribute for field automatic_tax
3594
+ attr_reader :automatic_tax
3595
+ # Describes whether Checkout should collect the customer's billing address. Defaults to `auto`.
3596
+ attr_reader :billing_address_collection
3597
+ # If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website.
3598
+ attr_reader :cancel_url
3599
+ # A unique string to reference the Checkout Session. This can be a
3600
+ # customer ID, a cart ID, or similar, and can be used to reconcile the
3601
+ # Session with your internal systems.
3602
+ attr_reader :client_reference_id
3603
+ # The client secret of the Session. Use this with [initCheckout](https://stripe.com/docs/js/custom_checkout/init) on your front end.
3604
+ attr_reader :client_secret
3605
+ # Information about the customer collected within the Checkout Session.
3606
+ attr_reader :collected_information
3607
+ # Results of `consent_collection` for this session.
3608
+ attr_reader :consent
3609
+ # When set, provides configuration for the Checkout Session to gather active consent from customers.
3610
+ attr_reader :consent_collection
3611
+ # Time at which the object was created. Measured in seconds since the Unix epoch.
3612
+ attr_reader :created
3613
+ # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
3614
+ attr_reader :currency
3615
+ # Currency conversion details for [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing) sessions
3616
+ attr_reader :currency_conversion
3617
+ # Collect additional information from your customer using custom fields. Up to 3 fields are supported.
3618
+ attr_reader :custom_fields
3619
+ # Attribute for field custom_text
3620
+ attr_reader :custom_text
3621
+ # The ID of the customer for this Session.
3622
+ # For Checkout Sessions in `subscription` mode or Checkout Sessions with `customer_creation` set as `always` in `payment` mode, Checkout
3623
+ # will create a new customer object based on information provided
3624
+ # during the payment flow unless an existing customer was provided when
3625
+ # the Session was created.
3626
+ attr_reader :customer
3627
+ # Configure whether a Checkout Session creates a Customer when the Checkout Session completes.
3628
+ attr_reader :customer_creation
3629
+ # The customer details including the customer's tax exempt status and the customer's tax IDs. Customer's address details are not present on Sessions in `setup` mode.
3630
+ attr_reader :customer_details
3631
+ # If provided, this value will be used when the Customer object is created.
3632
+ # If not provided, customers will be asked to enter their email address.
3633
+ # Use this parameter to prefill customer data if you already have an email
3634
+ # on file. To access information about the customer once the payment flow is
3635
+ # complete, use the `customer` attribute.
3636
+ attr_reader :customer_email
3637
+ # List of coupons and promotion codes attached to the Checkout Session.
3638
+ attr_reader :discounts
3639
+ # The timestamp at which the Checkout Session will expire.
3640
+ attr_reader :expires_at
3641
+ # Unique identifier for the object.
3642
+ attr_reader :id
3643
+ # ID of the invoice created by the Checkout Session, if it exists.
3644
+ attr_reader :invoice
3645
+ # Details on the state of invoice creation for the Checkout Session.
3646
+ attr_reader :invoice_creation
3647
+ # The line items purchased by the customer.
3648
+ attr_reader :line_items
3649
+ # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
3650
+ attr_reader :livemode
3651
+ # The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
3652
+ attr_reader :locale
3653
+ # 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.
3654
+ attr_reader :metadata
3655
+ # The mode of the Checkout Session.
3656
+ attr_reader :mode
3657
+ # String representing the object's type. Objects of the same type share the same value.
3658
+ attr_reader :object
3659
+ # The ID of the PaymentIntent for Checkout Sessions in `payment` mode. You can't confirm or cancel the PaymentIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead.
3660
+ attr_reader :payment_intent
3661
+ # The ID of the Payment Link that created this Session.
3662
+ attr_reader :payment_link
3663
+ # Configure whether a Checkout Session should collect a payment method. Defaults to `always`.
3664
+ attr_reader :payment_method_collection
3665
+ # Information about the payment method configuration used for this Checkout session if using dynamic payment methods.
3666
+ attr_reader :payment_method_configuration_details
3667
+ # Payment-method-specific configuration for the PaymentIntent or SetupIntent of this CheckoutSession.
3668
+ attr_reader :payment_method_options
3669
+ # A list of the types of payment methods (e.g. card) this Checkout
3670
+ # Session is allowed to accept.
3671
+ attr_reader :payment_method_types
3672
+ # The payment status of the Checkout Session, one of `paid`, `unpaid`, or `no_payment_required`.
3673
+ # You can use this value to decide when to fulfill your customer's order.
3674
+ attr_reader :payment_status
3675
+ # This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object.
3676
+ #
3677
+ # For specific permissions, please refer to their dedicated subsections, such as `permissions.update.shipping_details`.
3678
+ attr_reader :permissions
3679
+ # Attribute for field phone_number_collection
3680
+ attr_reader :phone_number_collection
3681
+ # The ID of the original expired Checkout Session that triggered the recovery flow.
3682
+ attr_reader :recovered_from
3683
+ # This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
3684
+ attr_reader :redirect_on_completion
3685
+ # Applies to Checkout Sessions with `ui_mode: embedded` or `ui_mode: custom`. The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
3686
+ attr_reader :return_url
3687
+ # Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
3688
+ attr_reader :saved_payment_method_options
3689
+ # The ID of the SetupIntent for Checkout Sessions in `setup` mode. You can't confirm or cancel the SetupIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead.
3690
+ attr_reader :setup_intent
3691
+ # When set, provides configuration for Checkout to collect a shipping address from a customer.
3692
+ attr_reader :shipping_address_collection
3693
+ # The details of the customer cost of shipping, including the customer chosen ShippingRate.
3694
+ attr_reader :shipping_cost
3695
+ # Shipping information for this Checkout Session.
3696
+ attr_reader :shipping_details
3697
+ # The shipping rate options applied to this Session.
3698
+ attr_reader :shipping_options
3699
+ # The status of the Checkout Session, one of `open`, `complete`, or `expired`.
3700
+ attr_reader :status
3701
+ # Describes the type of transaction being performed by Checkout in order to customize
3702
+ # relevant text on the page, such as the submit button. `submit_type` can only be
3703
+ # specified on Checkout Sessions in `payment` mode. If blank or `auto`, `pay` is used.
3704
+ attr_reader :submit_type
3705
+ # The ID of the subscription for Checkout Sessions in `subscription` mode.
3706
+ attr_reader :subscription
3707
+ # The URL the customer will be directed to after the payment or
3708
+ # subscription creation is successful.
3709
+ attr_reader :success_url
3710
+ # Attribute for field tax_id_collection
3711
+ attr_reader :tax_id_collection
3712
+ # Tax and discount details for the computed total amount.
3713
+ attr_reader :total_details
3714
+ # The UI mode of the Session. Defaults to `hosted`.
3715
+ attr_reader :ui_mode
3716
+ # The URL to the Checkout Session. Redirect customers to this URL to take them to Checkout. If you’re using [Custom Domains](https://stripe.com/docs/payments/checkout/custom-domains), the URL will use your subdomain. Otherwise, it’ll use `checkout.stripe.com.`
3717
+ # This value is only present when the session is active.
3718
+ attr_reader :url
3719
+
30
3720
  # Creates a Session object.
31
3721
  def self.create(params = {}, opts = {})
32
3722
  request_stripe_object(