stripe 17.3.0.pre.alpha.1 → 17.3.0.pre.alpha.2
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/lib/stripe/api_version.rb +1 -1
- data/lib/stripe/object_types.rb +1 -1
- data/lib/stripe/params/account_create_params.rb +33 -1
- data/lib/stripe/params/account_person_create_params.rb +33 -1
- data/lib/stripe/params/account_person_update_params.rb +33 -1
- data/lib/stripe/params/account_update_params.rb +33 -1
- data/lib/stripe/params/capital/financing_offer_create_params.rb +5 -5
- data/lib/stripe/params/capital/financing_offer_refill_params.rb +5 -5
- data/lib/stripe/params/delegated_checkout/requested_session_create_params.rb +1 -1
- data/lib/stripe/params/delegated_checkout/requested_session_update_params.rb +1 -1
- data/lib/stripe/params/invoice_create_preview_params.rb +57 -1
- data/lib/stripe/params/issuing/program_create_params.rb +21 -0
- data/lib/stripe/params/issuing/program_list_params.rb +24 -0
- data/lib/stripe/params/issuing/program_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/program_update_params.rb +21 -0
- data/lib/stripe/params/quote_create_params.rb +210 -2
- data/lib/stripe/params/quote_update_params.rb +210 -2
- data/lib/stripe/params/subscription_schedule_create_params.rb +62 -2
- data/lib/stripe/params/subscription_schedule_update_params.rb +62 -2
- data/lib/stripe/params/test_helpers/capital/financing_offer_create_params.rb +5 -5
- data/lib/stripe/params/test_helpers/capital/financing_offer_refill_params.rb +5 -5
- data/lib/stripe/params/token_create_params.rb +66 -2
- data/lib/stripe/params.rb +4 -5
- data/lib/stripe/resources/delegated_checkout/requested_session.rb +19 -1
- data/lib/stripe/resources/discount.rb +2 -0
- data/lib/stripe/resources/invoice.rb +16 -0
- data/lib/stripe/resources/invoice_item.rb +16 -0
- data/lib/stripe/resources/invoice_line_item.rb +16 -0
- data/lib/stripe/resources/issuing/program.rb +69 -0
- data/lib/stripe/resources/person.rb +36 -0
- data/lib/stripe/resources/quote.rb +348 -1
- data/lib/stripe/resources/quote_preview_invoice.rb +16 -0
- data/lib/stripe/resources/quote_preview_subscription_schedule.rb +174 -0
- data/lib/stripe/resources/subscription.rb +105 -2
- data/lib/stripe/resources/subscription_schedule.rb +174 -0
- data/lib/stripe/resources.rb +1 -1
- data/lib/stripe/services/issuing/program_service.rb +52 -0
- data/lib/stripe/services/issuing_service.rb +2 -1
- data/lib/stripe/services/v2_services.rb +1 -2
- data/lib/stripe/services.rb +1 -2
- data/lib/stripe/version.rb +1 -1
- data/rbi/stripe.rbi +2356 -203
- metadata +8 -10
- data/lib/stripe/params/v2/tax/automatic_rule_create_params.rb +0 -20
- data/lib/stripe/params/v2/tax/automatic_rule_deactivate_params.rb +0 -10
- data/lib/stripe/params/v2/tax/automatic_rule_find_params.rb +0 -17
- data/lib/stripe/params/v2/tax/automatic_rule_retrieve_params.rb +0 -10
- data/lib/stripe/params/v2/tax/automatic_rule_update_params.rb +0 -17
- data/lib/stripe/resources/v2/tax/automatic_rule.rb +0 -39
- data/lib/stripe/services/v2/tax/automatic_rule_service.rb +0 -65
- data/lib/stripe/services/v2/tax_service.rb +0 -15
|
@@ -3,6 +3,58 @@
|
|
|
3
3
|
|
|
4
4
|
module Stripe
|
|
5
5
|
class SubscriptionScheduleUpdateParams < ::Stripe::RequestParams
|
|
6
|
+
class BillingSchedule < ::Stripe::RequestParams
|
|
7
|
+
class AppliesTo < ::Stripe::RequestParams
|
|
8
|
+
# The ID of the price object.
|
|
9
|
+
attr_accessor :price
|
|
10
|
+
# Controls which subscription items the billing schedule applies to.
|
|
11
|
+
attr_accessor :type
|
|
12
|
+
|
|
13
|
+
def initialize(price: nil, type: nil)
|
|
14
|
+
@price = price
|
|
15
|
+
@type = type
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
class BillUntil < ::Stripe::RequestParams
|
|
20
|
+
class Duration < ::Stripe::RequestParams
|
|
21
|
+
# Specifies billing duration. Either `day`, `week`, `month` or `year`.
|
|
22
|
+
attr_accessor :interval
|
|
23
|
+
# The multiplier applied to the interval.
|
|
24
|
+
attr_accessor :interval_count
|
|
25
|
+
|
|
26
|
+
def initialize(interval: nil, interval_count: nil)
|
|
27
|
+
@interval = interval
|
|
28
|
+
@interval_count = interval_count
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
# Specifies the billing period.
|
|
32
|
+
attr_accessor :duration
|
|
33
|
+
# The end date of the billing schedule.
|
|
34
|
+
attr_accessor :timestamp
|
|
35
|
+
# Describes how the billing schedule will determine the end date. Either `duration` or `timestamp`.
|
|
36
|
+
attr_accessor :type
|
|
37
|
+
|
|
38
|
+
def initialize(duration: nil, timestamp: nil, type: nil)
|
|
39
|
+
@duration = duration
|
|
40
|
+
@timestamp = timestamp
|
|
41
|
+
@type = type
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
# Configure billing schedule differently for individual subscription items.
|
|
45
|
+
attr_accessor :applies_to
|
|
46
|
+
# The end date for the billing schedule.
|
|
47
|
+
attr_accessor :bill_until
|
|
48
|
+
# Specify a key for the billing schedule. Must be unique to this field, alphanumeric, and up to 200 characters. If not provided, a unique key will be generated.
|
|
49
|
+
attr_accessor :key
|
|
50
|
+
|
|
51
|
+
def initialize(applies_to: nil, bill_until: nil, key: nil)
|
|
52
|
+
@applies_to = applies_to
|
|
53
|
+
@bill_until = bill_until
|
|
54
|
+
@key = key
|
|
55
|
+
end
|
|
56
|
+
end
|
|
57
|
+
|
|
6
58
|
class DefaultSettings < ::Stripe::RequestParams
|
|
7
59
|
class AutomaticTax < ::Stripe::RequestParams
|
|
8
60
|
class Liability < ::Stripe::RequestParams
|
|
@@ -96,6 +148,8 @@ module Stripe
|
|
|
96
148
|
attr_accessor :on_behalf_of
|
|
97
149
|
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
|
|
98
150
|
attr_accessor :transfer_data
|
|
151
|
+
# Configures how the subscription schedule handles billing for phase transitions. Possible values are `phase_start` (default) or `billing_period_start`. `phase_start` bills based on the current state of the subscription, ignoring changes scheduled in future phases. `billing_period_start` bills predictively for upcoming phase transitions within the current billing cycle, including pricing changes and service period adjustments that will occur before the next invoice.
|
|
152
|
+
attr_accessor :phase_effective_at
|
|
99
153
|
|
|
100
154
|
def initialize(
|
|
101
155
|
application_fee_percent: nil,
|
|
@@ -107,7 +161,8 @@ module Stripe
|
|
|
107
161
|
description: nil,
|
|
108
162
|
invoice_settings: nil,
|
|
109
163
|
on_behalf_of: nil,
|
|
110
|
-
transfer_data: nil
|
|
164
|
+
transfer_data: nil,
|
|
165
|
+
phase_effective_at: nil
|
|
111
166
|
)
|
|
112
167
|
@application_fee_percent = application_fee_percent
|
|
113
168
|
@automatic_tax = automatic_tax
|
|
@@ -119,6 +174,7 @@ module Stripe
|
|
|
119
174
|
@invoice_settings = invoice_settings
|
|
120
175
|
@on_behalf_of = on_behalf_of
|
|
121
176
|
@transfer_data = transfer_data
|
|
177
|
+
@phase_effective_at = phase_effective_at
|
|
122
178
|
end
|
|
123
179
|
end
|
|
124
180
|
|
|
@@ -696,6 +752,8 @@ module Stripe
|
|
|
696
752
|
attr_accessor :prebilling
|
|
697
753
|
# If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
|
|
698
754
|
attr_accessor :proration_behavior
|
|
755
|
+
# Sets the billing schedules for the subscription schedule.
|
|
756
|
+
attr_accessor :billing_schedules
|
|
699
757
|
|
|
700
758
|
def initialize(
|
|
701
759
|
billing_behavior: nil,
|
|
@@ -705,7 +763,8 @@ module Stripe
|
|
|
705
763
|
metadata: nil,
|
|
706
764
|
phases: nil,
|
|
707
765
|
prebilling: nil,
|
|
708
|
-
proration_behavior: nil
|
|
766
|
+
proration_behavior: nil,
|
|
767
|
+
billing_schedules: nil
|
|
709
768
|
)
|
|
710
769
|
@billing_behavior = billing_behavior
|
|
711
770
|
@default_settings = default_settings
|
|
@@ -715,6 +774,7 @@ module Stripe
|
|
|
715
774
|
@phases = phases
|
|
716
775
|
@prebilling = prebilling
|
|
717
776
|
@proration_behavior = proration_behavior
|
|
777
|
+
@billing_schedules = billing_schedules
|
|
718
778
|
end
|
|
719
779
|
end
|
|
720
780
|
end
|
|
@@ -5,17 +5,17 @@ module Stripe
|
|
|
5
5
|
module TestHelpers
|
|
6
6
|
module Capital
|
|
7
7
|
class FinancingOfferCreateParams < ::Stripe::RequestParams
|
|
8
|
-
#
|
|
8
|
+
# Amount of financing offered, in minor units. For example, 1,000 USD is represented as 100000.
|
|
9
9
|
attr_accessor :advance_amount
|
|
10
10
|
# Specifies which fields in the response should be expanded.
|
|
11
11
|
attr_accessor :expand
|
|
12
|
-
#
|
|
12
|
+
# Fixed fee amount, in minor units. For example, 100 USD is represented as 10000.
|
|
13
13
|
attr_accessor :fee_amount
|
|
14
|
-
#
|
|
14
|
+
# The type of financing offer.
|
|
15
15
|
attr_accessor :financing_type
|
|
16
|
-
#
|
|
16
|
+
# The status of the financing offer.
|
|
17
17
|
attr_accessor :status
|
|
18
|
-
#
|
|
18
|
+
# Per-transaction rate at which Stripe withholds funds to repay the financing.
|
|
19
19
|
attr_accessor :withhold_rate
|
|
20
20
|
|
|
21
21
|
def initialize(
|
|
@@ -5,17 +5,17 @@ module Stripe
|
|
|
5
5
|
module TestHelpers
|
|
6
6
|
module Capital
|
|
7
7
|
class FinancingOfferRefillParams < ::Stripe::RequestParams
|
|
8
|
-
#
|
|
8
|
+
# Amount of financing offered, in minor units. For example, 1,000 USD is represented as 100000.
|
|
9
9
|
attr_accessor :advance_amount
|
|
10
10
|
# Specifies which fields in the response should be expanded.
|
|
11
11
|
attr_accessor :expand
|
|
12
|
-
#
|
|
12
|
+
# Fixed fee amount, in minor units. For example, 100 USD is represented as 10000.
|
|
13
13
|
attr_accessor :fee_amount
|
|
14
|
-
#
|
|
14
|
+
# The type of financing offer
|
|
15
15
|
attr_accessor :financing_type
|
|
16
|
-
#
|
|
16
|
+
# The status of the financing offer
|
|
17
17
|
attr_accessor :status
|
|
18
|
-
#
|
|
18
|
+
# Per-transaction rate at which Stripe withholds funds to repay the financing.
|
|
19
19
|
attr_accessor :withhold_rate
|
|
20
20
|
|
|
21
21
|
def initialize(
|
|
@@ -462,6 +462,30 @@ module Stripe
|
|
|
462
462
|
end
|
|
463
463
|
end
|
|
464
464
|
|
|
465
|
+
class SelfReportedIncome < ::Stripe::RequestParams
|
|
466
|
+
# Attribute for param field amount
|
|
467
|
+
attr_accessor :amount
|
|
468
|
+
# Attribute for param field currency
|
|
469
|
+
attr_accessor :currency
|
|
470
|
+
|
|
471
|
+
def initialize(amount: nil, currency: nil)
|
|
472
|
+
@amount = amount
|
|
473
|
+
@currency = currency
|
|
474
|
+
end
|
|
475
|
+
end
|
|
476
|
+
|
|
477
|
+
class SelfReportedMonthlyHousingPayment < ::Stripe::RequestParams
|
|
478
|
+
# Attribute for param field amount
|
|
479
|
+
attr_accessor :amount
|
|
480
|
+
# Attribute for param field currency
|
|
481
|
+
attr_accessor :currency
|
|
482
|
+
|
|
483
|
+
def initialize(amount: nil, currency: nil)
|
|
484
|
+
@amount = amount
|
|
485
|
+
@currency = currency
|
|
486
|
+
end
|
|
487
|
+
end
|
|
488
|
+
|
|
465
489
|
class Verification < ::Stripe::RequestParams
|
|
466
490
|
class AdditionalDocument < ::Stripe::RequestParams
|
|
467
491
|
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
|
|
@@ -542,6 +566,10 @@ module Stripe
|
|
|
542
566
|
attr_accessor :ssn_last_4
|
|
543
567
|
# The individual's verification document information.
|
|
544
568
|
attr_accessor :verification
|
|
569
|
+
# The credit applicant's self-reported yearly income in minor units.
|
|
570
|
+
attr_accessor :self_reported_income
|
|
571
|
+
# The credit applicant's self-reported monthly housing payment in minor units.
|
|
572
|
+
attr_accessor :self_reported_monthly_housing_payment
|
|
545
573
|
|
|
546
574
|
def initialize(
|
|
547
575
|
address: nil,
|
|
@@ -566,7 +594,9 @@ module Stripe
|
|
|
566
594
|
registered_address: nil,
|
|
567
595
|
relationship: nil,
|
|
568
596
|
ssn_last_4: nil,
|
|
569
|
-
verification: nil
|
|
597
|
+
verification: nil,
|
|
598
|
+
self_reported_income: nil,
|
|
599
|
+
self_reported_monthly_housing_payment: nil
|
|
570
600
|
)
|
|
571
601
|
@address = address
|
|
572
602
|
@address_kana = address_kana
|
|
@@ -591,6 +621,8 @@ module Stripe
|
|
|
591
621
|
@relationship = relationship
|
|
592
622
|
@ssn_last_4 = ssn_last_4
|
|
593
623
|
@verification = verification
|
|
624
|
+
@self_reported_income = self_reported_income
|
|
625
|
+
@self_reported_monthly_housing_payment = self_reported_monthly_housing_payment
|
|
594
626
|
end
|
|
595
627
|
end
|
|
596
628
|
# The business type.
|
|
@@ -976,6 +1008,30 @@ module Stripe
|
|
|
976
1008
|
end
|
|
977
1009
|
end
|
|
978
1010
|
|
|
1011
|
+
class SelfReportedIncome < ::Stripe::RequestParams
|
|
1012
|
+
# Attribute for param field amount
|
|
1013
|
+
attr_accessor :amount
|
|
1014
|
+
# Attribute for param field currency
|
|
1015
|
+
attr_accessor :currency
|
|
1016
|
+
|
|
1017
|
+
def initialize(amount: nil, currency: nil)
|
|
1018
|
+
@amount = amount
|
|
1019
|
+
@currency = currency
|
|
1020
|
+
end
|
|
1021
|
+
end
|
|
1022
|
+
|
|
1023
|
+
class SelfReportedMonthlyHousingPayment < ::Stripe::RequestParams
|
|
1024
|
+
# Attribute for param field amount
|
|
1025
|
+
attr_accessor :amount
|
|
1026
|
+
# Attribute for param field currency
|
|
1027
|
+
attr_accessor :currency
|
|
1028
|
+
|
|
1029
|
+
def initialize(amount: nil, currency: nil)
|
|
1030
|
+
@amount = amount
|
|
1031
|
+
@currency = currency
|
|
1032
|
+
end
|
|
1033
|
+
end
|
|
1034
|
+
|
|
979
1035
|
class UsCfpbData < ::Stripe::RequestParams
|
|
980
1036
|
class EthnicityDetails < ::Stripe::RequestParams
|
|
981
1037
|
# The persons ethnicity
|
|
@@ -1102,6 +1158,10 @@ module Stripe
|
|
|
1102
1158
|
attr_accessor :us_cfpb_data
|
|
1103
1159
|
# The person's verification status.
|
|
1104
1160
|
attr_accessor :verification
|
|
1161
|
+
# The credit applicant's self-reported yearly income in minor units.
|
|
1162
|
+
attr_accessor :self_reported_income
|
|
1163
|
+
# The credit applicant's self-reported monthly housing payment in minor units.
|
|
1164
|
+
attr_accessor :self_reported_monthly_housing_payment
|
|
1105
1165
|
|
|
1106
1166
|
def initialize(
|
|
1107
1167
|
additional_tos_acceptances: nil,
|
|
@@ -1130,7 +1190,9 @@ module Stripe
|
|
|
1130
1190
|
relationship: nil,
|
|
1131
1191
|
ssn_last_4: nil,
|
|
1132
1192
|
us_cfpb_data: nil,
|
|
1133
|
-
verification: nil
|
|
1193
|
+
verification: nil,
|
|
1194
|
+
self_reported_income: nil,
|
|
1195
|
+
self_reported_monthly_housing_payment: nil
|
|
1134
1196
|
)
|
|
1135
1197
|
@additional_tos_acceptances = additional_tos_acceptances
|
|
1136
1198
|
@address = address
|
|
@@ -1159,6 +1221,8 @@ module Stripe
|
|
|
1159
1221
|
@ssn_last_4 = ssn_last_4
|
|
1160
1222
|
@us_cfpb_data = us_cfpb_data
|
|
1161
1223
|
@verification = verification
|
|
1224
|
+
@self_reported_income = self_reported_income
|
|
1225
|
+
@self_reported_monthly_housing_payment = self_reported_monthly_housing_payment
|
|
1162
1226
|
end
|
|
1163
1227
|
end
|
|
1164
1228
|
|
data/lib/stripe/params.rb
CHANGED
|
@@ -303,6 +303,10 @@ require "stripe/params/issuing/personalization_design_retrieve_params"
|
|
|
303
303
|
require "stripe/params/issuing/personalization_design_update_params"
|
|
304
304
|
require "stripe/params/issuing/physical_bundle_list_params"
|
|
305
305
|
require "stripe/params/issuing/physical_bundle_retrieve_params"
|
|
306
|
+
require "stripe/params/issuing/program_create_params"
|
|
307
|
+
require "stripe/params/issuing/program_list_params"
|
|
308
|
+
require "stripe/params/issuing/program_retrieve_params"
|
|
309
|
+
require "stripe/params/issuing/program_update_params"
|
|
306
310
|
require "stripe/params/issuing/token_list_params"
|
|
307
311
|
require "stripe/params/issuing/token_retrieve_params"
|
|
308
312
|
require "stripe/params/issuing/token_update_params"
|
|
@@ -837,11 +841,6 @@ require "stripe/params/v2/payments/off_session_payment_retrieve_params"
|
|
|
837
841
|
require "stripe/params/v2/reporting/report_retrieve_params"
|
|
838
842
|
require "stripe/params/v2/reporting/report_run_create_params"
|
|
839
843
|
require "stripe/params/v2/reporting/report_run_retrieve_params"
|
|
840
|
-
require "stripe/params/v2/tax/automatic_rule_create_params"
|
|
841
|
-
require "stripe/params/v2/tax/automatic_rule_deactivate_params"
|
|
842
|
-
require "stripe/params/v2/tax/automatic_rule_find_params"
|
|
843
|
-
require "stripe/params/v2/tax/automatic_rule_retrieve_params"
|
|
844
|
-
require "stripe/params/v2/tax/automatic_rule_update_params"
|
|
845
844
|
require "stripe/params/v2/test_helpers/financial_address_credit_params"
|
|
846
845
|
require "stripe/params/v2/test_helpers/financial_address_generate_microdeposits_params"
|
|
847
846
|
require "stripe/params/v2/test_helpers/money_management_recipient_verifications_params"
|
|
@@ -189,15 +189,33 @@ module Stripe
|
|
|
189
189
|
end
|
|
190
190
|
|
|
191
191
|
class TotalDetails < ::Stripe::StripeObject
|
|
192
|
+
class ApplicableFee < ::Stripe::StripeObject
|
|
193
|
+
# The amount of the applicable fee.
|
|
194
|
+
attr_reader :amount
|
|
195
|
+
# The description of the applicable fee.
|
|
196
|
+
attr_reader :description
|
|
197
|
+
# The display name of the applicable fee.
|
|
198
|
+
attr_reader :display_name
|
|
199
|
+
|
|
200
|
+
def self.inner_class_types
|
|
201
|
+
@inner_class_types = {}
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
def self.field_remappings
|
|
205
|
+
@field_remappings = {}
|
|
206
|
+
end
|
|
207
|
+
end
|
|
192
208
|
# The amount discount of the total details.
|
|
193
209
|
attr_reader :amount_discount
|
|
194
210
|
# The amount fulfillment of the total details.
|
|
195
211
|
attr_reader :amount_fulfillment
|
|
196
212
|
# The amount tax of the total details.
|
|
197
213
|
attr_reader :amount_tax
|
|
214
|
+
# The applicable fees of the total details.
|
|
215
|
+
attr_reader :applicable_fees
|
|
198
216
|
|
|
199
217
|
def self.inner_class_types
|
|
200
|
-
@inner_class_types = {}
|
|
218
|
+
@inner_class_types = { applicable_fees: ApplicableFee }
|
|
201
219
|
end
|
|
202
220
|
|
|
203
221
|
def self.field_remappings
|
|
@@ -52,6 +52,8 @@ module Stripe
|
|
|
52
52
|
attr_reader :subscription
|
|
53
53
|
# The subscription item that this coupon is applied to, if it is applied to a particular subscription item.
|
|
54
54
|
attr_reader :subscription_item
|
|
55
|
+
# The subscription schedule that this coupon is applied to, if it is applied to a particular subscription schedule.
|
|
56
|
+
attr_reader :schedule
|
|
55
57
|
# Always true for a deleted object
|
|
56
58
|
attr_reader :deleted
|
|
57
59
|
|
|
@@ -356,6 +356,19 @@ module Stripe
|
|
|
356
356
|
end
|
|
357
357
|
end
|
|
358
358
|
|
|
359
|
+
class ScheduleDetails < ::Stripe::StripeObject
|
|
360
|
+
# The schedule that generated this invoice
|
|
361
|
+
attr_reader :schedule
|
|
362
|
+
|
|
363
|
+
def self.inner_class_types
|
|
364
|
+
@inner_class_types = {}
|
|
365
|
+
end
|
|
366
|
+
|
|
367
|
+
def self.field_remappings
|
|
368
|
+
@field_remappings = {}
|
|
369
|
+
end
|
|
370
|
+
end
|
|
371
|
+
|
|
359
372
|
class SubscriptionDetails < ::Stripe::StripeObject
|
|
360
373
|
class PauseCollection < ::Stripe::StripeObject
|
|
361
374
|
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
|
|
@@ -397,12 +410,15 @@ module Stripe
|
|
|
397
410
|
attr_reader :subscription_details
|
|
398
411
|
# The type of parent that generated this invoice
|
|
399
412
|
attr_reader :type
|
|
413
|
+
# Details about the schedule that generated this invoice
|
|
414
|
+
attr_reader :schedule_details
|
|
400
415
|
|
|
401
416
|
def self.inner_class_types
|
|
402
417
|
@inner_class_types = {
|
|
403
418
|
billing_cadence_details: BillingCadenceDetails,
|
|
404
419
|
quote_details: QuoteDetails,
|
|
405
420
|
subscription_details: SubscriptionDetails,
|
|
421
|
+
schedule_details: ScheduleDetails,
|
|
406
422
|
}
|
|
407
423
|
end
|
|
408
424
|
|
|
@@ -60,6 +60,19 @@ module Stripe
|
|
|
60
60
|
end
|
|
61
61
|
end
|
|
62
62
|
|
|
63
|
+
class ScheduleDetails < ::Stripe::StripeObject
|
|
64
|
+
# The subscription schedule that generated this invoice item
|
|
65
|
+
attr_reader :schedule
|
|
66
|
+
|
|
67
|
+
def self.inner_class_types
|
|
68
|
+
@inner_class_types = {}
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
def self.field_remappings
|
|
72
|
+
@field_remappings = {}
|
|
73
|
+
end
|
|
74
|
+
end
|
|
75
|
+
|
|
63
76
|
class SubscriptionDetails < ::Stripe::StripeObject
|
|
64
77
|
# The subscription that generated this invoice item
|
|
65
78
|
attr_reader :subscription
|
|
@@ -82,12 +95,15 @@ module Stripe
|
|
|
82
95
|
attr_reader :subscription_details
|
|
83
96
|
# The type of parent that generated this invoice item
|
|
84
97
|
attr_reader :type
|
|
98
|
+
# Details about the subscription schedule that generated this invoice item
|
|
99
|
+
attr_reader :schedule_details
|
|
85
100
|
|
|
86
101
|
def self.inner_class_types
|
|
87
102
|
@inner_class_types = {
|
|
88
103
|
license_fee_subscription_details: LicenseFeeSubscriptionDetails,
|
|
89
104
|
rate_card_subscription_details: RateCardSubscriptionDetails,
|
|
90
105
|
subscription_details: SubscriptionDetails,
|
|
106
|
+
schedule_details: ScheduleDetails,
|
|
91
107
|
}
|
|
92
108
|
end
|
|
93
109
|
|
|
@@ -131,6 +131,19 @@ module Stripe
|
|
|
131
131
|
end
|
|
132
132
|
end
|
|
133
133
|
|
|
134
|
+
class ScheduleDetails < ::Stripe::StripeObject
|
|
135
|
+
# The subscription schedule that generated this line item
|
|
136
|
+
attr_reader :schedule
|
|
137
|
+
|
|
138
|
+
def self.inner_class_types
|
|
139
|
+
@inner_class_types = {}
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
def self.field_remappings
|
|
143
|
+
@field_remappings = {}
|
|
144
|
+
end
|
|
145
|
+
end
|
|
146
|
+
|
|
134
147
|
class SubscriptionItemDetails < ::Stripe::StripeObject
|
|
135
148
|
class ProrationDetails < ::Stripe::StripeObject
|
|
136
149
|
class CreditedItems < ::Stripe::StripeObject
|
|
@@ -187,6 +200,8 @@ module Stripe
|
|
|
187
200
|
attr_reader :subscription_item_details
|
|
188
201
|
# The type of parent that generated this line item
|
|
189
202
|
attr_reader :type
|
|
203
|
+
# Details about the subscription schedule that generated this line item
|
|
204
|
+
attr_reader :schedule_details
|
|
190
205
|
|
|
191
206
|
def self.inner_class_types
|
|
192
207
|
@inner_class_types = {
|
|
@@ -194,6 +209,7 @@ module Stripe
|
|
|
194
209
|
license_fee_subscription_details: LicenseFeeSubscriptionDetails,
|
|
195
210
|
rate_card_subscription_details: RateCardSubscriptionDetails,
|
|
196
211
|
subscription_item_details: SubscriptionItemDetails,
|
|
212
|
+
schedule_details: ScheduleDetails,
|
|
197
213
|
}
|
|
198
214
|
end
|
|
199
215
|
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module Stripe
|
|
5
|
+
module Issuing
|
|
6
|
+
# An Issuing `Program` represents a card program that the user has access to.
|
|
7
|
+
class Program < APIResource
|
|
8
|
+
extend Stripe::APIOperations::Create
|
|
9
|
+
extend Stripe::APIOperations::List
|
|
10
|
+
include Stripe::APIOperations::Save
|
|
11
|
+
|
|
12
|
+
OBJECT_NAME = "issuing.program"
|
|
13
|
+
def self.object_name
|
|
14
|
+
"issuing.program"
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
# Time at which the object was created. Measured in seconds since the Unix epoch.
|
|
18
|
+
attr_reader :created
|
|
19
|
+
# Unique identifier for the object.
|
|
20
|
+
attr_reader :id
|
|
21
|
+
# Whether or not this is the "default" issuing program new cards are created on. Only one active `is_default` program at the same time.
|
|
22
|
+
attr_reader :is_default
|
|
23
|
+
# 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.
|
|
24
|
+
attr_reader :metadata
|
|
25
|
+
# String representing the object's type. Objects of the same type share the same value.
|
|
26
|
+
attr_reader :object
|
|
27
|
+
# The platform's Issuing Program for which this program is associated.
|
|
28
|
+
attr_reader :platform_program
|
|
29
|
+
|
|
30
|
+
# Create a Program object.
|
|
31
|
+
def self.create(params = {}, opts = {})
|
|
32
|
+
request_stripe_object(
|
|
33
|
+
method: :post,
|
|
34
|
+
path: "/v1/issuing/programs",
|
|
35
|
+
params: params,
|
|
36
|
+
opts: opts
|
|
37
|
+
)
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
# List all of the programs the given Issuing user has access to.
|
|
41
|
+
def self.list(params = {}, opts = {})
|
|
42
|
+
request_stripe_object(
|
|
43
|
+
method: :get,
|
|
44
|
+
path: "/v1/issuing/programs",
|
|
45
|
+
params: params,
|
|
46
|
+
opts: opts
|
|
47
|
+
)
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
# Updates a Program object.
|
|
51
|
+
def self.update(program, params = {}, opts = {})
|
|
52
|
+
request_stripe_object(
|
|
53
|
+
method: :post,
|
|
54
|
+
path: format("/v1/issuing/programs/%<program>s", { program: CGI.escape(program) }),
|
|
55
|
+
params: params,
|
|
56
|
+
opts: opts
|
|
57
|
+
)
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
def self.inner_class_types
|
|
61
|
+
@inner_class_types = {}
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
def self.field_remappings
|
|
65
|
+
@field_remappings = {}
|
|
66
|
+
end
|
|
67
|
+
end
|
|
68
|
+
end
|
|
69
|
+
end
|
|
@@ -395,6 +395,36 @@ module Stripe
|
|
|
395
395
|
@field_remappings = {}
|
|
396
396
|
end
|
|
397
397
|
end
|
|
398
|
+
|
|
399
|
+
class SelfReportedIncome < ::Stripe::StripeObject
|
|
400
|
+
# Amount in the minor currency unit (e.g., cents for USD)
|
|
401
|
+
attr_reader :amount
|
|
402
|
+
# 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).
|
|
403
|
+
attr_reader :currency
|
|
404
|
+
|
|
405
|
+
def self.inner_class_types
|
|
406
|
+
@inner_class_types = {}
|
|
407
|
+
end
|
|
408
|
+
|
|
409
|
+
def self.field_remappings
|
|
410
|
+
@field_remappings = {}
|
|
411
|
+
end
|
|
412
|
+
end
|
|
413
|
+
|
|
414
|
+
class SelfReportedMonthlyHousingPayment < ::Stripe::StripeObject
|
|
415
|
+
# Amount in the minor currency unit (e.g., cents for USD)
|
|
416
|
+
attr_reader :amount
|
|
417
|
+
# 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).
|
|
418
|
+
attr_reader :currency
|
|
419
|
+
|
|
420
|
+
def self.inner_class_types
|
|
421
|
+
@inner_class_types = {}
|
|
422
|
+
end
|
|
423
|
+
|
|
424
|
+
def self.field_remappings
|
|
425
|
+
@field_remappings = {}
|
|
426
|
+
end
|
|
427
|
+
end
|
|
398
428
|
# The account the person is associated with.
|
|
399
429
|
attr_reader :account
|
|
400
430
|
# Attribute for field additional_tos_acceptances
|
|
@@ -459,6 +489,10 @@ module Stripe
|
|
|
459
489
|
attr_reader :us_cfpb_data
|
|
460
490
|
# Attribute for field verification
|
|
461
491
|
attr_reader :verification
|
|
492
|
+
# Attribute for field self_reported_income
|
|
493
|
+
attr_reader :self_reported_income
|
|
494
|
+
# Attribute for field self_reported_monthly_housing_payment
|
|
495
|
+
attr_reader :self_reported_monthly_housing_payment
|
|
462
496
|
# Always true for a deleted object
|
|
463
497
|
attr_reader :deleted
|
|
464
498
|
|
|
@@ -496,6 +530,8 @@ module Stripe
|
|
|
496
530
|
requirements: Requirements,
|
|
497
531
|
us_cfpb_data: UsCfpbData,
|
|
498
532
|
verification: Verification,
|
|
533
|
+
self_reported_income: SelfReportedIncome,
|
|
534
|
+
self_reported_monthly_housing_payment: SelfReportedMonthlyHousingPayment,
|
|
499
535
|
}
|
|
500
536
|
end
|
|
501
537
|
|