stripe 15.5.0.pre.beta.2 → 15.6.0.pre.alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/API_VERSION +1 -1
- data/CHANGELOG.md +117 -1
- data/OPENAPI_VERSION +1 -1
- data/README.md +6 -4
- data/VERSION +1 -1
- data/lib/stripe/api_requestor.rb +20 -18
- data/lib/stripe/api_version.rb +1 -1
- data/lib/stripe/errors.rb +26 -23
- data/lib/stripe/event_types.rb +83 -0
- data/lib/stripe/events/v2_billing_cadence_billed_event.rb +21 -0
- data/lib/stripe/events/v2_billing_cadence_canceled_event.rb +21 -0
- data/lib/stripe/events/v2_billing_cadence_created_event.rb +23 -0
- data/lib/stripe/events/v2_billing_cadence_errored_event.rb +21 -0
- data/lib/stripe/events/v2_billing_license_fee_created_event.rb +21 -0
- data/lib/stripe/events/v2_billing_license_fee_updated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_license_fee_version_created_event.rb +23 -0
- data/lib/stripe/events/v2_billing_licensed_item_created_event.rb +21 -0
- data/lib/stripe/events/v2_billing_licensed_item_updated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_metered_item_created_event.rb +21 -0
- data/lib/stripe/events/v2_billing_metered_item_updated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_component_created_event.rb +23 -0
- data/lib/stripe/events/v2_billing_pricing_plan_component_updated_event.rb +23 -0
- data/lib/stripe/events/v2_billing_pricing_plan_created_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_collection_awaiting_customer_action_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_collection_current_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_collection_past_due_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_collection_paused_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_collection_unpaid_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_servicing_activated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_servicing_canceled_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_subscription_servicing_paused_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_updated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_pricing_plan_version_created_event.rb +23 -0
- data/lib/stripe/events/v2_billing_rate_card_created_event.rb +23 -0
- data/lib/stripe/events/v2_billing_rate_card_rate_created_event.rb +23 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_activated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_canceled_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_collection_awaiting_customer_action_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_collection_current_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_collection_past_due_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_collection_paused_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_collection_unpaid_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_servicing_activated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_servicing_canceled_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_subscription_servicing_paused_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_updated_event.rb +21 -0
- data/lib/stripe/events/v2_billing_rate_card_version_created_event.rb +23 -0
- data/lib/stripe/events/v2_core_health_api_error_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_api_error_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_api_latency_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_api_latency_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_authorization_rate_drop_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_authorization_rate_drop_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_event_generation_failure_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_fraud_rate_increased_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_issuing_authorization_request_timeout_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_issuing_authorization_request_timeout_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_payment_method_error_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_payment_method_error_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_traffic_volume_drop_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_traffic_volume_drop_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_webhook_latency_firing_event.rb +13 -0
- data/lib/stripe/events/v2_core_health_webhook_latency_resolved_event.rb +13 -0
- data/lib/stripe/events/v2_reporting_report_run_created_event.rb +21 -0
- data/lib/stripe/events/v2_reporting_report_run_failed_event.rb +21 -0
- data/lib/stripe/events/v2_reporting_report_run_succeeded_event.rb +21 -0
- data/lib/stripe/events/v2_reporting_report_run_updated_event.rb +21 -0
- data/lib/stripe/object_types.rb +27 -0
- data/lib/stripe/resources/account.rb +2 -2
- data/lib/stripe/resources/account_session.rb +94 -13
- data/lib/stripe/resources/balance.rb +2 -7
- data/lib/stripe/resources/balance_settings.rb +72 -65
- data/lib/stripe/resources/billing/alert.rb +128 -1
- data/lib/stripe/resources/billing/alert_triggered.rb +6 -0
- data/lib/stripe/resources/billing/credit_balance_summary.rb +50 -0
- data/lib/stripe/resources/billing/credit_balance_transaction.rb +50 -0
- data/lib/stripe/resources/billing/credit_grant.rb +61 -2
- data/lib/stripe/resources/billing/meter.rb +2 -2
- data/lib/stripe/resources/billing/meter_usage_row.rb +1 -1
- data/lib/stripe/resources/billing_portal/configuration.rb +12 -2
- data/lib/stripe/resources/charge.rb +36 -5
- data/lib/stripe/resources/checkout/session.rb +237 -6
- data/lib/stripe/resources/credit_note.rb +3 -3
- data/lib/stripe/resources/dispute.rb +1 -1
- data/lib/stripe/resources/file.rb +1 -1
- data/lib/stripe/resources/file_link.rb +1 -1
- data/lib/stripe/resources/invoice.rb +55 -1
- data/lib/stripe/resources/invoice_item.rb +48 -0
- data/lib/stripe/resources/invoice_line_item.rb +52 -0
- data/lib/stripe/resources/invoice_payment.rb +1 -1
- data/lib/stripe/resources/mandate.rb +65 -1
- data/lib/stripe/resources/payment_attempt_record.rb +86 -10
- data/lib/stripe/resources/payment_intent.rb +182 -4
- data/lib/stripe/resources/payment_link.rb +1 -1
- data/lib/stripe/resources/payment_method.rb +2 -0
- data/lib/stripe/resources/payment_record.rb +107 -14
- data/lib/stripe/resources/promotion_code.rb +5 -2
- data/lib/stripe/resources/quote_preview_invoice.rb +8 -1
- data/lib/stripe/resources/quote_preview_subscription_schedule.rb +24 -0
- data/lib/stripe/resources/setup_attempt.rb +4 -1
- data/lib/stripe/resources/setup_intent.rb +194 -1
- data/lib/stripe/resources/subscription.rb +145 -9
- data/lib/stripe/resources/subscription_schedule.rb +124 -2
- data/lib/stripe/resources/terminal/configuration.rb +82 -0
- data/lib/stripe/resources/terminal/reader.rb +22 -0
- data/lib/stripe/resources/v2/billing/bill_setting.rb +62 -0
- data/lib/stripe/resources/v2/billing/bill_setting_version.rb +50 -0
- data/lib/stripe/resources/v2/billing/cadence.rb +182 -0
- data/lib/stripe/resources/v2/billing/collection_setting.rb +148 -0
- data/lib/stripe/resources/v2/billing/collection_setting_version.rb +136 -0
- data/lib/stripe/resources/v2/billing/custom_pricing_unit.rb +35 -0
- data/lib/stripe/resources/v2/billing/intent.rb +59 -0
- data/lib/stripe/resources/v2/billing/intent_action.rb +200 -0
- data/lib/stripe/resources/v2/billing/license_fee.rb +79 -0
- data/lib/stripe/resources/v2/billing/license_fee_subscription.rb +36 -0
- data/lib/stripe/resources/v2/billing/license_fee_version.rb +56 -0
- data/lib/stripe/resources/v2/billing/licensed_item.rb +44 -0
- data/lib/stripe/resources/v2/billing/metered_item.rb +58 -0
- data/lib/stripe/resources/v2/billing/pricing_plan.rb +43 -0
- data/lib/stripe/resources/v2/billing/pricing_plan_component.rb +58 -0
- data/lib/stripe/resources/v2/billing/pricing_plan_subscription.rb +63 -0
- data/lib/stripe/resources/v2/billing/pricing_plan_version.rb +30 -0
- data/lib/stripe/resources/v2/billing/profile.rb +38 -0
- data/lib/stripe/resources/v2/billing/rate_card.rb +53 -0
- data/lib/stripe/resources/v2/billing/rate_card_rate.rb +71 -0
- data/lib/stripe/resources/v2/billing/rate_card_subscription.rb +63 -0
- data/lib/stripe/resources/v2/billing/rate_card_version.rb +26 -0
- data/lib/stripe/resources/v2/billing/service_action.rb +117 -0
- data/lib/stripe/resources/v2/core/account.rb +8 -0
- data/lib/stripe/resources/v2/core/claimable_sandbox.rb +57 -0
- data/lib/stripe/resources/v2/event.rb +2 -0
- data/lib/stripe/resources/v2/money_management/financial_account.rb +4 -2
- data/lib/stripe/resources/v2/money_management/outbound_payment_quote.rb +1 -1
- data/lib/stripe/resources/v2/money_management/transaction.rb +2 -0
- data/lib/stripe/resources/v2/money_management/transaction_entry.rb +2 -0
- data/lib/stripe/resources/v2/reporting/report.rb +64 -0
- data/lib/stripe/resources/v2/reporting/report_run.rb +89 -0
- data/lib/stripe/resources/v2/tax/automatic_rule.rb +31 -0
- data/lib/stripe/resources.rb +85 -0
- data/lib/stripe/services/account_session_service.rb +64 -13
- data/lib/stripe/services/balance_settings_service.rb +44 -41
- data/lib/stripe/services/billing/alert_service.rb +75 -1
- data/lib/stripe/services/billing/credit_balance_summary_service.rb +13 -1
- data/lib/stripe/services/billing/credit_grant_service.rb +29 -2
- data/lib/stripe/services/billing/meter_service.rb +1 -1
- data/lib/stripe/services/billing_portal/configuration_service.rb +10 -2
- data/lib/stripe/services/checkout/session_service.rb +166 -5
- data/lib/stripe/services/credit_note_preview_lines_service.rb +1 -1
- data/lib/stripe/services/credit_note_service.rb +2 -2
- data/lib/stripe/services/customer_service.rb +4 -4
- data/lib/stripe/services/file_link_service.rb +1 -1
- data/lib/stripe/services/file_service.rb +1 -1
- data/lib/stripe/services/invoice_payment_service.rb +1 -1
- data/lib/stripe/services/invoice_service.rb +47 -0
- data/lib/stripe/services/mandate_service.rb +40 -0
- data/lib/stripe/services/payment_attempt_record_service.rb +4 -1
- data/lib/stripe/services/payment_intent_service.rb +157 -3
- data/lib/stripe/services/payment_link_service.rb +1 -1
- data/lib/stripe/services/payment_record_service.rb +25 -5
- data/lib/stripe/services/quote_service.rb +4 -4
- data/lib/stripe/services/setup_intent_service.rb +153 -0
- data/lib/stripe/services/subscription_schedule_service.rb +100 -2
- data/lib/stripe/services/subscription_service.rb +134 -9
- data/lib/stripe/services/terminal/configuration_service.rb +64 -0
- data/lib/stripe/services/test_helpers/terminal/reader_service.rb +22 -0
- data/lib/stripe/services/v1_services.rb +5 -5
- data/lib/stripe/services/v2/billing/bill_setting_service.rb +214 -0
- data/lib/stripe/services/v2/billing/bill_settings/version_service.rb +45 -0
- data/lib/stripe/services/v2/billing/cadence_service.rb +428 -0
- data/lib/stripe/services/v2/billing/collection_setting_service.rb +518 -0
- data/lib/stripe/services/v2/billing/collection_settings/version_service.rb +45 -0
- data/lib/stripe/services/v2/billing/custom_pricing_unit_service.rb +108 -0
- data/lib/stripe/services/v2/billing/intent_service.rb +465 -0
- data/lib/stripe/services/v2/billing/intents/action_service.rb +45 -0
- data/lib/stripe/services/v2/billing/license_fee_service.rb +250 -0
- data/lib/stripe/services/v2/billing/license_fee_subscription_service.rb +23 -0
- data/lib/stripe/services/v2/billing/license_fees/version_service.rb +45 -0
- data/lib/stripe/services/v2/billing/licensed_item_service.rb +149 -0
- data/lib/stripe/services/v2/billing/metered_item_service.rb +176 -0
- data/lib/stripe/services/v2/billing/pricing_plan_service.rb +142 -0
- data/lib/stripe/services/v2/billing/pricing_plan_subscription_service.rb +76 -0
- data/lib/stripe/services/v2/billing/pricing_plans/component_service.rb +162 -0
- data/lib/stripe/services/v2/billing/pricing_plans/version_service.rb +45 -0
- data/lib/stripe/services/v2/billing/profile_service.rb +144 -0
- data/lib/stripe/services/v2/billing/rate_card_service.rb +151 -0
- data/lib/stripe/services/v2/billing/rate_card_subscription_service.rb +144 -0
- data/lib/stripe/services/v2/billing/rate_cards/rate_service.rb +161 -0
- data/lib/stripe/services/v2/billing/rate_cards/version_service.rb +45 -0
- data/lib/stripe/services/v2/billing/service_action_service.rb +259 -0
- data/lib/stripe/services/v2/billing_service.rb +19 -2
- data/lib/stripe/services/v2/core/account_service.rb +16 -2
- data/lib/stripe/services/v2/core/claimable_sandbox_service.rb +50 -0
- data/lib/stripe/services/v2/core_service.rb +4 -3
- data/lib/stripe/services/v2/money_management/financial_account_service.rb +4 -1
- data/lib/stripe/services/v2/money_management_service.rb +3 -3
- data/lib/stripe/services/v2/reporting/report_run_service.rb +88 -0
- data/lib/stripe/services/v2/reporting/report_service.rb +25 -0
- data/lib/stripe/services/v2/reporting_service.rb +16 -0
- data/lib/stripe/services/v2/tax/automatic_rule_service.rb +99 -0
- data/lib/stripe/services/v2/tax_service.rb +15 -0
- data/lib/stripe/services/v2_services.rb +3 -1
- data/lib/stripe/services.rb +29 -0
- data/lib/stripe/stripe_service.rb +3 -1
- data/lib/stripe/version.rb +1 -1
- metadata +116 -3
- data/rbi/stripe.rbi +0 -199145
@@ -34,6 +34,15 @@ module Stripe
|
|
34
34
|
end
|
35
35
|
end
|
36
36
|
|
37
|
+
class ReaderSecurity < Stripe::RequestParams
|
38
|
+
# Passcode used to access a reader's admin menu.
|
39
|
+
attr_accessor :admin_menu_passcode
|
40
|
+
|
41
|
+
def initialize(admin_menu_passcode: nil)
|
42
|
+
@admin_menu_passcode = admin_menu_passcode
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
37
46
|
class RebootWindow < Stripe::RequestParams
|
38
47
|
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
|
39
48
|
attr_accessor :end_hour
|
@@ -236,6 +245,21 @@ module Stripe
|
|
236
245
|
end
|
237
246
|
end
|
238
247
|
|
248
|
+
class Mxn < Stripe::RequestParams
|
249
|
+
# Fixed amounts displayed when collecting a tip
|
250
|
+
attr_accessor :fixed_amounts
|
251
|
+
# Percentages displayed when collecting a tip
|
252
|
+
attr_accessor :percentages
|
253
|
+
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
|
254
|
+
attr_accessor :smart_tip_threshold
|
255
|
+
|
256
|
+
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil)
|
257
|
+
@fixed_amounts = fixed_amounts
|
258
|
+
@percentages = percentages
|
259
|
+
@smart_tip_threshold = smart_tip_threshold
|
260
|
+
end
|
261
|
+
end
|
262
|
+
|
239
263
|
class Myr < Stripe::RequestParams
|
240
264
|
# Fixed amounts displayed when collecting a tip
|
241
265
|
attr_accessor :fixed_amounts
|
@@ -379,6 +403,8 @@ module Stripe
|
|
379
403
|
attr_accessor :huf
|
380
404
|
# Tipping configuration for JPY
|
381
405
|
attr_accessor :jpy
|
406
|
+
# Tipping configuration for MXN
|
407
|
+
attr_accessor :mxn
|
382
408
|
# Tipping configuration for MYR
|
383
409
|
attr_accessor :myr
|
384
410
|
# Tipping configuration for NOK
|
@@ -409,6 +435,7 @@ module Stripe
|
|
409
435
|
hkd: nil,
|
410
436
|
huf: nil,
|
411
437
|
jpy: nil,
|
438
|
+
mxn: nil,
|
412
439
|
myr: nil,
|
413
440
|
nok: nil,
|
414
441
|
nzd: nil,
|
@@ -430,6 +457,7 @@ module Stripe
|
|
430
457
|
@hkd = hkd
|
431
458
|
@huf = huf
|
432
459
|
@jpy = jpy
|
460
|
+
@mxn = mxn
|
433
461
|
@myr = myr
|
434
462
|
@nok = nok
|
435
463
|
@nzd = nzd
|
@@ -536,6 +564,8 @@ module Stripe
|
|
536
564
|
attr_accessor :name
|
537
565
|
# Configurations for collecting transactions offline.
|
538
566
|
attr_accessor :offline
|
567
|
+
# Configurations for reader security settings.
|
568
|
+
attr_accessor :reader_security
|
539
569
|
# Reboot time settings for readers that support customized reboot time configuration.
|
540
570
|
attr_accessor :reboot_window
|
541
571
|
# An object containing device type specific settings for Stripe S700 readers
|
@@ -552,6 +582,7 @@ module Stripe
|
|
552
582
|
expand: nil,
|
553
583
|
name: nil,
|
554
584
|
offline: nil,
|
585
|
+
reader_security: nil,
|
555
586
|
reboot_window: nil,
|
556
587
|
stripe_s700: nil,
|
557
588
|
tipping: nil,
|
@@ -562,6 +593,7 @@ module Stripe
|
|
562
593
|
@expand = expand
|
563
594
|
@name = name
|
564
595
|
@offline = offline
|
596
|
+
@reader_security = reader_security
|
565
597
|
@reboot_window = reboot_window
|
566
598
|
@stripe_s700 = stripe_s700
|
567
599
|
@tipping = tipping
|
@@ -616,6 +648,15 @@ module Stripe
|
|
616
648
|
end
|
617
649
|
end
|
618
650
|
|
651
|
+
class ReaderSecurity < Stripe::RequestParams
|
652
|
+
# Passcode used to access a reader's admin menu.
|
653
|
+
attr_accessor :admin_menu_passcode
|
654
|
+
|
655
|
+
def initialize(admin_menu_passcode: nil)
|
656
|
+
@admin_menu_passcode = admin_menu_passcode
|
657
|
+
end
|
658
|
+
end
|
659
|
+
|
619
660
|
class RebootWindow < Stripe::RequestParams
|
620
661
|
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
|
621
662
|
attr_accessor :end_hour
|
@@ -818,6 +859,21 @@ module Stripe
|
|
818
859
|
end
|
819
860
|
end
|
820
861
|
|
862
|
+
class Mxn < Stripe::RequestParams
|
863
|
+
# Fixed amounts displayed when collecting a tip
|
864
|
+
attr_accessor :fixed_amounts
|
865
|
+
# Percentages displayed when collecting a tip
|
866
|
+
attr_accessor :percentages
|
867
|
+
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
|
868
|
+
attr_accessor :smart_tip_threshold
|
869
|
+
|
870
|
+
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil)
|
871
|
+
@fixed_amounts = fixed_amounts
|
872
|
+
@percentages = percentages
|
873
|
+
@smart_tip_threshold = smart_tip_threshold
|
874
|
+
end
|
875
|
+
end
|
876
|
+
|
821
877
|
class Myr < Stripe::RequestParams
|
822
878
|
# Fixed amounts displayed when collecting a tip
|
823
879
|
attr_accessor :fixed_amounts
|
@@ -961,6 +1017,8 @@ module Stripe
|
|
961
1017
|
attr_accessor :huf
|
962
1018
|
# Tipping configuration for JPY
|
963
1019
|
attr_accessor :jpy
|
1020
|
+
# Tipping configuration for MXN
|
1021
|
+
attr_accessor :mxn
|
964
1022
|
# Tipping configuration for MYR
|
965
1023
|
attr_accessor :myr
|
966
1024
|
# Tipping configuration for NOK
|
@@ -991,6 +1049,7 @@ module Stripe
|
|
991
1049
|
hkd: nil,
|
992
1050
|
huf: nil,
|
993
1051
|
jpy: nil,
|
1052
|
+
mxn: nil,
|
994
1053
|
myr: nil,
|
995
1054
|
nok: nil,
|
996
1055
|
nzd: nil,
|
@@ -1012,6 +1071,7 @@ module Stripe
|
|
1012
1071
|
@hkd = hkd
|
1013
1072
|
@huf = huf
|
1014
1073
|
@jpy = jpy
|
1074
|
+
@mxn = mxn
|
1015
1075
|
@myr = myr
|
1016
1076
|
@nok = nok
|
1017
1077
|
@nzd = nzd
|
@@ -1118,6 +1178,8 @@ module Stripe
|
|
1118
1178
|
attr_accessor :name
|
1119
1179
|
# Configurations for collecting transactions offline.
|
1120
1180
|
attr_accessor :offline
|
1181
|
+
# Configurations for reader security settings.
|
1182
|
+
attr_accessor :reader_security
|
1121
1183
|
# Reboot time settings for readers that support customized reboot time configuration.
|
1122
1184
|
attr_accessor :reboot_window
|
1123
1185
|
# An object containing device type specific settings for Stripe S700 readers
|
@@ -1134,6 +1196,7 @@ module Stripe
|
|
1134
1196
|
expand: nil,
|
1135
1197
|
name: nil,
|
1136
1198
|
offline: nil,
|
1199
|
+
reader_security: nil,
|
1137
1200
|
reboot_window: nil,
|
1138
1201
|
stripe_s700: nil,
|
1139
1202
|
tipping: nil,
|
@@ -1144,6 +1207,7 @@ module Stripe
|
|
1144
1207
|
@expand = expand
|
1145
1208
|
@name = name
|
1146
1209
|
@offline = offline
|
1210
|
+
@reader_security = reader_security
|
1147
1211
|
@reboot_window = reboot_window
|
1148
1212
|
@stripe_s700 = stripe_s700
|
1149
1213
|
@tipping = tipping
|
@@ -6,6 +6,24 @@ module Stripe
|
|
6
6
|
module Terminal
|
7
7
|
class ReaderService < StripeService
|
8
8
|
class PresentPaymentMethodParams < Stripe::RequestParams
|
9
|
+
class Card < Stripe::RequestParams
|
10
|
+
# Card security code.
|
11
|
+
attr_accessor :cvc
|
12
|
+
# Two-digit number representing the card's expiration month.
|
13
|
+
attr_accessor :exp_month
|
14
|
+
# Two- or four-digit number representing the card's expiration year.
|
15
|
+
attr_accessor :exp_year
|
16
|
+
# The card number, as a string without any separators.
|
17
|
+
attr_accessor :number
|
18
|
+
|
19
|
+
def initialize(cvc: nil, exp_month: nil, exp_year: nil, number: nil)
|
20
|
+
@cvc = cvc
|
21
|
+
@exp_month = exp_month
|
22
|
+
@exp_year = exp_year
|
23
|
+
@number = number
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
9
27
|
class CardPresent < Stripe::RequestParams
|
10
28
|
# The card number, as a string without any separators.
|
11
29
|
attr_accessor :number
|
@@ -25,6 +43,8 @@ module Stripe
|
|
25
43
|
end
|
26
44
|
# Simulated on-reader tip amount.
|
27
45
|
attr_accessor :amount_tip
|
46
|
+
# Simulated data for the card payment method.
|
47
|
+
attr_accessor :card
|
28
48
|
# Simulated data for the card_present payment method.
|
29
49
|
attr_accessor :card_present
|
30
50
|
# Specifies which fields in the response should be expanded.
|
@@ -36,12 +56,14 @@ module Stripe
|
|
36
56
|
|
37
57
|
def initialize(
|
38
58
|
amount_tip: nil,
|
59
|
+
card: nil,
|
39
60
|
card_present: nil,
|
40
61
|
expand: nil,
|
41
62
|
interac_present: nil,
|
42
63
|
type: nil
|
43
64
|
)
|
44
65
|
@amount_tip = amount_tip
|
66
|
+
@card = card
|
45
67
|
@card_present = card_present
|
46
68
|
@expand = expand
|
47
69
|
@interac_present = interac_present
|
@@ -4,7 +4,7 @@ module Stripe
|
|
4
4
|
class V1Services < StripeService
|
5
5
|
# v1 accessors: The beginning of the section generated from our OpenAPI spec
|
6
6
|
attr_reader :accounts
|
7
|
-
attr_reader :account_links, :account_notices, :account_sessions, :apple_pay_domains, :application_fees, :apps, :balance, :balance_settings, :balance_transactions, :billing, :billing_portal, :capital, :charges, :checkout, :climate, :confirmation_tokens, :
|
7
|
+
attr_reader :account_links, :account_notices, :account_sessions, :apple_pay_domains, :application_fees, :apps, :balance, :balance_settings, :balance_transactions, :billing, :billing_portal, :capital, :charges, :checkout, :climate, :confirmation_tokens, :country_specs, :coupons, :credit_notes, :customers, :customer_sessions, :disputes, :entitlements, :ephemeral_keys, :events, :exchange_rates, :external_accounts, :files, :file_links, :financial_connections, :forwarding, :fx_quotes, :identity, :invoices, :invoice_items, :invoice_payments, :invoice_rendering_templates, :issuing, :mandates, :margins, :orders, :payment_attempt_records, :payment_intents, :payment_links, :payment_methods, :payment_method_configurations, :payment_method_domains, :payment_records, :payouts, :plans, :prices, :privacy, :products, :promotion_codes, :quotes, :radar, :refunds, :reporting, :reviews, :setup_attempts, :setup_intents, :shipping_rates, :sigma, :sources, :subscriptions, :subscription_items, :subscription_schedules, :tax, :tax_codes, :tax_ids, :tax_rates, :terminal, :test_helpers, :tokens, :topups, :transfers, :treasury, :webhook_endpoints
|
8
8
|
# v1 accessors: The end of the section generated from our OpenAPI spec
|
9
9
|
|
10
10
|
# OAuthService is manually maintained, as it has special behaviors
|
@@ -30,7 +30,6 @@ module Stripe
|
|
30
30
|
@checkout = Stripe::CheckoutService.new(@requestor)
|
31
31
|
@climate = Stripe::ClimateService.new(@requestor)
|
32
32
|
@confirmation_tokens = Stripe::ConfirmationTokenService.new(@requestor)
|
33
|
-
@test_helpers = Stripe::TestHelpersService.new(@requestor)
|
34
33
|
@country_specs = Stripe::CountrySpecService.new(@requestor)
|
35
34
|
@coupons = Stripe::CouponService.new(@requestor)
|
36
35
|
@credit_notes = Stripe::CreditNoteService.new(@requestor)
|
@@ -41,6 +40,7 @@ module Stripe
|
|
41
40
|
@ephemeral_keys = Stripe::EphemeralKeyService.new(@requestor)
|
42
41
|
@events = Stripe::EventService.new(@requestor)
|
43
42
|
@exchange_rates = Stripe::ExchangeRateService.new(@requestor)
|
43
|
+
@external_accounts = Stripe::ExternalAccountService.new(@requestor)
|
44
44
|
@files = Stripe::FileService.new(@requestor)
|
45
45
|
@file_links = Stripe::FileLinkService.new(@requestor)
|
46
46
|
@financial_connections = Stripe::FinancialConnectionsService.new(@requestor)
|
@@ -48,9 +48,9 @@ module Stripe
|
|
48
48
|
@fx_quotes = Stripe::FxQuoteService.new(@requestor)
|
49
49
|
@identity = Stripe::IdentityService.new(@requestor)
|
50
50
|
@invoices = Stripe::InvoiceService.new(@requestor)
|
51
|
+
@invoice_items = Stripe::InvoiceItemService.new(@requestor)
|
51
52
|
@invoice_payments = Stripe::InvoicePaymentService.new(@requestor)
|
52
53
|
@invoice_rendering_templates = Stripe::InvoiceRenderingTemplateService.new(@requestor)
|
53
|
-
@invoice_items = Stripe::InvoiceItemService.new(@requestor)
|
54
54
|
@issuing = Stripe::IssuingService.new(@requestor)
|
55
55
|
@mandates = Stripe::MandateService.new(@requestor)
|
56
56
|
@margins = Stripe::MarginService.new(@requestor)
|
@@ -73,10 +73,10 @@ module Stripe
|
|
73
73
|
@refunds = Stripe::RefundService.new(@requestor)
|
74
74
|
@reporting = Stripe::ReportingService.new(@requestor)
|
75
75
|
@reviews = Stripe::ReviewService.new(@requestor)
|
76
|
-
@sigma = Stripe::SigmaService.new(@requestor)
|
77
76
|
@setup_attempts = Stripe::SetupAttemptService.new(@requestor)
|
78
77
|
@setup_intents = Stripe::SetupIntentService.new(@requestor)
|
79
78
|
@shipping_rates = Stripe::ShippingRateService.new(@requestor)
|
79
|
+
@sigma = Stripe::SigmaService.new(@requestor)
|
80
80
|
@sources = Stripe::SourceService.new(@requestor)
|
81
81
|
@subscriptions = Stripe::SubscriptionService.new(@requestor)
|
82
82
|
@subscription_items = Stripe::SubscriptionItemService.new(@requestor)
|
@@ -86,12 +86,12 @@ module Stripe
|
|
86
86
|
@tax_ids = Stripe::TaxIdService.new(@requestor)
|
87
87
|
@tax_rates = Stripe::TaxRateService.new(@requestor)
|
88
88
|
@terminal = Stripe::TerminalService.new(@requestor)
|
89
|
+
@test_helpers = Stripe::TestHelpersService.new(@requestor)
|
89
90
|
@tokens = Stripe::TokenService.new(@requestor)
|
90
91
|
@topups = Stripe::TopupService.new(@requestor)
|
91
92
|
@transfers = Stripe::TransferService.new(@requestor)
|
92
93
|
@treasury = Stripe::TreasuryService.new(@requestor)
|
93
94
|
@webhook_endpoints = Stripe::WebhookEndpointService.new(@requestor)
|
94
|
-
@external_accounts = Stripe::ExternalAccountService.new(@requestor)
|
95
95
|
# v1 services: The end of the section generated from our OpenAPI spec
|
96
96
|
|
97
97
|
@oauth = OAuthService.new(@requestor)
|
@@ -0,0 +1,214 @@
|
|
1
|
+
# File generated from our OpenAPI spec
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
module Stripe
|
5
|
+
module V2
|
6
|
+
module Billing
|
7
|
+
class BillSettingService < StripeService
|
8
|
+
attr_reader :versions
|
9
|
+
|
10
|
+
def initialize(requestor)
|
11
|
+
super
|
12
|
+
@versions = Stripe::V2::Billing::BillSettings::VersionService.new(@requestor)
|
13
|
+
end
|
14
|
+
|
15
|
+
class ListParams < Stripe::RequestParams
|
16
|
+
# Optionally set the maximum number of results per page. Defaults to 20.
|
17
|
+
attr_accessor :limit
|
18
|
+
# Only return the settings with these lookup_keys, if any exist.
|
19
|
+
# You can specify up to 10 lookup_keys.
|
20
|
+
attr_accessor :lookup_keys
|
21
|
+
|
22
|
+
def initialize(limit: nil, lookup_keys: nil)
|
23
|
+
@limit = limit
|
24
|
+
@lookup_keys = lookup_keys
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
class CreateParams < Stripe::RequestParams
|
29
|
+
class Calculation < Stripe::RequestParams
|
30
|
+
class Tax < Stripe::RequestParams
|
31
|
+
# Determines if tax will be calculated automatically based on a PTC or manually based on rules defined by the merchant. Defaults to "manual".
|
32
|
+
attr_accessor :type
|
33
|
+
|
34
|
+
def initialize(type: nil)
|
35
|
+
@type = type
|
36
|
+
end
|
37
|
+
end
|
38
|
+
# Settings for calculating tax.
|
39
|
+
attr_accessor :tax
|
40
|
+
|
41
|
+
def initialize(tax: nil)
|
42
|
+
@tax = tax
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
class Invoice < Stripe::RequestParams
|
47
|
+
class TimeUntilDue < Stripe::RequestParams
|
48
|
+
# The interval unit for the time until due.
|
49
|
+
attr_accessor :interval
|
50
|
+
# The number of interval units. For example, if interval=day and interval_count=30,
|
51
|
+
# the invoice will be due in 30 days.
|
52
|
+
attr_accessor :interval_count
|
53
|
+
|
54
|
+
def initialize(interval: nil, interval_count: nil)
|
55
|
+
@interval = interval
|
56
|
+
@interval_count = interval_count
|
57
|
+
end
|
58
|
+
end
|
59
|
+
# The amount of time until the invoice will be overdue for payment.
|
60
|
+
attr_accessor :time_until_due
|
61
|
+
|
62
|
+
def initialize(time_until_due: nil)
|
63
|
+
@time_until_due = time_until_due
|
64
|
+
end
|
65
|
+
end
|
66
|
+
# Settings related to calculating a bill.
|
67
|
+
attr_accessor :calculation
|
68
|
+
# An optional customer-facing display name for the CollectionSetting object.
|
69
|
+
# Maximum length of 250 characters.
|
70
|
+
attr_accessor :display_name
|
71
|
+
# Settings related to invoice behavior.
|
72
|
+
attr_accessor :invoice
|
73
|
+
# The ID of the invoice rendering template to be used when generating invoices.
|
74
|
+
attr_accessor :invoice_rendering_template
|
75
|
+
# A lookup key used to retrieve settings dynamically from a static string.
|
76
|
+
# This may be up to 200 characters.
|
77
|
+
attr_accessor :lookup_key
|
78
|
+
|
79
|
+
def initialize(
|
80
|
+
calculation: nil,
|
81
|
+
display_name: nil,
|
82
|
+
invoice: nil,
|
83
|
+
invoice_rendering_template: nil,
|
84
|
+
lookup_key: nil
|
85
|
+
)
|
86
|
+
@calculation = calculation
|
87
|
+
@display_name = display_name
|
88
|
+
@invoice = invoice
|
89
|
+
@invoice_rendering_template = invoice_rendering_template
|
90
|
+
@lookup_key = lookup_key
|
91
|
+
end
|
92
|
+
end
|
93
|
+
|
94
|
+
class RetrieveParams < Stripe::RequestParams; end
|
95
|
+
|
96
|
+
class UpdateParams < Stripe::RequestParams
|
97
|
+
class Calculation < Stripe::RequestParams
|
98
|
+
class Tax < Stripe::RequestParams
|
99
|
+
# Determines if tax will be calculated automatically based on a PTC or manually based on rules defined by the merchant. Defaults to "manual".
|
100
|
+
attr_accessor :type
|
101
|
+
|
102
|
+
def initialize(type: nil)
|
103
|
+
@type = type
|
104
|
+
end
|
105
|
+
end
|
106
|
+
# Settings for calculating tax.
|
107
|
+
attr_accessor :tax
|
108
|
+
|
109
|
+
def initialize(tax: nil)
|
110
|
+
@tax = tax
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
class Invoice < Stripe::RequestParams
|
115
|
+
class TimeUntilDue < Stripe::RequestParams
|
116
|
+
# The interval unit for the time until due.
|
117
|
+
attr_accessor :interval
|
118
|
+
# The number of interval units. For example, if interval=day and interval_count=30,
|
119
|
+
# the invoice will be due in 30 days.
|
120
|
+
attr_accessor :interval_count
|
121
|
+
|
122
|
+
def initialize(interval: nil, interval_count: nil)
|
123
|
+
@interval = interval
|
124
|
+
@interval_count = interval_count
|
125
|
+
end
|
126
|
+
end
|
127
|
+
# The amount of time until the invoice will be overdue for payment.
|
128
|
+
attr_accessor :time_until_due
|
129
|
+
|
130
|
+
def initialize(time_until_due: nil)
|
131
|
+
@time_until_due = time_until_due
|
132
|
+
end
|
133
|
+
end
|
134
|
+
# Settings related to calculating a bill.
|
135
|
+
attr_accessor :calculation
|
136
|
+
# An optional customer-facing display name for the BillSetting object.
|
137
|
+
# To remove the display name, set it to an empty string in the request.
|
138
|
+
# Maximum length of 250 characters.
|
139
|
+
attr_accessor :display_name
|
140
|
+
# Settings related to invoice behavior.
|
141
|
+
attr_accessor :invoice
|
142
|
+
# The ID of the invoice rendering template to be used when generating invoices.
|
143
|
+
attr_accessor :invoice_rendering_template
|
144
|
+
# Optionally change the live version of the BillSetting. Providing `live_version = "latest"` will set the
|
145
|
+
# BillSetting' `live_version` to its latest version.
|
146
|
+
attr_accessor :live_version
|
147
|
+
# A lookup key used to retrieve settings dynamically from a static string.
|
148
|
+
# This may be up to 200 characters.
|
149
|
+
attr_accessor :lookup_key
|
150
|
+
|
151
|
+
def initialize(
|
152
|
+
calculation: nil,
|
153
|
+
display_name: nil,
|
154
|
+
invoice: nil,
|
155
|
+
invoice_rendering_template: nil,
|
156
|
+
live_version: nil,
|
157
|
+
lookup_key: nil
|
158
|
+
)
|
159
|
+
@calculation = calculation
|
160
|
+
@display_name = display_name
|
161
|
+
@invoice = invoice
|
162
|
+
@invoice_rendering_template = invoice_rendering_template
|
163
|
+
@live_version = live_version
|
164
|
+
@lookup_key = lookup_key
|
165
|
+
end
|
166
|
+
end
|
167
|
+
|
168
|
+
# Create a BillSetting object.
|
169
|
+
def create(params = {}, opts = {})
|
170
|
+
request(
|
171
|
+
method: :post,
|
172
|
+
path: "/v2/billing/bill_settings",
|
173
|
+
params: params,
|
174
|
+
opts: opts,
|
175
|
+
base_address: :api
|
176
|
+
)
|
177
|
+
end
|
178
|
+
|
179
|
+
# List all BillSetting objects.
|
180
|
+
def list(params = {}, opts = {})
|
181
|
+
request(
|
182
|
+
method: :get,
|
183
|
+
path: "/v2/billing/bill_settings",
|
184
|
+
params: params,
|
185
|
+
opts: opts,
|
186
|
+
base_address: :api
|
187
|
+
)
|
188
|
+
end
|
189
|
+
|
190
|
+
# Retrieve a BillSetting object by ID.
|
191
|
+
def retrieve(id, params = {}, opts = {})
|
192
|
+
request(
|
193
|
+
method: :get,
|
194
|
+
path: format("/v2/billing/bill_settings/%<id>s", { id: CGI.escape(id) }),
|
195
|
+
params: params,
|
196
|
+
opts: opts,
|
197
|
+
base_address: :api
|
198
|
+
)
|
199
|
+
end
|
200
|
+
|
201
|
+
# Update fields on an existing BillSetting object.
|
202
|
+
def update(id, params = {}, opts = {})
|
203
|
+
request(
|
204
|
+
method: :post,
|
205
|
+
path: format("/v2/billing/bill_settings/%<id>s", { id: CGI.escape(id) }),
|
206
|
+
params: params,
|
207
|
+
opts: opts,
|
208
|
+
base_address: :api
|
209
|
+
)
|
210
|
+
end
|
211
|
+
end
|
212
|
+
end
|
213
|
+
end
|
214
|
+
end
|
@@ -0,0 +1,45 @@
|
|
1
|
+
# File generated from our OpenAPI spec
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
module Stripe
|
5
|
+
module V2
|
6
|
+
module Billing
|
7
|
+
module BillSettings
|
8
|
+
class VersionService < StripeService
|
9
|
+
class ListParams < Stripe::RequestParams
|
10
|
+
# Optionally set the maximum number of results per page. Defaults to 20.
|
11
|
+
attr_accessor :limit
|
12
|
+
|
13
|
+
def initialize(limit: nil)
|
14
|
+
@limit = limit
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
class RetrieveParams < Stripe::RequestParams; end
|
19
|
+
|
20
|
+
# List all BillSettingVersions by BillSetting ID.
|
21
|
+
def list(bill_setting_id, params = {}, opts = {})
|
22
|
+
request(
|
23
|
+
method: :get,
|
24
|
+
path: format("/v2/billing/bill_settings/%<bill_setting_id>s/versions", { bill_setting_id: CGI.escape(bill_setting_id) }),
|
25
|
+
params: params,
|
26
|
+
opts: opts,
|
27
|
+
base_address: :api
|
28
|
+
)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Retrieve a BillSettingVersion by ID.
|
32
|
+
def retrieve(bill_setting_id, id, params = {}, opts = {})
|
33
|
+
request(
|
34
|
+
method: :get,
|
35
|
+
path: format("/v2/billing/bill_settings/%<bill_setting_id>s/versions/%<id>s", { bill_setting_id: CGI.escape(bill_setting_id), id: CGI.escape(id) }),
|
36
|
+
params: params,
|
37
|
+
opts: opts,
|
38
|
+
base_address: :api
|
39
|
+
)
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|