stripe 17.0.0 → 17.1.0.pre.beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (509) hide show
  1. checksums.yaml +4 -4
  2. data/lib/stripe/api_requestor.rb +34 -0
  3. data/lib/stripe/api_version.rb +1 -2
  4. data/lib/stripe/errors.rb +63 -0
  5. data/lib/stripe/event_types.rb +236 -0
  6. data/lib/stripe/events/v2_billing_bill_setting_updated_event.rb +61 -0
  7. data/lib/stripe/events/v2_core_account_closed_event.rb +44 -0
  8. data/lib/stripe/events/v2_core_account_created_event.rb +44 -0
  9. data/lib/stripe/events/v2_core_account_including_configuration_customer_capability_status_updated_event.rb +63 -0
  10. data/lib/stripe/events/v2_core_account_including_configuration_customer_updated_event.rb +44 -0
  11. data/lib/stripe/events/v2_core_account_including_configuration_merchant_capability_status_updated_event.rb +63 -0
  12. data/lib/stripe/events/v2_core_account_including_configuration_merchant_updated_event.rb +44 -0
  13. data/lib/stripe/events/v2_core_account_including_configuration_recipient_capability_status_updated_event.rb +63 -0
  14. data/lib/stripe/events/v2_core_account_including_configuration_recipient_updated_event.rb +44 -0
  15. data/lib/stripe/events/v2_core_account_including_configuration_storer_capability_status_updated_event.rb +63 -0
  16. data/lib/stripe/events/v2_core_account_including_configuration_storer_updated_event.rb +44 -0
  17. data/lib/stripe/events/v2_core_account_including_defaults_updated_event.rb +44 -0
  18. data/lib/stripe/events/v2_core_account_including_identity_updated_event.rb +44 -0
  19. data/lib/stripe/events/v2_core_account_including_requirements_updated_event.rb +44 -0
  20. data/lib/stripe/events/v2_core_account_link_returned_event.rb +42 -0
  21. data/lib/stripe/events/v2_core_account_person_created_event.rb +61 -0
  22. data/lib/stripe/events/v2_core_account_person_deleted_event.rb +61 -0
  23. data/lib/stripe/events/v2_core_account_person_updated_event.rb +61 -0
  24. data/lib/stripe/events/v2_core_account_updated_event.rb +44 -0
  25. data/lib/stripe/events/v2_money_management_adjustment_created_event.rb +44 -0
  26. data/lib/stripe/events/v2_money_management_financial_account_created_event.rb +44 -0
  27. data/lib/stripe/events/v2_money_management_financial_account_updated_event.rb +44 -0
  28. data/lib/stripe/events/v2_money_management_financial_address_activated_event.rb +44 -0
  29. data/lib/stripe/events/v2_money_management_financial_address_failed_event.rb +44 -0
  30. data/lib/stripe/events/v2_money_management_inbound_transfer_available_event.rb +61 -0
  31. data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_failed_event.rb +44 -0
  32. data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_processing_event.rb +44 -0
  33. data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_queued_event.rb +44 -0
  34. data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_returned_event.rb +44 -0
  35. data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_succeeded_event.rb +44 -0
  36. data/lib/stripe/events/v2_money_management_outbound_payment_canceled_event.rb +44 -0
  37. data/lib/stripe/events/v2_money_management_outbound_payment_created_event.rb +44 -0
  38. data/lib/stripe/events/v2_money_management_outbound_payment_failed_event.rb +44 -0
  39. data/lib/stripe/events/v2_money_management_outbound_payment_posted_event.rb +44 -0
  40. data/lib/stripe/events/v2_money_management_outbound_payment_returned_event.rb +44 -0
  41. data/lib/stripe/events/v2_money_management_outbound_payment_updated_event.rb +44 -0
  42. data/lib/stripe/events/v2_money_management_outbound_transfer_canceled_event.rb +44 -0
  43. data/lib/stripe/events/v2_money_management_outbound_transfer_created_event.rb +44 -0
  44. data/lib/stripe/events/v2_money_management_outbound_transfer_failed_event.rb +44 -0
  45. data/lib/stripe/events/v2_money_management_outbound_transfer_posted_event.rb +44 -0
  46. data/lib/stripe/events/v2_money_management_outbound_transfer_returned_event.rb +44 -0
  47. data/lib/stripe/events/v2_money_management_outbound_transfer_updated_event.rb +44 -0
  48. data/lib/stripe/events/v2_money_management_payout_method_updated_event.rb +44 -0
  49. data/lib/stripe/events/v2_money_management_received_credit_available_event.rb +61 -0
  50. data/lib/stripe/events/v2_money_management_received_credit_failed_event.rb +44 -0
  51. data/lib/stripe/events/v2_money_management_received_credit_returned_event.rb +44 -0
  52. data/lib/stripe/events/v2_money_management_received_credit_succeeded_event.rb +44 -0
  53. data/lib/stripe/events/v2_money_management_received_debit_canceled_event.rb +44 -0
  54. data/lib/stripe/events/v2_money_management_received_debit_failed_event.rb +44 -0
  55. data/lib/stripe/events/v2_money_management_received_debit_pending_event.rb +44 -0
  56. data/lib/stripe/events/v2_money_management_received_debit_succeeded_event.rb +44 -0
  57. data/lib/stripe/events/v2_money_management_received_debit_updated_event.rb +44 -0
  58. data/lib/stripe/events/v2_money_management_transaction_created_event.rb +44 -0
  59. data/lib/stripe/events/v2_money_management_transaction_updated_event.rb +44 -0
  60. data/lib/stripe/events/v2_payments_off_session_payment_authorization_attempt_failed_event.rb +44 -0
  61. data/lib/stripe/events/v2_payments_off_session_payment_authorization_attempt_started_event.rb +46 -0
  62. data/lib/stripe/events/v2_payments_off_session_payment_canceled_event.rb +44 -0
  63. data/lib/stripe/events/v2_payments_off_session_payment_created_event.rb +44 -0
  64. data/lib/stripe/events/v2_payments_off_session_payment_failed_event.rb +44 -0
  65. data/lib/stripe/events/v2_payments_off_session_payment_requires_capture_event.rb +44 -0
  66. data/lib/stripe/events/v2_payments_off_session_payment_succeeded_event.rb +44 -0
  67. data/lib/stripe/object_types.rb +58 -0
  68. data/lib/stripe/params/account_create_params.rb +300 -1
  69. data/lib/stripe/params/account_notice_list_params.rb +25 -0
  70. data/lib/stripe/params/account_notice_retrieve_params.rb +13 -0
  71. data/lib/stripe/params/account_notice_update_params.rb +36 -0
  72. data/lib/stripe/params/account_session_create_params.rb +226 -1
  73. data/lib/stripe/params/account_update_params.rb +262 -0
  74. data/lib/stripe/params/billing/analytics/meter_usage_retrieve_params.rb +65 -0
  75. data/lib/stripe/params/billing/credit_balance_summary_retrieve_params.rb +4 -1
  76. data/lib/stripe/params/billing/credit_balance_transaction_list_params.rb +4 -0
  77. data/lib/stripe/params/billing/credit_grant_create_params.rb +4 -0
  78. data/lib/stripe/params/billing/credit_grant_list_params.rb +4 -0
  79. data/lib/stripe/params/billing_portal/session_create_params.rb +4 -0
  80. data/lib/stripe/params/capital/financing_offer_list_params.rb +58 -0
  81. data/lib/stripe/params/capital/financing_offer_mark_delivered_params.rb +15 -0
  82. data/lib/stripe/params/capital/financing_offer_retrieve_params.rb +15 -0
  83. data/lib/stripe/params/capital/financing_summary_retrieve_params.rb +15 -0
  84. data/lib/stripe/params/capital/financing_transaction_list_params.rb +45 -0
  85. data/lib/stripe/params/capital/financing_transaction_retrieve_params.rb +15 -0
  86. data/lib/stripe/params/charge_capture_params.rb +709 -0
  87. data/lib/stripe/params/charge_update_params.rb +709 -0
  88. data/lib/stripe/params/checkout/session_create_params.rb +193 -3
  89. data/lib/stripe/params/checkout/session_list_params.rb +4 -0
  90. data/lib/stripe/params/checkout/session_update_params.rb +288 -1
  91. data/lib/stripe/params/confirmation_token_create_params.rb +97 -0
  92. data/lib/stripe/params/coupon_create_params.rb +17 -1
  93. data/lib/stripe/params/credit_note_list_params.rb +4 -0
  94. data/lib/stripe/params/customer_session_create_params.rb +4 -1
  95. data/lib/stripe/params/dispute_update_params.rb +10 -1
  96. data/lib/stripe/params/external_account_create_params.rb +134 -0
  97. data/lib/stripe/params/external_account_delete_params.rb +6 -0
  98. data/lib/stripe/params/external_account_list_params.rb +25 -0
  99. data/lib/stripe/params/external_account_retrieve_params.rb +13 -0
  100. data/lib/stripe/params/external_account_update_params.rb +91 -0
  101. data/lib/stripe/params/financial_connections/account_inferred_balance_list_params.rb +24 -0
  102. data/lib/stripe/params/financial_connections/account_list_params.rb +4 -1
  103. data/lib/stripe/params/financial_connections/institution_list_params.rb +24 -0
  104. data/lib/stripe/params/financial_connections/institution_retrieve_params.rb +15 -0
  105. data/lib/stripe/params/financial_connections/session_create_params.rb +34 -2
  106. data/lib/stripe/params/fx_quote_create_params.rb +73 -0
  107. data/lib/stripe/params/fx_quote_list_params.rb +22 -0
  108. data/lib/stripe/params/fx_quote_retrieve_params.rb +13 -0
  109. data/lib/stripe/params/identity/verification_session_create_params.rb +4 -0
  110. data/lib/stripe/params/identity/verification_session_list_params.rb +4 -0
  111. data/lib/stripe/params/invoice_add_lines_params.rb +33 -1
  112. data/lib/stripe/params/invoice_attach_payment_params.rb +46 -1
  113. data/lib/stripe/params/invoice_create_params.rb +112 -2
  114. data/lib/stripe/params/invoice_create_preview_params.rb +826 -9
  115. data/lib/stripe/params/invoice_item_create_params.rb +37 -1
  116. data/lib/stripe/params/invoice_item_list_params.rb +4 -0
  117. data/lib/stripe/params/invoice_item_update_params.rb +33 -1
  118. data/lib/stripe/params/invoice_line_item_update_params.rb +33 -1
  119. data/lib/stripe/params/invoice_list_params.rb +4 -0
  120. data/lib/stripe/params/invoice_payment_list_params.rb +4 -1
  121. data/lib/stripe/params/invoice_update_lines_params.rb +33 -1
  122. data/lib/stripe/params/invoice_update_params.rb +108 -2
  123. data/lib/stripe/params/issuing/cardholder_create_params.rb +2 -1
  124. data/lib/stripe/params/issuing/credit_underwriting_record_correct_params.rb +163 -0
  125. data/lib/stripe/params/issuing/credit_underwriting_record_create_from_application_params.rb +50 -0
  126. data/lib/stripe/params/issuing/credit_underwriting_record_create_from_proactive_review_params.rb +128 -0
  127. data/lib/stripe/params/issuing/credit_underwriting_record_list_params.rb +24 -0
  128. data/lib/stripe/params/issuing/credit_underwriting_record_report_decision_params.rb +86 -0
  129. data/lib/stripe/params/issuing/credit_underwriting_record_retrieve_params.rb +15 -0
  130. data/lib/stripe/params/issuing/dispute_settlement_detail_list_params.rb +33 -0
  131. data/lib/stripe/params/issuing/dispute_settlement_detail_retrieve_params.rb +15 -0
  132. data/lib/stripe/params/issuing/fraud_liability_debit_list_params.rb +44 -0
  133. data/lib/stripe/params/issuing/fraud_liability_debit_retrieve_params.rb +15 -0
  134. data/lib/stripe/params/issuing/transaction_list_params.rb +4 -0
  135. data/lib/stripe/params/mandate_list_params.rb +39 -0
  136. data/lib/stripe/params/margin_create_params.rb +25 -0
  137. data/lib/stripe/params/margin_list_params.rb +25 -0
  138. data/lib/stripe/params/margin_retrieve_params.rb +13 -0
  139. data/lib/stripe/params/margin_update_params.rb +22 -0
  140. data/lib/stripe/params/order_cancel_params.rb +13 -0
  141. data/lib/stripe/params/order_create_params.rb +1124 -0
  142. data/lib/stripe/params/order_line_item_list_params.rb +22 -0
  143. data/lib/stripe/params/order_list_line_items_params.rb +22 -0
  144. data/lib/stripe/params/order_list_params.rb +25 -0
  145. data/lib/stripe/params/order_reopen_params.rb +13 -0
  146. data/lib/stripe/params/order_retrieve_params.rb +13 -0
  147. data/lib/stripe/params/order_submit_params.rb +16 -0
  148. data/lib/stripe/params/order_update_params.rb +1128 -0
  149. data/lib/stripe/params/payment_attempt_record_list_params.rb +19 -0
  150. data/lib/stripe/params/payment_attempt_record_retrieve_params.rb +13 -0
  151. data/lib/stripe/params/payment_intent_amount_details_line_item_list_params.rb +22 -0
  152. data/lib/stripe/params/payment_intent_capture_params.rb +895 -0
  153. data/lib/stripe/params/payment_intent_confirm_params.rb +1373 -7
  154. data/lib/stripe/params/payment_intent_create_params.rb +1387 -13
  155. data/lib/stripe/params/payment_intent_decrement_authorization_params.rb +73 -0
  156. data/lib/stripe/params/payment_intent_increment_authorization_params.rb +223 -0
  157. data/lib/stripe/params/payment_intent_list_params.rb +4 -0
  158. data/lib/stripe/params/payment_intent_trigger_action_params.rb +27 -0
  159. data/lib/stripe/params/payment_intent_update_params.rb +1409 -4
  160. data/lib/stripe/params/payment_method_attach_params.rb +4 -1
  161. data/lib/stripe/params/payment_method_configuration_create_params.rb +126 -0
  162. data/lib/stripe/params/payment_method_configuration_update_params.rb +126 -0
  163. data/lib/stripe/params/payment_method_create_params.rb +97 -0
  164. data/lib/stripe/params/payment_method_update_params.rb +19 -0
  165. data/lib/stripe/params/payment_record_report_payment_attempt_canceled_params.rb +19 -0
  166. data/lib/stripe/params/payment_record_report_payment_attempt_failed_params.rb +19 -0
  167. data/lib/stripe/params/payment_record_report_payment_attempt_guaranteed_params.rb +19 -0
  168. data/lib/stripe/params/payment_record_report_payment_attempt_informational_params.rb +93 -0
  169. data/lib/stripe/params/payment_record_report_payment_attempt_params.rb +186 -0
  170. data/lib/stripe/params/payment_record_report_payment_params.rb +252 -0
  171. data/lib/stripe/params/payment_record_retrieve_params.rb +13 -0
  172. data/lib/stripe/params/price_update_params.rb +19 -0
  173. data/lib/stripe/params/privacy/redaction_job_cancel_params.rb +15 -0
  174. data/lib/stripe/params/privacy/redaction_job_create_params.rb +67 -0
  175. data/lib/stripe/params/privacy/redaction_job_list_params.rb +27 -0
  176. data/lib/stripe/params/privacy/redaction_job_retrieve_params.rb +15 -0
  177. data/lib/stripe/params/privacy/redaction_job_run_params.rb +15 -0
  178. data/lib/stripe/params/privacy/redaction_job_update_params.rb +18 -0
  179. data/lib/stripe/params/privacy/redaction_job_validate_params.rb +15 -0
  180. data/lib/stripe/params/privacy/redaction_job_validation_error_list_params.rb +24 -0
  181. data/lib/stripe/params/promotion_code_create_params.rb +4 -0
  182. data/lib/stripe/params/promotion_code_list_params.rb +4 -0
  183. data/lib/stripe/params/quote_create_params.rb +805 -3
  184. data/lib/stripe/params/quote_line_list_params.rb +22 -0
  185. data/lib/stripe/params/quote_list_lines_params.rb +22 -0
  186. data/lib/stripe/params/quote_list_params.rb +8 -0
  187. data/lib/stripe/params/quote_list_preview_invoice_lines_params.rb +22 -0
  188. data/lib/stripe/params/quote_mark_draft_params.rb +13 -0
  189. data/lib/stripe/params/quote_mark_stale_params.rb +16 -0
  190. data/lib/stripe/params/quote_preview_invoice_list_params.rb +22 -0
  191. data/lib/stripe/params/quote_preview_subscription_schedule_list_params.rb +22 -0
  192. data/lib/stripe/params/quote_reestimate_params.rb +13 -0
  193. data/lib/stripe/params/quote_update_params.rb +813 -4
  194. data/lib/stripe/params/setup_intent_confirm_params.rb +225 -3
  195. data/lib/stripe/params/setup_intent_create_params.rb +231 -3
  196. data/lib/stripe/params/setup_intent_list_params.rb +4 -0
  197. data/lib/stripe/params/setup_intent_update_params.rb +231 -3
  198. data/lib/stripe/params/subscription_attach_cadence_params.rb +16 -0
  199. data/lib/stripe/params/subscription_create_params.rb +259 -5
  200. data/lib/stripe/params/subscription_item_create_params.rb +46 -2
  201. data/lib/stripe/params/subscription_item_update_params.rb +29 -1
  202. data/lib/stripe/params/subscription_list_params.rb +4 -0
  203. data/lib/stripe/params/subscription_schedule_amend_params.rb +570 -0
  204. data/lib/stripe/params/subscription_schedule_create_params.rb +167 -5
  205. data/lib/stripe/params/subscription_schedule_list_params.rb +4 -0
  206. data/lib/stripe/params/subscription_schedule_update_params.rb +163 -5
  207. data/lib/stripe/params/subscription_update_params.rb +238 -4
  208. data/lib/stripe/params/tax/association_find_params.rb +18 -0
  209. data/lib/stripe/params/tax/form_list_params.rb +51 -0
  210. data/lib/stripe/params/tax/form_pdf_params.rb +15 -0
  211. data/lib/stripe/params/tax/form_retrieve_params.rb +15 -0
  212. data/lib/stripe/params/tax_id_create_params.rb +4 -1
  213. data/lib/stripe/params/tax_id_list_params.rb +4 -1
  214. data/lib/stripe/params/terminal/configuration_create_params.rb +13 -0
  215. data/lib/stripe/params/terminal/configuration_update_params.rb +13 -0
  216. data/lib/stripe/params/terminal/onboarding_link_create_params.rb +43 -0
  217. data/lib/stripe/params/terminal/reader_collected_data_retrieve_params.rb +15 -0
  218. data/lib/stripe/params/test_helpers/confirmation_token_create_params.rb +97 -0
  219. data/lib/stripe/params/test_helpers/treasury/received_credit_create_params.rb +25 -1
  220. data/lib/stripe/params/test_helpers/treasury/received_debit_create_params.rb +25 -1
  221. data/lib/stripe/params/transfer_create_params.rb +4 -0
  222. data/lib/stripe/params/treasury/financial_account_create_params.rb +8 -1
  223. data/lib/stripe/params/treasury/financial_account_features_update_params.rb +4 -1
  224. data/lib/stripe/params/treasury/financial_account_update_features_params.rb +4 -1
  225. data/lib/stripe/params/treasury/financial_account_update_params.rb +8 -1
  226. data/lib/stripe/params/treasury/outbound_transfer_create_params.rb +24 -0
  227. data/lib/stripe/params/treasury/received_credit_create_params.rb +25 -1
  228. data/lib/stripe/params/treasury/received_debit_create_params.rb +25 -1
  229. data/lib/stripe/params/v2/billing/bill_setting_create_params.rb +74 -0
  230. data/lib/stripe/params/v2/billing/bill_setting_list_params.rb +21 -0
  231. data/lib/stripe/params/v2/billing/bill_setting_retrieve_params.rb +10 -0
  232. data/lib/stripe/params/v2/billing/bill_setting_update_params.rb +80 -0
  233. data/lib/stripe/params/v2/billing/bill_settings/version_list_params.rb +19 -0
  234. data/lib/stripe/params/v2/billing/bill_settings/version_retrieve_params.rb +12 -0
  235. data/lib/stripe/params/v2/billing/cadence_cancel_params.rb +10 -0
  236. data/lib/stripe/params/v2/billing/cadence_create_params.rb +253 -0
  237. data/lib/stripe/params/v2/billing/cadence_list_params.rb +43 -0
  238. data/lib/stripe/params/v2/billing/cadence_retrieve_params.rb +17 -0
  239. data/lib/stripe/params/v2/billing/cadence_update_params.rb +75 -0
  240. data/lib/stripe/params/v2/billing/collection_setting_create_params.rb +223 -0
  241. data/lib/stripe/params/v2/billing/collection_setting_list_params.rb +21 -0
  242. data/lib/stripe/params/v2/billing/collection_setting_retrieve_params.rb +10 -0
  243. data/lib/stripe/params/v2/billing/collection_setting_update_params.rb +229 -0
  244. data/lib/stripe/params/v2/billing/collection_settings/version_list_params.rb +19 -0
  245. data/lib/stripe/params/v2/billing/collection_settings/version_retrieve_params.rb +12 -0
  246. data/lib/stripe/params/v2/billing/profile_create_params.rb +37 -0
  247. data/lib/stripe/params/v2/billing/profile_list_params.rb +40 -0
  248. data/lib/stripe/params/v2/billing/profile_retrieve_params.rb +10 -0
  249. data/lib/stripe/params/v2/billing/profile_update_params.rb +35 -0
  250. data/lib/stripe/params/v2/core/account_close_params.rb +17 -0
  251. data/lib/stripe/params/v2/core/account_create_params.rb +2217 -0
  252. data/lib/stripe/params/v2/core/account_link_create_params.rb +101 -0
  253. data/lib/stripe/params/v2/core/account_list_params.rb +20 -0
  254. data/lib/stripe/params/v2/core/account_retrieve_params.rb +17 -0
  255. data/lib/stripe/params/v2/core/account_update_params.rb +2245 -0
  256. data/lib/stripe/params/v2/core/accounts/person_create_params.rb +493 -0
  257. data/lib/stripe/params/v2/core/accounts/person_delete_params.rb +12 -0
  258. data/lib/stripe/params/v2/core/accounts/person_list_params.rb +19 -0
  259. data/lib/stripe/params/v2/core/accounts/person_retrieve_params.rb +12 -0
  260. data/lib/stripe/params/v2/core/accounts/person_update_params.rb +493 -0
  261. data/lib/stripe/params/v2/core/vault/gb_bank_account_acknowledge_confirmation_of_payee_params.rb +12 -0
  262. data/lib/stripe/params/v2/core/vault/gb_bank_account_archive_params.rb +12 -0
  263. data/lib/stripe/params/v2/core/vault/gb_bank_account_create_params.rb +50 -0
  264. data/lib/stripe/params/v2/core/vault/gb_bank_account_initiate_confirmation_of_payee_params.rb +22 -0
  265. data/lib/stripe/params/v2/core/vault/gb_bank_account_retrieve_params.rb +12 -0
  266. data/lib/stripe/params/v2/core/vault/us_bank_account_archive_params.rb +12 -0
  267. data/lib/stripe/params/v2/core/vault/us_bank_account_create_params.rb +33 -0
  268. data/lib/stripe/params/v2/core/vault/us_bank_account_retrieve_params.rb +12 -0
  269. data/lib/stripe/params/v2/core/vault/us_bank_account_update_params.rb +22 -0
  270. data/lib/stripe/params/v2/money_management/adjustment_list_params.rb +48 -0
  271. data/lib/stripe/params/v2/money_management/adjustment_retrieve_params.rb +10 -0
  272. data/lib/stripe/params/v2/money_management/financial_account_close_params.rb +28 -0
  273. data/lib/stripe/params/v2/money_management/financial_account_create_params.rb +34 -0
  274. data/lib/stripe/params/v2/money_management/financial_account_list_params.rb +20 -0
  275. data/lib/stripe/params/v2/money_management/financial_account_retrieve_params.rb +10 -0
  276. data/lib/stripe/params/v2/money_management/financial_address_create_params.rb +20 -0
  277. data/lib/stripe/params/v2/money_management/financial_address_list_params.rb +23 -0
  278. data/lib/stripe/params/v2/money_management/financial_address_retrieve_params.rb +17 -0
  279. data/lib/stripe/params/v2/money_management/inbound_transfer_create_params.rb +50 -0
  280. data/lib/stripe/params/v2/money_management/inbound_transfer_list_params.rb +44 -0
  281. data/lib/stripe/params/v2/money_management/inbound_transfer_retrieve_params.rb +10 -0
  282. data/lib/stripe/params/v2/money_management/outbound_payment_cancel_params.rb +10 -0
  283. data/lib/stripe/params/v2/money_management/outbound_payment_create_params.rb +98 -0
  284. data/lib/stripe/params/v2/money_management/outbound_payment_list_params.rb +52 -0
  285. data/lib/stripe/params/v2/money_management/outbound_payment_quote_create_params.rb +67 -0
  286. data/lib/stripe/params/v2/money_management/outbound_payment_quote_retrieve_params.rb +10 -0
  287. data/lib/stripe/params/v2/money_management/outbound_payment_retrieve_params.rb +10 -0
  288. data/lib/stripe/params/v2/money_management/outbound_setup_intent_cancel_params.rb +10 -0
  289. data/lib/stripe/params/v2/money_management/outbound_setup_intent_create_params.rb +85 -0
  290. data/lib/stripe/params/v2/money_management/outbound_setup_intent_list_params.rb +17 -0
  291. data/lib/stripe/params/v2/money_management/outbound_setup_intent_retrieve_params.rb +10 -0
  292. data/lib/stripe/params/v2/money_management/outbound_setup_intent_update_params.rb +80 -0
  293. data/lib/stripe/params/v2/money_management/outbound_transfer_cancel_params.rb +10 -0
  294. data/lib/stripe/params/v2/money_management/outbound_transfer_create_params.rb +77 -0
  295. data/lib/stripe/params/v2/money_management/outbound_transfer_list_params.rb +48 -0
  296. data/lib/stripe/params/v2/money_management/outbound_transfer_retrieve_params.rb +10 -0
  297. data/lib/stripe/params/v2/money_management/payout_method_archive_params.rb +10 -0
  298. data/lib/stripe/params/v2/money_management/payout_method_list_params.rb +31 -0
  299. data/lib/stripe/params/v2/money_management/payout_method_retrieve_params.rb +10 -0
  300. data/lib/stripe/params/v2/money_management/payout_method_unarchive_params.rb +10 -0
  301. data/lib/stripe/params/v2/money_management/payout_methods_bank_account_spec_retrieve_params.rb +17 -0
  302. data/lib/stripe/params/v2/money_management/received_credit_list_params.rb +44 -0
  303. data/lib/stripe/params/v2/money_management/received_credit_retrieve_params.rb +10 -0
  304. data/lib/stripe/params/v2/money_management/received_debit_list_params.rb +17 -0
  305. data/lib/stripe/params/v2/money_management/received_debit_retrieve_params.rb +10 -0
  306. data/lib/stripe/params/v2/money_management/transaction_entry_list_params.rb +43 -0
  307. data/lib/stripe/params/v2/money_management/transaction_entry_retrieve_params.rb +10 -0
  308. data/lib/stripe/params/v2/money_management/transaction_list_params.rb +47 -0
  309. data/lib/stripe/params/v2/money_management/transaction_retrieve_params.rb +10 -0
  310. data/lib/stripe/params/v2/payments/off_session_payment_cancel_params.rb +10 -0
  311. data/lib/stripe/params/v2/payments/off_session_payment_capture_params.rb +61 -0
  312. data/lib/stripe/params/v2/payments/off_session_payment_create_params.rb +237 -0
  313. data/lib/stripe/params/v2/payments/off_session_payment_list_params.rb +17 -0
  314. data/lib/stripe/params/v2/payments/off_session_payment_retrieve_params.rb +10 -0
  315. data/lib/stripe/params/v2/test_helpers/financial_address_credit_params.rb +23 -0
  316. data/lib/stripe/params/v2/test_helpers/financial_address_generate_microdeposits_params.rb +10 -0
  317. data/lib/stripe/params.rb +169 -0
  318. data/lib/stripe/resources/account.rb +166 -1
  319. data/lib/stripe/resources/account_notice.rb +94 -0
  320. data/lib/stripe/resources/account_session.rb +81 -0
  321. data/lib/stripe/resources/billing/analytics/meter_usage.rb +33 -0
  322. data/lib/stripe/resources/billing/analytics/meter_usage_row.rb +38 -0
  323. data/lib/stripe/resources/billing/credit_balance_summary.rb +2 -0
  324. data/lib/stripe/resources/billing/credit_grant.rb +2 -0
  325. data/lib/stripe/resources/billing_portal/session.rb +2 -0
  326. data/lib/stripe/resources/capital/financing_offer.rb +142 -0
  327. data/lib/stripe/resources/capital/financing_summary.rb +79 -0
  328. data/lib/stripe/resources/capital/financing_transaction.rb +99 -0
  329. data/lib/stripe/resources/card.rb +2 -0
  330. data/lib/stripe/resources/cash_balance.rb +2 -0
  331. data/lib/stripe/resources/charge.rb +234 -1
  332. data/lib/stripe/resources/checkout/session.rb +154 -4
  333. data/lib/stripe/resources/confirmation_token.rb +155 -0
  334. data/lib/stripe/resources/coupon.rb +26 -1
  335. data/lib/stripe/resources/credit_note.rb +2 -0
  336. data/lib/stripe/resources/credit_note_line_item.rb +18 -0
  337. data/lib/stripe/resources/customer.rb +2 -0
  338. data/lib/stripe/resources/customer_balance_transaction.rb +2 -0
  339. data/lib/stripe/resources/customer_cash_balance_transaction.rb +2 -0
  340. data/lib/stripe/resources/customer_session.rb +2 -0
  341. data/lib/stripe/resources/discount.rb +2 -0
  342. data/lib/stripe/resources/dispute.rb +22 -0
  343. data/lib/stripe/resources/event.rb +64 -1
  344. data/lib/stripe/resources/financial_connections/account.rb +27 -0
  345. data/lib/stripe/resources/financial_connections/account_inferred_balance.rb +35 -0
  346. data/lib/stripe/resources/financial_connections/institution.rb +127 -0
  347. data/lib/stripe/resources/financial_connections/session.rb +67 -1
  348. data/lib/stripe/resources/fx_quote.rb +147 -0
  349. data/lib/stripe/resources/identity/verification_session.rb +2 -0
  350. data/lib/stripe/resources/invoice.rb +152 -1
  351. data/lib/stripe/resources/invoice_item.rb +4 -0
  352. data/lib/stripe/resources/invoice_line_item.rb +40 -0
  353. data/lib/stripe/resources/invoice_payment.rb +2 -0
  354. data/lib/stripe/resources/issuing/credit_underwriting_record.rb +263 -0
  355. data/lib/stripe/resources/issuing/dispute_settlement_detail.rb +71 -0
  356. data/lib/stripe/resources/issuing/fraud_liability_debit.rb +51 -0
  357. data/lib/stripe/resources/issuing/settlement.rb +61 -0
  358. data/lib/stripe/resources/issuing/transaction.rb +2 -0
  359. data/lib/stripe/resources/line_item.rb +68 -1
  360. data/lib/stripe/resources/mandate.rb +71 -0
  361. data/lib/stripe/resources/margin.rb +64 -0
  362. data/lib/stripe/resources/order.rb +987 -0
  363. data/lib/stripe/resources/payment_attempt_record.rb +2102 -0
  364. data/lib/stripe/resources/payment_intent.rb +848 -4
  365. data/lib/stripe/resources/payment_intent_amount_details_line_item.rb +128 -0
  366. data/lib/stripe/resources/payment_method.rb +157 -0
  367. data/lib/stripe/resources/payment_method_configuration.rb +204 -0
  368. data/lib/stripe/resources/payment_record.rb +2208 -0
  369. data/lib/stripe/resources/price.rb +20 -0
  370. data/lib/stripe/resources/privacy/redaction_job.rb +187 -0
  371. data/lib/stripe/resources/privacy/redaction_job_validation_error.rb +49 -0
  372. data/lib/stripe/resources/promotion_code.rb +2 -0
  373. data/lib/stripe/resources/quote.rb +571 -2
  374. data/lib/stripe/resources/quote_line.rb +521 -0
  375. data/lib/stripe/resources/quote_preview_invoice.rb +1150 -0
  376. data/lib/stripe/resources/quote_preview_subscription_schedule.rb +732 -0
  377. data/lib/stripe/resources/refund.rb +18 -0
  378. data/lib/stripe/resources/setup_attempt.rb +63 -0
  379. data/lib/stripe/resources/setup_intent.rb +132 -1
  380. data/lib/stripe/resources/source.rb +38 -0
  381. data/lib/stripe/resources/subscription.rb +232 -0
  382. data/lib/stripe/resources/subscription_item.rb +20 -1
  383. data/lib/stripe/resources/subscription_schedule.rb +198 -3
  384. data/lib/stripe/resources/tax/association.rb +86 -0
  385. data/lib/stripe/resources/tax/form.rb +264 -0
  386. data/lib/stripe/resources/tax_id.rb +4 -0
  387. data/lib/stripe/resources/terminal/configuration.rb +16 -0
  388. data/lib/stripe/resources/terminal/onboarding_link.rb +71 -0
  389. data/lib/stripe/resources/terminal/reader.rb +8 -0
  390. data/lib/stripe/resources/terminal/reader_collected_data.rb +47 -0
  391. data/lib/stripe/resources/transfer.rb +2 -0
  392. data/lib/stripe/resources/treasury/financial_account.rb +2 -0
  393. data/lib/stripe/resources/treasury/financial_account_features.rb +2 -0
  394. data/lib/stripe/resources/treasury/outbound_transfer.rb +30 -0
  395. data/lib/stripe/resources/treasury/received_credit.rb +30 -0
  396. data/lib/stripe/resources/treasury/received_debit.rb +32 -0
  397. data/lib/stripe/resources/v2/billing/bill_setting.rb +102 -0
  398. data/lib/stripe/resources/v2/billing/bill_setting_version.rb +90 -0
  399. data/lib/stripe/resources/v2/billing/cadence.rb +609 -0
  400. data/lib/stripe/resources/v2/billing/collection_setting.rb +274 -0
  401. data/lib/stripe/resources/v2/billing/collection_setting_version.rb +262 -0
  402. data/lib/stripe/resources/v2/billing/profile.rb +46 -0
  403. data/lib/stripe/resources/v2/core/account.rb +3851 -0
  404. data/lib/stripe/resources/v2/core/account_link.rb +123 -0
  405. data/lib/stripe/resources/v2/core/account_person.rb +477 -0
  406. data/lib/stripe/resources/v2/core/vault/gb_bank_account.rb +114 -0
  407. data/lib/stripe/resources/v2/core/vault/us_bank_account.rb +47 -0
  408. data/lib/stripe/resources/v2/financial_address_credit_simulation.rb +28 -0
  409. data/lib/stripe/resources/v2/financial_address_generated_microdeposits.rb +30 -0
  410. data/lib/stripe/resources/v2/money_management/adjustment.rb +67 -0
  411. data/lib/stripe/resources/v2/money_management/financial_account.rb +140 -0
  412. data/lib/stripe/resources/v2/money_management/financial_address.rb +132 -0
  413. data/lib/stripe/resources/v2/money_management/inbound_transfer.rb +148 -0
  414. data/lib/stripe/resources/v2/money_management/outbound_payment.rb +217 -0
  415. data/lib/stripe/resources/v2/money_management/outbound_payment_quote.rb +144 -0
  416. data/lib/stripe/resources/v2/money_management/outbound_setup_intent.rb +69 -0
  417. data/lib/stripe/resources/v2/money_management/outbound_transfer.rb +196 -0
  418. data/lib/stripe/resources/v2/money_management/payout_method.rb +109 -0
  419. data/lib/stripe/resources/v2/money_management/payout_methods_bank_account_spec.rb +81 -0
  420. data/lib/stripe/resources/v2/money_management/received_credit.rb +228 -0
  421. data/lib/stripe/resources/v2/money_management/received_debit.rb +136 -0
  422. data/lib/stripe/resources/v2/money_management/transaction.rb +116 -0
  423. data/lib/stripe/resources/v2/money_management/transaction_entry.rb +105 -0
  424. data/lib/stripe/resources/v2/payments/off_session_payment.rb +242 -0
  425. data/lib/stripe/resources.rb +116 -0
  426. data/lib/stripe/services/account_notice_service.rb +39 -0
  427. data/lib/stripe/services/billing/analytics/meter_usage_service.rb +21 -0
  428. data/lib/stripe/services/billing/analytics_service.rb +15 -0
  429. data/lib/stripe/services/billing_service.rb +2 -1
  430. data/lib/stripe/services/capital/financing_offer_service.rb +42 -0
  431. data/lib/stripe/services/capital/financing_summary_service.rb +19 -0
  432. data/lib/stripe/services/capital/financing_transaction_service.rb +31 -0
  433. data/lib/stripe/services/capital_service.rb +15 -0
  434. data/lib/stripe/services/external_account_service.rb +68 -0
  435. data/lib/stripe/services/financial_connections/account_inferred_balance_service.rb +19 -0
  436. data/lib/stripe/services/financial_connections/account_service.rb +3 -1
  437. data/lib/stripe/services/financial_connections/institution_service.rb +30 -0
  438. data/lib/stripe/services/financial_connections_service.rb +2 -1
  439. data/lib/stripe/services/fx_quote_service.rb +27 -0
  440. data/lib/stripe/services/issuing/credit_underwriting_record_service.rb +74 -0
  441. data/lib/stripe/services/issuing/dispute_settlement_detail_service.rb +30 -0
  442. data/lib/stripe/services/issuing/fraud_liability_debit_service.rb +30 -0
  443. data/lib/stripe/services/issuing_service.rb +5 -1
  444. data/lib/stripe/services/mandate_service.rb +5 -0
  445. data/lib/stripe/services/margin_service.rb +50 -0
  446. data/lib/stripe/services/order_line_item_service.rb +17 -0
  447. data/lib/stripe/services/order_service.rb +78 -0
  448. data/lib/stripe/services/payment_attempt_record_service.rb +28 -0
  449. data/lib/stripe/services/payment_intent_amount_details_line_item_service.rb +17 -0
  450. data/lib/stripe/services/payment_intent_service.rb +44 -0
  451. data/lib/stripe/services/payment_record_service.rb +89 -0
  452. data/lib/stripe/services/privacy/redaction_job_service.rb +104 -0
  453. data/lib/stripe/services/privacy/redaction_job_validation_error_service.rb +19 -0
  454. data/lib/stripe/services/privacy_service.rb +13 -0
  455. data/lib/stripe/services/quote_line_service.rb +17 -0
  456. data/lib/stripe/services/quote_preview_invoice_service.rb +17 -0
  457. data/lib/stripe/services/quote_preview_subscription_schedule_service.rb +17 -0
  458. data/lib/stripe/services/quote_service.rb +49 -1
  459. data/lib/stripe/services/subscription_schedule_service.rb +11 -0
  460. data/lib/stripe/services/subscription_service.rb +11 -0
  461. data/lib/stripe/services/tax/association_service.rb +19 -0
  462. data/lib/stripe/services/tax/form_service.rb +37 -0
  463. data/lib/stripe/services/tax_service.rb +3 -1
  464. data/lib/stripe/services/terminal/onboarding_link_service.rb +19 -0
  465. data/lib/stripe/services/terminal/reader_collected_data_service.rb +19 -0
  466. data/lib/stripe/services/terminal_service.rb +3 -1
  467. data/lib/stripe/services/v1_services.rb +10 -1
  468. data/lib/stripe/services/v2/billing/bill_setting_service.rb +61 -0
  469. data/lib/stripe/services/v2/billing/bill_settings/version_service.rb +34 -0
  470. data/lib/stripe/services/v2/billing/cadence_service.rb +65 -0
  471. data/lib/stripe/services/v2/billing/collection_setting_service.rb +61 -0
  472. data/lib/stripe/services/v2/billing/collection_settings/version_service.rb +34 -0
  473. data/lib/stripe/services/v2/billing/profile_service.rb +54 -0
  474. data/lib/stripe/services/v2/billing_service.rb +5 -1
  475. data/lib/stripe/services/v2/core/account_link_service.rb +21 -0
  476. data/lib/stripe/services/v2/core/account_service.rb +76 -0
  477. data/lib/stripe/services/v2/core/accounts/person_service.rb +67 -0
  478. data/lib/stripe/services/v2/core/vault/gb_bank_account_service.rb +74 -0
  479. data/lib/stripe/services/v2/core/vault/us_bank_account_service.rb +68 -0
  480. data/lib/stripe/services/v2/core/vault_service.rb +18 -0
  481. data/lib/stripe/services/v2/core_service.rb +4 -1
  482. data/lib/stripe/services/v2/money_management/adjustment_service.rb +32 -0
  483. data/lib/stripe/services/v2/money_management/financial_account_service.rb +59 -0
  484. data/lib/stripe/services/v2/money_management/financial_address_service.rb +46 -0
  485. data/lib/stripe/services/v2/money_management/inbound_transfer_service.rb +45 -0
  486. data/lib/stripe/services/v2/money_management/outbound_payment_quote_service.rb +34 -0
  487. data/lib/stripe/services/v2/money_management/outbound_payment_service.rb +62 -0
  488. data/lib/stripe/services/v2/money_management/outbound_setup_intent_service.rb +73 -0
  489. data/lib/stripe/services/v2/money_management/outbound_transfer_service.rb +60 -0
  490. data/lib/stripe/services/v2/money_management/payout_method_service.rb +63 -0
  491. data/lib/stripe/services/v2/money_management/payout_methods_bank_account_spec_service.rb +23 -0
  492. data/lib/stripe/services/v2/money_management/received_credit_service.rb +32 -0
  493. data/lib/stripe/services/v2/money_management/received_debit_service.rb +32 -0
  494. data/lib/stripe/services/v2/money_management/transaction_entry_service.rb +32 -0
  495. data/lib/stripe/services/v2/money_management/transaction_service.rb +32 -0
  496. data/lib/stripe/services/v2/money_management_service.rb +31 -0
  497. data/lib/stripe/services/v2/payment_service.rb +15 -0
  498. data/lib/stripe/services/v2/payments/off_session_payment_service.rb +65 -0
  499. data/lib/stripe/services/v2/test_helper_service.rb +15 -0
  500. data/lib/stripe/services/v2/test_helpers/financial_address_service.rb +36 -0
  501. data/lib/stripe/services/v2_services.rb +4 -1
  502. data/lib/stripe/services.rb +61 -0
  503. data/lib/stripe/stripe_configuration.rb +3 -1
  504. data/lib/stripe/stripe_object.rb +1 -1
  505. data/lib/stripe/util.rb +7 -1
  506. data/lib/stripe/version.rb +1 -1
  507. data/lib/stripe.rb +53 -0
  508. data/rbi/stripe.rbi +155102 -90522
  509. metadata +349 -3
@@ -0,0 +1,1128 @@
1
+ # File generated from our OpenAPI spec
2
+ # frozen_string_literal: true
3
+
4
+ module Stripe
5
+ class OrderUpdateParams < Stripe::RequestParams
6
+ class AutomaticTax < Stripe::RequestParams
7
+ # Enable automatic tax calculation which will automatically compute tax rates on this order.
8
+ attr_accessor :enabled
9
+
10
+ def initialize(enabled: nil)
11
+ @enabled = enabled
12
+ end
13
+ end
14
+
15
+ class BillingDetails < Stripe::RequestParams
16
+ class Address < Stripe::RequestParams
17
+ # City, district, suburb, town, or village.
18
+ attr_accessor :city
19
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
20
+ attr_accessor :country
21
+ # Address line 1, such as the street, PO Box, or company name.
22
+ attr_accessor :line1
23
+ # Address line 2, such as the apartment, suite, unit, or building.
24
+ attr_accessor :line2
25
+ # ZIP or postal code.
26
+ attr_accessor :postal_code
27
+ # State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
28
+ attr_accessor :state
29
+
30
+ def initialize(
31
+ city: nil,
32
+ country: nil,
33
+ line1: nil,
34
+ line2: nil,
35
+ postal_code: nil,
36
+ state: nil
37
+ )
38
+ @city = city
39
+ @country = country
40
+ @line1 = line1
41
+ @line2 = line2
42
+ @postal_code = postal_code
43
+ @state = state
44
+ end
45
+ end
46
+ # The billing address provided by the customer.
47
+ attr_accessor :address
48
+ # The billing email provided by the customer.
49
+ attr_accessor :email
50
+ # The billing name provided by the customer.
51
+ attr_accessor :name
52
+ # The billing phone number provided by the customer.
53
+ attr_accessor :phone
54
+
55
+ def initialize(address: nil, email: nil, name: nil, phone: nil)
56
+ @address = address
57
+ @email = email
58
+ @name = name
59
+ @phone = phone
60
+ end
61
+ end
62
+
63
+ class Discount < Stripe::RequestParams
64
+ # ID of the coupon to create a new discount for.
65
+ attr_accessor :coupon
66
+ # ID of an existing discount on the object (or one of its ancestors) to reuse.
67
+ attr_accessor :discount
68
+ # ID of the promotion code to create a new discount for.
69
+ attr_accessor :promotion_code
70
+
71
+ def initialize(coupon: nil, discount: nil, promotion_code: nil)
72
+ @coupon = coupon
73
+ @discount = discount
74
+ @promotion_code = promotion_code
75
+ end
76
+ end
77
+
78
+ class LineItem < Stripe::RequestParams
79
+ class Discount < Stripe::RequestParams
80
+ # ID of the coupon to create a new discount for.
81
+ attr_accessor :coupon
82
+ # ID of an existing discount on the object (or one of its ancestors) to reuse.
83
+ attr_accessor :discount
84
+
85
+ def initialize(coupon: nil, discount: nil)
86
+ @coupon = coupon
87
+ @discount = discount
88
+ end
89
+ end
90
+
91
+ class PriceData < Stripe::RequestParams
92
+ # 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).
93
+ attr_accessor :currency
94
+ # ID of the [Product](https://docs.stripe.com/api/products) this [Price](https://docs.stripe.com/api/prices) belongs to.
95
+ #
96
+ # Use this to implement a variable-pricing model in your integration. This is required if `product_data` is not specified.
97
+ attr_accessor :product
98
+ # 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.
99
+ attr_accessor :tax_behavior
100
+ # A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
101
+ attr_accessor :unit_amount
102
+ # 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.
103
+ attr_accessor :unit_amount_decimal
104
+
105
+ def initialize(
106
+ currency: nil,
107
+ product: nil,
108
+ tax_behavior: nil,
109
+ unit_amount: nil,
110
+ unit_amount_decimal: nil
111
+ )
112
+ @currency = currency
113
+ @product = product
114
+ @tax_behavior = tax_behavior
115
+ @unit_amount = unit_amount
116
+ @unit_amount_decimal = unit_amount_decimal
117
+ end
118
+ end
119
+
120
+ class ProductData < Stripe::RequestParams
121
+ class PackageDimensions < Stripe::RequestParams
122
+ # Height, in inches. Maximum precision is 2 decimal places.
123
+ attr_accessor :height
124
+ # Length, in inches. Maximum precision is 2 decimal places.
125
+ attr_accessor :length
126
+ # Weight, in ounces. Maximum precision is 2 decimal places.
127
+ attr_accessor :weight
128
+ # Width, in inches. Maximum precision is 2 decimal places.
129
+ attr_accessor :width
130
+
131
+ def initialize(height: nil, length: nil, weight: nil, width: nil)
132
+ @height = height
133
+ @length = length
134
+ @weight = weight
135
+ @width = width
136
+ end
137
+ end
138
+ # 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.
139
+ attr_accessor :description
140
+ # A unique identifier for this product.
141
+ #
142
+ # `product_data` automatically creates a Product with this ID. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates. If any of the fields in the existing Product are different from the values in `product_data`, `product_data` updates the existing Product with the new information. So set `product_data[id]` to the same string every time you sell the same product, but don't re-use the same string for different products.
143
+ attr_accessor :id
144
+ # A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
145
+ attr_accessor :images
146
+ # 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`.
147
+ attr_accessor :metadata
148
+ # The product's name, meant to be displayable to the customer.
149
+ attr_accessor :name
150
+ # The dimensions of this product for shipping purposes.
151
+ attr_accessor :package_dimensions
152
+ # Whether this product is shipped (i.e., physical goods).
153
+ attr_accessor :shippable
154
+ # A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
155
+ attr_accessor :tax_code
156
+ # A URL of a publicly-accessible webpage for this product.
157
+ attr_accessor :url
158
+
159
+ def initialize(
160
+ description: nil,
161
+ id: nil,
162
+ images: nil,
163
+ metadata: nil,
164
+ name: nil,
165
+ package_dimensions: nil,
166
+ shippable: nil,
167
+ tax_code: nil,
168
+ url: nil
169
+ )
170
+ @description = description
171
+ @id = id
172
+ @images = images
173
+ @metadata = metadata
174
+ @name = name
175
+ @package_dimensions = package_dimensions
176
+ @shippable = shippable
177
+ @tax_code = tax_code
178
+ @url = url
179
+ end
180
+ end
181
+ # The description for the line item. Will default to the name of the associated product.
182
+ attr_accessor :description
183
+ # The discounts applied to this line item.
184
+ attr_accessor :discounts
185
+ # The ID of an existing line item on the order.
186
+ attr_accessor :id
187
+ # The ID of a [Price](https://docs.stripe.com/api/prices) to add to the Order.
188
+ #
189
+ # The `price` parameter is an alternative to using the `product` parameter. If each of your products are sold at a single price, you can set `Product.default_price` and then pass the `product` parameter when creating a line item. If your products are sold at several possible prices, use the `price` parameter to explicitly specify which one to use.
190
+ attr_accessor :price
191
+ # Data used to generate a new Price object inline.
192
+ #
193
+ # The `price_data` parameter is an alternative to using the `product` or `price` parameters. If you create a Product upfront and configure a `Product.default_price`, pass the `product` parameter when creating a line item. If you prefer not to define Products upfront, or if you charge variable prices, pass the `price_data` parameter to describe the price for this line item.
194
+ #
195
+ # Each time you pass `price_data` we create a Price for the Product. This Price is hidden in both the Dashboard and API lists and cannot be reused.
196
+ attr_accessor :price_data
197
+ # The ID of a [Product](https://docs.stripe.com/api/products) to add to the Order.
198
+ #
199
+ # The Product must have a `default_price` specified. Otherwise, specify the price by passing the `price` or `price_data` parameter.
200
+ attr_accessor :product
201
+ # Defines a [Product](https://docs.stripe.com/api/products) inline and adds it to the Order.
202
+ #
203
+ # `product_data` is an alternative to the `product` parameter. If you created a Product upfront, use the `product` parameter to refer to the existing Product. But if you prefer not to create Products upfront, pass the `product_data` parameter to define a Product inline as part of configuring the Order.
204
+ #
205
+ # `product_data` automatically creates a Product, just as if you had manually created the Product. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates.
206
+ attr_accessor :product_data
207
+ # The quantity of the line item.
208
+ attr_accessor :quantity
209
+ # The tax rates applied to this line item.
210
+ attr_accessor :tax_rates
211
+
212
+ def initialize(
213
+ description: nil,
214
+ discounts: nil,
215
+ id: nil,
216
+ price: nil,
217
+ price_data: nil,
218
+ product: nil,
219
+ product_data: nil,
220
+ quantity: nil,
221
+ tax_rates: nil
222
+ )
223
+ @description = description
224
+ @discounts = discounts
225
+ @id = id
226
+ @price = price
227
+ @price_data = price_data
228
+ @product = product
229
+ @product_data = product_data
230
+ @quantity = quantity
231
+ @tax_rates = tax_rates
232
+ end
233
+ end
234
+
235
+ class Payment < Stripe::RequestParams
236
+ class Settings < Stripe::RequestParams
237
+ class PaymentMethodOptions < Stripe::RequestParams
238
+ class AcssDebit < Stripe::RequestParams
239
+ class MandateOptions < Stripe::RequestParams
240
+ # A URL for custom mandate text to render during confirmation step.
241
+ # The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
242
+ # or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
243
+ attr_accessor :custom_mandate_url
244
+ # Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
245
+ attr_accessor :interval_description
246
+ # Payment schedule for the mandate.
247
+ attr_accessor :payment_schedule
248
+ # Transaction type of the mandate.
249
+ attr_accessor :transaction_type
250
+
251
+ def initialize(
252
+ custom_mandate_url: nil,
253
+ interval_description: nil,
254
+ payment_schedule: nil,
255
+ transaction_type: nil
256
+ )
257
+ @custom_mandate_url = custom_mandate_url
258
+ @interval_description = interval_description
259
+ @payment_schedule = payment_schedule
260
+ @transaction_type = transaction_type
261
+ end
262
+ end
263
+ # Additional fields for Mandate creation
264
+ attr_accessor :mandate_options
265
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
266
+ #
267
+ # 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.
268
+ #
269
+ # 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.
270
+ #
271
+ # 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).
272
+ #
273
+ # 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`.
274
+ attr_accessor :setup_future_usage
275
+ # Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
276
+ attr_accessor :target_date
277
+ # Bank account verification method.
278
+ attr_accessor :verification_method
279
+
280
+ def initialize(
281
+ mandate_options: nil,
282
+ setup_future_usage: nil,
283
+ target_date: nil,
284
+ verification_method: nil
285
+ )
286
+ @mandate_options = mandate_options
287
+ @setup_future_usage = setup_future_usage
288
+ @target_date = target_date
289
+ @verification_method = verification_method
290
+ end
291
+ end
292
+
293
+ class AfterpayClearpay < Stripe::RequestParams
294
+ # Controls when the funds are captured from the customer's account.
295
+ #
296
+ # If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
297
+ #
298
+ # If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
299
+ attr_accessor :capture_method
300
+ # An internal identifier or reference this payment corresponds to. The identifier is limited to 128 characters and may contain only letters, digits, underscores, backslashes and dashes.
301
+ attr_accessor :reference
302
+ # Indicates that you intend to make future payments with the payment method.
303
+ #
304
+ # Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
305
+ #
306
+ # When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
307
+ #
308
+ # If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
309
+ attr_accessor :setup_future_usage
310
+
311
+ def initialize(capture_method: nil, reference: nil, setup_future_usage: nil)
312
+ @capture_method = capture_method
313
+ @reference = reference
314
+ @setup_future_usage = setup_future_usage
315
+ end
316
+ end
317
+
318
+ class Alipay < Stripe::RequestParams
319
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
320
+ #
321
+ # 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.
322
+ #
323
+ # 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.
324
+ #
325
+ # 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).
326
+ #
327
+ # 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`.
328
+ attr_accessor :setup_future_usage
329
+
330
+ def initialize(setup_future_usage: nil)
331
+ @setup_future_usage = setup_future_usage
332
+ end
333
+ end
334
+
335
+ class Bancontact < Stripe::RequestParams
336
+ # Preferred language of the Bancontact authorization page that the customer is redirected to.
337
+ attr_accessor :preferred_language
338
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
339
+ #
340
+ # 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.
341
+ #
342
+ # 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.
343
+ #
344
+ # 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).
345
+ #
346
+ # 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`.
347
+ attr_accessor :setup_future_usage
348
+
349
+ def initialize(preferred_language: nil, setup_future_usage: nil)
350
+ @preferred_language = preferred_language
351
+ @setup_future_usage = setup_future_usage
352
+ end
353
+ end
354
+
355
+ class Card < Stripe::RequestParams
356
+ # Controls when the funds will be captured from the customer's account.
357
+ attr_accessor :capture_method
358
+ # Indicates that you intend to make future payments with the payment method.
359
+ #
360
+ # Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
361
+ #
362
+ # When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
363
+ #
364
+ # If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
365
+ attr_accessor :setup_future_usage
366
+
367
+ def initialize(capture_method: nil, setup_future_usage: nil)
368
+ @capture_method = capture_method
369
+ @setup_future_usage = setup_future_usage
370
+ end
371
+ end
372
+
373
+ class CustomerBalance < Stripe::RequestParams
374
+ class BankTransfer < Stripe::RequestParams
375
+ class EuBankTransfer < Stripe::RequestParams
376
+ # The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
377
+ attr_accessor :country
378
+
379
+ def initialize(country: nil)
380
+ @country = country
381
+ end
382
+ end
383
+ # Configuration for the eu_bank_transfer funding type.
384
+ attr_accessor :eu_bank_transfer
385
+ # List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
386
+ #
387
+ # Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
388
+ attr_accessor :requested_address_types
389
+ # The list of bank transfer types 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`.
390
+ attr_accessor :type
391
+
392
+ def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil)
393
+ @eu_bank_transfer = eu_bank_transfer
394
+ @requested_address_types = requested_address_types
395
+ @type = type
396
+ end
397
+ end
398
+ # Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
399
+ attr_accessor :bank_transfer
400
+ # The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
401
+ attr_accessor :funding_type
402
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
403
+ #
404
+ # 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.
405
+ #
406
+ # 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.
407
+ #
408
+ # 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).
409
+ #
410
+ # 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`.
411
+ attr_accessor :setup_future_usage
412
+
413
+ def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil)
414
+ @bank_transfer = bank_transfer
415
+ @funding_type = funding_type
416
+ @setup_future_usage = setup_future_usage
417
+ end
418
+ end
419
+
420
+ class Ideal < Stripe::RequestParams
421
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
422
+ #
423
+ # 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.
424
+ #
425
+ # 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.
426
+ #
427
+ # 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).
428
+ #
429
+ # 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`.
430
+ attr_accessor :setup_future_usage
431
+
432
+ def initialize(setup_future_usage: nil)
433
+ @setup_future_usage = setup_future_usage
434
+ end
435
+ end
436
+
437
+ class Klarna < Stripe::RequestParams
438
+ class OnDemand < Stripe::RequestParams
439
+ # Your average amount value. You can use a value across your customer base, or segment based on customer type, country, etc.
440
+ attr_accessor :average_amount
441
+ # The maximum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
442
+ attr_accessor :maximum_amount
443
+ # The lowest or minimum value you may charge a customer per purchase. You can use a value across your customer base, or segment based on customer type, country, etc.
444
+ attr_accessor :minimum_amount
445
+ # Interval at which the customer is making purchases
446
+ attr_accessor :purchase_interval
447
+ # The number of `purchase_interval` between charges
448
+ attr_accessor :purchase_interval_count
449
+
450
+ def initialize(
451
+ average_amount: nil,
452
+ maximum_amount: nil,
453
+ minimum_amount: nil,
454
+ purchase_interval: nil,
455
+ purchase_interval_count: nil
456
+ )
457
+ @average_amount = average_amount
458
+ @maximum_amount = maximum_amount
459
+ @minimum_amount = minimum_amount
460
+ @purchase_interval = purchase_interval
461
+ @purchase_interval_count = purchase_interval_count
462
+ end
463
+ end
464
+
465
+ class Subscription < Stripe::RequestParams
466
+ class NextBilling < Stripe::RequestParams
467
+ # The amount of the next charge for the subscription.
468
+ attr_accessor :amount
469
+ # The date of the next charge for the subscription in YYYY-MM-DD format.
470
+ attr_accessor :date
471
+
472
+ def initialize(amount: nil, date: nil)
473
+ @amount = amount
474
+ @date = date
475
+ end
476
+ end
477
+ # Unit of time between subscription charges.
478
+ attr_accessor :interval
479
+ # The number of intervals (specified in the `interval` attribute) between subscription charges. For example, `interval=month` and `interval_count=3` charges every 3 months.
480
+ attr_accessor :interval_count
481
+ # Name for subscription.
482
+ attr_accessor :name
483
+ # Describes the upcoming charge for this subscription.
484
+ attr_accessor :next_billing
485
+ # A non-customer-facing reference to correlate subscription charges in the Klarna app. Use a value that persists across subscription charges.
486
+ attr_accessor :reference
487
+
488
+ def initialize(
489
+ interval: nil,
490
+ interval_count: nil,
491
+ name: nil,
492
+ next_billing: nil,
493
+ reference: nil
494
+ )
495
+ @interval = interval
496
+ @interval_count = interval_count
497
+ @name = name
498
+ @next_billing = next_billing
499
+ @reference = reference
500
+ end
501
+ end
502
+ # Controls when the funds are captured from the customer's account.
503
+ #
504
+ # If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
505
+ #
506
+ # If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
507
+ attr_accessor :capture_method
508
+ # On-demand details if setting up or charging an on-demand payment.
509
+ attr_accessor :on_demand
510
+ # Preferred language of the Klarna authorization page that the customer is redirected to
511
+ attr_accessor :preferred_locale
512
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
513
+ #
514
+ # 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.
515
+ #
516
+ # 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.
517
+ #
518
+ # 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).
519
+ #
520
+ # 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`.
521
+ attr_accessor :setup_future_usage
522
+ # Subscription details if setting up or charging a subscription.
523
+ attr_accessor :subscriptions
524
+
525
+ def initialize(
526
+ capture_method: nil,
527
+ on_demand: nil,
528
+ preferred_locale: nil,
529
+ setup_future_usage: nil,
530
+ subscriptions: nil
531
+ )
532
+ @capture_method = capture_method
533
+ @on_demand = on_demand
534
+ @preferred_locale = preferred_locale
535
+ @setup_future_usage = setup_future_usage
536
+ @subscriptions = subscriptions
537
+ end
538
+ end
539
+
540
+ class Link < Stripe::RequestParams
541
+ # Controls when the funds are captured from the customer's account.
542
+ #
543
+ # If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
544
+ #
545
+ # If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
546
+ attr_accessor :capture_method
547
+ # [Deprecated] This is a legacy parameter that no longer has any function.
548
+ attr_accessor :persistent_token
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
+ #
557
+ # 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`.
558
+ attr_accessor :setup_future_usage
559
+
560
+ def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil)
561
+ @capture_method = capture_method
562
+ @persistent_token = persistent_token
563
+ @setup_future_usage = setup_future_usage
564
+ end
565
+ end
566
+
567
+ class Oxxo < Stripe::RequestParams
568
+ # 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.
569
+ attr_accessor :expires_after_days
570
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
571
+ #
572
+ # 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.
573
+ #
574
+ # 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.
575
+ #
576
+ # 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).
577
+ #
578
+ # 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`.
579
+ attr_accessor :setup_future_usage
580
+
581
+ def initialize(expires_after_days: nil, setup_future_usage: nil)
582
+ @expires_after_days = expires_after_days
583
+ @setup_future_usage = setup_future_usage
584
+ end
585
+ end
586
+
587
+ class P24 < Stripe::RequestParams
588
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
589
+ #
590
+ # 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.
591
+ #
592
+ # 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.
593
+ #
594
+ # 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).
595
+ #
596
+ # 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`.
597
+ attr_accessor :setup_future_usage
598
+ # Confirm that the payer has accepted the P24 terms and conditions.
599
+ attr_accessor :tos_shown_and_accepted
600
+
601
+ def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil)
602
+ @setup_future_usage = setup_future_usage
603
+ @tos_shown_and_accepted = tos_shown_and_accepted
604
+ end
605
+ end
606
+
607
+ class Paypal < Stripe::RequestParams
608
+ class LineItem < Stripe::RequestParams
609
+ class Tax < Stripe::RequestParams
610
+ # The tax for a single unit of the line item in minor units. Cannot be a negative number.
611
+ attr_accessor :amount
612
+ # The tax behavior for the line item.
613
+ attr_accessor :behavior
614
+
615
+ def initialize(amount: nil, behavior: nil)
616
+ @amount = amount
617
+ @behavior = behavior
618
+ end
619
+ end
620
+ # Type of the line item.
621
+ attr_accessor :category
622
+ # Description of the line item.
623
+ attr_accessor :description
624
+ # Descriptive name of the line item.
625
+ attr_accessor :name
626
+ # Quantity of the line item. Must be a positive number.
627
+ attr_accessor :quantity
628
+ # Client facing stock keeping unit, article number or similar.
629
+ attr_accessor :sku
630
+ # The Stripe account ID of the connected account that sells the item.
631
+ attr_accessor :sold_by
632
+ # The tax information for the line item.
633
+ attr_accessor :tax
634
+ # Price for a single unit of the line item in minor units. Cannot be a negative number.
635
+ attr_accessor :unit_amount
636
+
637
+ def initialize(
638
+ category: nil,
639
+ description: nil,
640
+ name: nil,
641
+ quantity: nil,
642
+ sku: nil,
643
+ sold_by: nil,
644
+ tax: nil,
645
+ unit_amount: nil
646
+ )
647
+ @category = category
648
+ @description = description
649
+ @name = name
650
+ @quantity = quantity
651
+ @sku = sku
652
+ @sold_by = sold_by
653
+ @tax = tax
654
+ @unit_amount = unit_amount
655
+ end
656
+ end
657
+ # Controls when the funds will be captured from the customer's account.
658
+ attr_accessor :capture_method
659
+ # The line items purchased by the customer.
660
+ attr_accessor :line_items
661
+ # [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
662
+ attr_accessor :preferred_locale
663
+ # 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.
664
+ attr_accessor :reference
665
+ # 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.
666
+ attr_accessor :reference_id
667
+ # The risk correlation ID for an on-session payment using a saved PayPal payment method.
668
+ attr_accessor :risk_correlation_id
669
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
670
+ #
671
+ # 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.
672
+ #
673
+ # 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.
674
+ #
675
+ # 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).
676
+ #
677
+ # 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`.
678
+ attr_accessor :setup_future_usage
679
+ # 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.
680
+ attr_accessor :subsellers
681
+
682
+ def initialize(
683
+ capture_method: nil,
684
+ line_items: nil,
685
+ preferred_locale: nil,
686
+ reference: nil,
687
+ reference_id: nil,
688
+ risk_correlation_id: nil,
689
+ setup_future_usage: nil,
690
+ subsellers: nil
691
+ )
692
+ @capture_method = capture_method
693
+ @line_items = line_items
694
+ @preferred_locale = preferred_locale
695
+ @reference = reference
696
+ @reference_id = reference_id
697
+ @risk_correlation_id = risk_correlation_id
698
+ @setup_future_usage = setup_future_usage
699
+ @subsellers = subsellers
700
+ end
701
+ end
702
+
703
+ class SepaDebit < Stripe::RequestParams
704
+ class MandateOptions < Stripe::RequestParams
705
+ # 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'.
706
+ attr_accessor :reference_prefix
707
+
708
+ def initialize(reference_prefix: nil)
709
+ @reference_prefix = reference_prefix
710
+ end
711
+ end
712
+ # Additional fields for Mandate creation
713
+ attr_accessor :mandate_options
714
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
715
+ #
716
+ # 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.
717
+ #
718
+ # 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.
719
+ #
720
+ # 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).
721
+ #
722
+ # 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`.
723
+ attr_accessor :setup_future_usage
724
+ # Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
725
+ attr_accessor :target_date
726
+
727
+ def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil)
728
+ @mandate_options = mandate_options
729
+ @setup_future_usage = setup_future_usage
730
+ @target_date = target_date
731
+ end
732
+ end
733
+
734
+ class Sofort < Stripe::RequestParams
735
+ # Language shown to the payer on redirect.
736
+ attr_accessor :preferred_language
737
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
738
+ #
739
+ # 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.
740
+ #
741
+ # 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.
742
+ #
743
+ # 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).
744
+ #
745
+ # 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`.
746
+ attr_accessor :setup_future_usage
747
+
748
+ def initialize(preferred_language: nil, setup_future_usage: nil)
749
+ @preferred_language = preferred_language
750
+ @setup_future_usage = setup_future_usage
751
+ end
752
+ end
753
+
754
+ class WechatPay < Stripe::RequestParams
755
+ # The app ID registered with WeChat Pay. Only required when client is ios or android.
756
+ attr_accessor :app_id
757
+ # The client type that the end customer will pay from
758
+ attr_accessor :client
759
+ # Indicates that you intend to make future payments with this PaymentIntent's payment method.
760
+ #
761
+ # 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.
762
+ #
763
+ # 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.
764
+ #
765
+ # 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).
766
+ #
767
+ # 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`.
768
+ attr_accessor :setup_future_usage
769
+
770
+ def initialize(app_id: nil, client: nil, setup_future_usage: nil)
771
+ @app_id = app_id
772
+ @client = client
773
+ @setup_future_usage = setup_future_usage
774
+ end
775
+ end
776
+ # If paying by `acss_debit`, this sub-hash contains details about the ACSS Debit payment method options to pass to the order's PaymentIntent.
777
+ attr_accessor :acss_debit
778
+ # If paying by `afterpay_clearpay`, this sub-hash contains details about the AfterpayClearpay payment method options to pass to the order's PaymentIntent.
779
+ attr_accessor :afterpay_clearpay
780
+ # If paying by `alipay`, this sub-hash contains details about the Alipay payment method options to pass to the order's PaymentIntent.
781
+ attr_accessor :alipay
782
+ # If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the order's PaymentIntent.
783
+ attr_accessor :bancontact
784
+ # If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the order's PaymentIntent.
785
+ attr_accessor :card
786
+ # If paying by `customer_balance`, this sub-hash contains details about the Customer Balance payment method options to pass to the order's PaymentIntent.
787
+ attr_accessor :customer_balance
788
+ # If paying by `ideal`, this sub-hash contains details about the iDEAL payment method options to pass to the order's PaymentIntent.
789
+ attr_accessor :ideal
790
+ # If paying by `klarna`, this sub-hash contains details about the Klarna payment method options to pass to the order's PaymentIntent.
791
+ attr_accessor :klarna
792
+ # If paying by `link`, this sub-hash contains details about the Link payment method options to pass to the order's PaymentIntent.
793
+ attr_accessor :link
794
+ # If paying by `oxxo`, this sub-hash contains details about the OXXO payment method options to pass to the order's PaymentIntent.
795
+ attr_accessor :oxxo
796
+ # If paying by `p24`, this sub-hash contains details about the P24 payment method options to pass to the order's PaymentIntent.
797
+ attr_accessor :p24
798
+ # If paying by `paypal`, this sub-hash contains details about the PayPal payment method options to pass to the order's PaymentIntent.
799
+ attr_accessor :paypal
800
+ # If paying by `sepa_debit`, this sub-hash contains details about the SEPA Debit payment method options to pass to the order's PaymentIntent.
801
+ attr_accessor :sepa_debit
802
+ # If paying by `sofort`, this sub-hash contains details about the Sofort payment method options to pass to the order's PaymentIntent.
803
+ attr_accessor :sofort
804
+ # If paying by `wechat_pay`, this sub-hash contains details about the WeChat Pay payment method options to pass to the order's PaymentIntent.
805
+ attr_accessor :wechat_pay
806
+
807
+ def initialize(
808
+ acss_debit: nil,
809
+ afterpay_clearpay: nil,
810
+ alipay: nil,
811
+ bancontact: nil,
812
+ card: nil,
813
+ customer_balance: nil,
814
+ ideal: nil,
815
+ klarna: nil,
816
+ link: nil,
817
+ oxxo: nil,
818
+ p24: nil,
819
+ paypal: nil,
820
+ sepa_debit: nil,
821
+ sofort: nil,
822
+ wechat_pay: nil
823
+ )
824
+ @acss_debit = acss_debit
825
+ @afterpay_clearpay = afterpay_clearpay
826
+ @alipay = alipay
827
+ @bancontact = bancontact
828
+ @card = card
829
+ @customer_balance = customer_balance
830
+ @ideal = ideal
831
+ @klarna = klarna
832
+ @link = link
833
+ @oxxo = oxxo
834
+ @p24 = p24
835
+ @paypal = paypal
836
+ @sepa_debit = sepa_debit
837
+ @sofort = sofort
838
+ @wechat_pay = wechat_pay
839
+ end
840
+ end
841
+
842
+ class TransferData < Stripe::RequestParams
843
+ # The amount that will be transferred automatically when the order is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
844
+ attr_accessor :amount
845
+ # ID of the Connected account receiving the transfer.
846
+ attr_accessor :destination
847
+
848
+ def initialize(amount: nil, destination: nil)
849
+ @amount = amount
850
+ @destination = destination
851
+ end
852
+ end
853
+ # 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.
854
+ attr_accessor :application_fee_amount
855
+ # PaymentMethod-specific configuration to provide to the order's PaymentIntent.
856
+ attr_accessor :payment_method_options
857
+ # The list of [payment method types](https://stripe.com/docs/payments/payment-methods/overview) to provide to the order's PaymentIntent. Do not include this attribute if you prefer to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
858
+ attr_accessor :payment_method_types
859
+ # The URL to redirect the customer to after they authenticate their payment.
860
+ attr_accessor :return_url
861
+ # For non-card charges, you can use this value as the complete description that appears on your customers' statements. Must contain at least one letter, maximum 22 characters.
862
+ attr_accessor :statement_descriptor
863
+ # Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
864
+ attr_accessor :statement_descriptor_suffix
865
+ # Provides configuration for completing a transfer for the order after it is paid.
866
+ attr_accessor :transfer_data
867
+
868
+ def initialize(
869
+ application_fee_amount: nil,
870
+ payment_method_options: nil,
871
+ payment_method_types: nil,
872
+ return_url: nil,
873
+ statement_descriptor: nil,
874
+ statement_descriptor_suffix: nil,
875
+ transfer_data: nil
876
+ )
877
+ @application_fee_amount = application_fee_amount
878
+ @payment_method_options = payment_method_options
879
+ @payment_method_types = payment_method_types
880
+ @return_url = return_url
881
+ @statement_descriptor = statement_descriptor
882
+ @statement_descriptor_suffix = statement_descriptor_suffix
883
+ @transfer_data = transfer_data
884
+ end
885
+ end
886
+ # Settings describing how the order should configure generated PaymentIntents.
887
+ attr_accessor :settings
888
+
889
+ def initialize(settings: nil)
890
+ @settings = settings
891
+ end
892
+ end
893
+
894
+ class ShippingCost < Stripe::RequestParams
895
+ class ShippingRateData < Stripe::RequestParams
896
+ class DeliveryEstimate < Stripe::RequestParams
897
+ class Maximum < Stripe::RequestParams
898
+ # A unit of time.
899
+ attr_accessor :unit
900
+ # Must be greater than 0.
901
+ attr_accessor :value
902
+
903
+ def initialize(unit: nil, value: nil)
904
+ @unit = unit
905
+ @value = value
906
+ end
907
+ end
908
+
909
+ class Minimum < Stripe::RequestParams
910
+ # A unit of time.
911
+ attr_accessor :unit
912
+ # Must be greater than 0.
913
+ attr_accessor :value
914
+
915
+ def initialize(unit: nil, value: nil)
916
+ @unit = unit
917
+ @value = value
918
+ end
919
+ end
920
+ # The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
921
+ attr_accessor :maximum
922
+ # The lower bound of the estimated range. If empty, represents no lower bound.
923
+ attr_accessor :minimum
924
+
925
+ def initialize(maximum: nil, minimum: nil)
926
+ @maximum = maximum
927
+ @minimum = minimum
928
+ end
929
+ end
930
+
931
+ class FixedAmount < Stripe::RequestParams
932
+ class CurrencyOptions < Stripe::RequestParams
933
+ # A non-negative integer in cents representing how much to charge.
934
+ attr_accessor :amount
935
+ # Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
936
+ attr_accessor :tax_behavior
937
+
938
+ def initialize(amount: nil, tax_behavior: nil)
939
+ @amount = amount
940
+ @tax_behavior = tax_behavior
941
+ end
942
+ end
943
+ # A non-negative integer in cents representing how much to charge.
944
+ attr_accessor :amount
945
+ # 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).
946
+ attr_accessor :currency
947
+ # 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).
948
+ attr_accessor :currency_options
949
+
950
+ def initialize(amount: nil, currency: nil, currency_options: nil)
951
+ @amount = amount
952
+ @currency = currency
953
+ @currency_options = currency_options
954
+ end
955
+ end
956
+ # The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
957
+ attr_accessor :delivery_estimate
958
+ # The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
959
+ attr_accessor :display_name
960
+ # Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
961
+ attr_accessor :fixed_amount
962
+ # 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`.
963
+ attr_accessor :metadata
964
+ # Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
965
+ attr_accessor :tax_behavior
966
+ # A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
967
+ attr_accessor :tax_code
968
+ # The type of calculation to use on the shipping rate.
969
+ attr_accessor :type
970
+
971
+ def initialize(
972
+ delivery_estimate: nil,
973
+ display_name: nil,
974
+ fixed_amount: nil,
975
+ metadata: nil,
976
+ tax_behavior: nil,
977
+ tax_code: nil,
978
+ type: nil
979
+ )
980
+ @delivery_estimate = delivery_estimate
981
+ @display_name = display_name
982
+ @fixed_amount = fixed_amount
983
+ @metadata = metadata
984
+ @tax_behavior = tax_behavior
985
+ @tax_code = tax_code
986
+ @type = type
987
+ end
988
+ end
989
+ # The ID of the shipping rate to use for this order.
990
+ attr_accessor :shipping_rate
991
+ # Parameters to create a new ad-hoc shipping rate for this order.
992
+ attr_accessor :shipping_rate_data
993
+
994
+ def initialize(shipping_rate: nil, shipping_rate_data: nil)
995
+ @shipping_rate = shipping_rate
996
+ @shipping_rate_data = shipping_rate_data
997
+ end
998
+ end
999
+
1000
+ class ShippingDetails < Stripe::RequestParams
1001
+ class Address < Stripe::RequestParams
1002
+ # City, district, suburb, town, or village.
1003
+ attr_accessor :city
1004
+ # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
1005
+ attr_accessor :country
1006
+ # Address line 1, such as the street, PO Box, or company name.
1007
+ attr_accessor :line1
1008
+ # Address line 2, such as the apartment, suite, unit, or building.
1009
+ attr_accessor :line2
1010
+ # ZIP or postal code.
1011
+ attr_accessor :postal_code
1012
+ # State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix, such as "NY" or "TX".
1013
+ attr_accessor :state
1014
+
1015
+ def initialize(
1016
+ city: nil,
1017
+ country: nil,
1018
+ line1: nil,
1019
+ line2: nil,
1020
+ postal_code: nil,
1021
+ state: nil
1022
+ )
1023
+ @city = city
1024
+ @country = country
1025
+ @line1 = line1
1026
+ @line2 = line2
1027
+ @postal_code = postal_code
1028
+ @state = state
1029
+ end
1030
+ end
1031
+ # The shipping address for the order.
1032
+ attr_accessor :address
1033
+ # The name of the recipient of the order.
1034
+ attr_accessor :name
1035
+ # The phone number (including extension) for the recipient of the order.
1036
+ attr_accessor :phone
1037
+
1038
+ def initialize(address: nil, name: nil, phone: nil)
1039
+ @address = address
1040
+ @name = name
1041
+ @phone = phone
1042
+ end
1043
+ end
1044
+
1045
+ class TaxDetails < Stripe::RequestParams
1046
+ class TaxId < Stripe::RequestParams
1047
+ # Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
1048
+ attr_accessor :type
1049
+ # Value of the tax ID.
1050
+ attr_accessor :value
1051
+
1052
+ def initialize(type: nil, value: nil)
1053
+ @type = type
1054
+ @value = value
1055
+ end
1056
+ end
1057
+ # The purchaser's tax exemption status. One of `none`, `exempt`, or `reverse`.
1058
+ attr_accessor :tax_exempt
1059
+ # The purchaser's tax IDs to be used for this order.
1060
+ attr_accessor :tax_ids
1061
+
1062
+ def initialize(tax_exempt: nil, tax_ids: nil)
1063
+ @tax_exempt = tax_exempt
1064
+ @tax_ids = tax_ids
1065
+ end
1066
+ end
1067
+ # Settings for automatic tax calculation for this order.
1068
+ attr_accessor :automatic_tax
1069
+ # Billing details for the customer. If a customer is provided, this will be automatically populated with values from that customer if override values are not provided.
1070
+ attr_accessor :billing_details
1071
+ # 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).
1072
+ attr_accessor :currency
1073
+ # The customer associated with this order.
1074
+ attr_accessor :customer
1075
+ # An arbitrary string attached to the object. Often useful for displaying to users.
1076
+ attr_accessor :description
1077
+ # The coupons, promotion codes, and/or discounts to apply to the order. Pass the empty string `""` to unset this field.
1078
+ attr_accessor :discounts
1079
+ # Specifies which fields in the response should be expanded.
1080
+ attr_accessor :expand
1081
+ # The IP address of the purchaser for this order.
1082
+ attr_accessor :ip_address
1083
+ # A list of line items the customer is ordering. Each line item includes information about the product, the quantity, and the resulting cost.
1084
+ attr_accessor :line_items
1085
+ # 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`.
1086
+ attr_accessor :metadata
1087
+ # Payment information associated with the order, including payment settings.
1088
+ attr_accessor :payment
1089
+ # Settings for the customer cost of shipping for this order.
1090
+ attr_accessor :shipping_cost
1091
+ # Shipping details for the order.
1092
+ attr_accessor :shipping_details
1093
+ # Additional tax details about the purchaser to be used for this order.
1094
+ attr_accessor :tax_details
1095
+
1096
+ def initialize(
1097
+ automatic_tax: nil,
1098
+ billing_details: nil,
1099
+ currency: nil,
1100
+ customer: nil,
1101
+ description: nil,
1102
+ discounts: nil,
1103
+ expand: nil,
1104
+ ip_address: nil,
1105
+ line_items: nil,
1106
+ metadata: nil,
1107
+ payment: nil,
1108
+ shipping_cost: nil,
1109
+ shipping_details: nil,
1110
+ tax_details: nil
1111
+ )
1112
+ @automatic_tax = automatic_tax
1113
+ @billing_details = billing_details
1114
+ @currency = currency
1115
+ @customer = customer
1116
+ @description = description
1117
+ @discounts = discounts
1118
+ @expand = expand
1119
+ @ip_address = ip_address
1120
+ @line_items = line_items
1121
+ @metadata = metadata
1122
+ @payment = payment
1123
+ @shipping_cost = shipping_cost
1124
+ @shipping_details = shipping_details
1125
+ @tax_details = tax_details
1126
+ end
1127
+ end
1128
+ end