stripe 10.2.0 → 10.3.0.pre.beta.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (41) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +244 -40
  3. data/OPENAPI_VERSION +1 -1
  4. data/README.md +11 -0
  5. data/VERSION +1 -1
  6. data/lib/stripe/api_operations/request.rb +2 -0
  7. data/lib/stripe/api_version.rb +1 -0
  8. data/lib/stripe/object_types.rb +21 -0
  9. data/lib/stripe/request_signing_authenticator.rb +79 -0
  10. data/lib/stripe/resources/account_notice.rb +14 -0
  11. data/lib/stripe/resources/capital/financing_offer.rb +32 -0
  12. data/lib/stripe/resources/capital/financing_summary.rb +12 -0
  13. data/lib/stripe/resources/capital/financing_transaction.rb +13 -0
  14. data/lib/stripe/resources/confirmation_token.rb +11 -0
  15. data/lib/stripe/resources/customer_session.rb +12 -0
  16. data/lib/stripe/resources/financial_connections/account.rb +39 -0
  17. data/lib/stripe/resources/financial_connections/account_inferred_balance.rb +13 -0
  18. data/lib/stripe/resources/financial_connections/transaction.rb +13 -0
  19. data/lib/stripe/resources/gift_cards/card.rb +25 -0
  20. data/lib/stripe/resources/gift_cards/transaction.rb +56 -0
  21. data/lib/stripe/resources/invoice.rb +21 -0
  22. data/lib/stripe/resources/invoice_payment.rb +11 -0
  23. data/lib/stripe/resources/issuing/credit_underwriting_record.rb +69 -0
  24. data/lib/stripe/resources/issuing/personalization_design.rb +77 -0
  25. data/lib/stripe/resources/issuing/physical_bundle.rb +13 -0
  26. data/lib/stripe/resources/margin.rb +14 -0
  27. data/lib/stripe/resources/order.rb +89 -0
  28. data/lib/stripe/resources/quote.rb +94 -0
  29. data/lib/stripe/resources/quote_phase.rb +29 -0
  30. data/lib/stripe/resources/quote_preview_invoice.rb +42 -0
  31. data/lib/stripe/resources/quote_preview_subscription_schedule.rb +10 -0
  32. data/lib/stripe/resources/subscription_schedule.rb +18 -0
  33. data/lib/stripe/resources/tax/form.rb +39 -0
  34. data/lib/stripe/resources/terminal/reader.rb +54 -0
  35. data/lib/stripe/resources.rb +20 -0
  36. data/lib/stripe/stripe_client.rb +61 -27
  37. data/lib/stripe/stripe_configuration.rb +2 -1
  38. data/lib/stripe/util.rb +8 -1
  39. data/lib/stripe/version.rb +1 -1
  40. data/lib/stripe.rb +46 -0
  41. metadata +24 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1175af77634044ef0ef6efda0626ace1431bdb4ad52eb78c643af4eba8982faf
4
- data.tar.gz: 19863ceeab18b449560dc647213d5873eadb190db544015e88749b5e79414528
3
+ metadata.gz: 99e6b9749e8b1212d2c4b42f40c49b220ea10132346b5c8a4eb96894bc06247f
4
+ data.tar.gz: 76680576e92e252db64df9543df2b1befde7dd1bff4c2d4d74fe946af068a60c
5
5
  SHA512:
6
- metadata.gz: 24f1e67f729c964e150bf991140467c85d2b85430da3a7d736cd6b6ae5a9ce8afac2664e27fb3df51d472eb23b1ae67f5933e019e8c6fd9c7639d32e4713a334
7
- data.tar.gz: 28dee05f7251e400ba32ace17cb0e8e78f63bfa156ba36c9d6f3baa7cc6d361d0e86826a962a117e70cd774628183eddf70d0379c9c485a74192b9844c3855c5
6
+ metadata.gz: c65eb672e988647ccb5844d722f57cb82d6d7ac2da7e4ee095678104ae8f2a04c2e2bb65abf34aecfcf235838b18cb4a93f6cd3b7d96075f2e4d8a7308b57efc
7
+ data.tar.gz: 8225c92b8ee117d57a968bbe13b2f9edc274ffae4fd3fd669a749a1e34a9efa1f34965db93ac435d7f8026ed5a1c40fc373b487e80a30be36a5eb0f2728037b0
data/CHANGELOG.md CHANGED
@@ -1,4 +1,9 @@
1
1
  # Changelog
2
+
3
+ ## 10.3.0-beta.1 - 2023-11-30
4
+ * [#1298](https://github.com/stripe/stripe-ruby/pull/1298) Update generated code for beta
5
+ * [#1296](https://github.com/stripe/stripe-ruby/pull/1296) Merge master into beta
6
+
2
7
  ## 10.2.0 - 2023-11-30
3
8
  * [#1292](https://github.com/stripe/stripe-ruby/pull/1292) Update generated code
4
9
  * Add support for new resources `Climate.Order`, `Climate.Product`, and `Climate.Supplier`
@@ -11,12 +16,26 @@
11
16
 
12
17
  * [#1288](https://github.com/stripe/stripe-ruby/pull/1288) Update generated code
13
18
 
19
+ ## 10.2.0-beta.1 - 2023-11-02
20
+ * [#1287](https://github.com/stripe/stripe-ruby/pull/1287) Update generated code for beta
21
+ * Add support for `attach_payment_intent` method on resource `Invoice`
22
+ * [#1285](https://github.com/stripe/stripe-ruby/pull/1285) Update generated code for beta
14
23
 
15
24
  ## 10.1.0 - 2023-11-02
16
25
  * [#1286](https://github.com/stripe/stripe-ruby/pull/1286) Update generated code
17
26
  * Add support for new resource `Tax.Registration`
18
27
  * Add support for `create`, `list`, and `update` methods on resource `Registration`
19
28
 
29
+ ## 10.1.0-beta.2 - 2023-10-26
30
+ * [#1285](https://github.com/stripe/stripe-ruby/pull/1285) Update generated code for beta
31
+ * Add support for new resource `Margin`
32
+ * Add support for `create`, `list`, `retrieve`, and `update` methods on resource `Margin`
33
+
34
+ ## 10.1.0-beta.1 - 2023-10-17
35
+ * [#1284](https://github.com/stripe/stripe-ruby/pull/1284) Update generated code for beta
36
+ - Update pinned API version to `2023-10-16`
37
+ * [#1282](https://github.com/stripe/stripe-ruby/pull/1282) Update generated code for beta
38
+
20
39
  ## 10.0.0 - 2023-10-16
21
40
  * This release changes the pinned API version to `2023-10-16`. Please read the [API Upgrade Guide](https://stripe.com/docs/upgrades#2023-10-16) and carefully review the API changes before upgrading `stripe-ruby`.
22
41
  * [#1283](https://github.com/stripe/stripe-ruby/pull/1283) Update generated code
@@ -24,11 +43,33 @@
24
43
  * [#1281](https://github.com/stripe/stripe-ruby/pull/1281) Update generated code
25
44
  * Documentation only changes
26
45
 
46
+ ## 9.5.0-beta.2 - 2023-10-12
47
+ * [#1280](https://github.com/stripe/stripe-ruby/pull/1280) Update generated code for beta
48
+ * Add support for new resources `AccountNotice` and `Issuing.CreditUnderwritingRecord`
49
+ * Add support for `list`, `retrieve`, and `update` methods on resource `AccountNotice`
50
+ * Add support for `correct`, `create_from_application`, `create_from_proactive_review`, `list`, `report_decision`, and `retrieve` methods on resource `CreditUnderwritingRecord`
51
+
52
+ ## 9.5.0-beta.1 - 2023-10-05
53
+ * [#1278](https://github.com/stripe/stripe-ruby/pull/1278) Update generated code for beta
54
+ * Add support for `mark_draft` and `mark_stale` methods on resource `Quote`
55
+ * Remove support for `draft_quote` and `mark_stale_quote` methods on resource `Quote`
56
+ * Rename `preview_invoice_lines` to `list_preview_invoice_lines` on resource `Quote`
57
+
27
58
  ## 9.4.0 - 2023-10-05
28
59
  * [#1277](https://github.com/stripe/stripe-ruby/pull/1277) Update generated code
29
60
  * Add support for new resources `Issuing.Token`
30
61
  * Add support for `list`, `retrieve`, and `update` methods on resource `Token`
31
62
 
63
+ ## 9.4.0-beta.3 - 2023-09-28
64
+ * [#1276](https://github.com/stripe/stripe-ruby/pull/1276) Update generated code for beta
65
+ * Rename resources `Issuing.CardDesign` and `Issuing.CardBundle` to `Issuing.PersonalizationDesign` and `Issuing.PhysicalBundle`
66
+
67
+ ## 9.4.0-beta.2 - 2023-09-21
68
+ * [#1273](https://github.com/stripe/stripe-ruby/pull/1273) Update generated code for beta
69
+
70
+ ## 9.4.0-beta.1 - 2023-09-14
71
+ * Updated stable APIs to the latest version
72
+
32
73
  ## 9.3.0 - 2023-09-14
33
74
  * [#1272](https://github.com/stripe/stripe-ruby/pull/1272) Update generated code
34
75
  * Add support for new resource `PaymentMethodConfiguration`
@@ -37,18 +78,38 @@
37
78
  * Add support for `capture`, `create`, `expire`, `increment`, and `reverse` test helper methods on resource `Issuing.Authorization`
38
79
  * Add support for `create_force_capture`, `create_unlinked_refund`, and `refund` test helper methods on resource `Issuing.Transaction`
39
80
 
81
+ ## 9.3.0-beta.1 - 2023-09-07
82
+ * [#1269](https://github.com/stripe/stripe-ruby/pull/1269) Update generated code for beta
83
+ * Release specs are identical.
84
+ * [#1268](https://github.com/stripe/stripe-ruby/pull/1268) Update generated code for beta
85
+ * Remove support for `submit_card` test helper method on resource `Issuing.Card`
86
+ * [#1265](https://github.com/stripe/stripe-ruby/pull/1265) Update generated code for beta
87
+ * Rename `Quote.preview_invoices` to `QuotePreviewInvoice.list` and `Quote.preview_schedules` to `QuotePreviewSchedules.list`
88
+ * [#1264](https://github.com/stripe/stripe-ruby/pull/1264) Update generated code for beta
89
+ * Add support for new resources `QuotePreviewInvoice` and `QuotePreviewSchedule`
90
+ * [#1259](https://github.com/stripe/stripe-ruby/pull/1259) Update generated code for beta
91
+
92
+ * [#1257](https://github.com/stripe/stripe-ruby/pull/1257) Update generated code for beta
93
+
94
+ * [#1254](https://github.com/stripe/stripe-ruby/pull/1254) Update generated code for beta
95
+ * Add support for `submit_card` test helper method on resource `Issuing.Card`
96
+ * [#1252](https://github.com/stripe/stripe-ruby/pull/1252) Remove developer_message support
97
+
40
98
  ## 9.2.0 - 2023-09-07
41
99
  * [#1267](https://github.com/stripe/stripe-ruby/pull/1267) Update generated code
42
100
  * Add support for new resource `PaymentMethodDomain`
43
101
  * Add support for `create`, `list`, `retrieve`, `update`, and `validate` methods on resource `PaymentMethodDomain`
44
102
 
103
+ ## 9.2.0-beta.1 - 2023-08-31
104
+ * [#1265](https://github.com/stripe/stripe-ruby/pull/1265) Update generated code for beta
105
+ * Rename `Quote.preview_invoices` to `QuotePreviewInvoice.list` and `Quote.preview_schedules` to `QuotePreviewSchedules.list`
106
+
45
107
  ## 9.1.0 - 2023-08-31
46
108
  * [#1266](https://github.com/stripe/stripe-ruby/pull/1266) Update generated code
47
109
  * Add support for new resource `AccountSession`
48
110
  * Add support for `create` method on resource `AccountSession`
49
111
  * [#1262](https://github.com/stripe/stripe-ruby/pull/1262) Explicitly format timestamp in SignatureVerificationError message
50
112
 
51
-
52
113
  ## 9.0.0 - 2023-08-16
53
114
  **⚠️ ACTION REQUIRED: the breaking change in this release likely affects you ⚠️**
54
115
 
@@ -81,10 +142,39 @@
81
142
 
82
143
  That is, instead of upgrading stripe-ruby and separately upgrading your Stripe API Version through the Stripe Dashboard. whenever you upgrade major versions of stripe-ruby, you should also upgrade your integration to be compatible with the latest Stripe API version.
83
144
 
145
+ ## 9.0.0-beta.1 - 2023-08-24
146
+ * [#1264](https://github.com/stripe/stripe-ruby/pull/1264) Update generated code for beta
147
+ * Add support for new resources `QuotePreviewInvoice` and `QuotePreviewSchedule`
148
+ * [#1259](https://github.com/stripe/stripe-ruby/pull/1259) Update generated code for beta
149
+
150
+ ## 8.8.0-beta.1 - 2023-08-10
151
+ * [#1257](https://github.com/stripe/stripe-ruby/pull/1257) Update generated code for beta
152
+ * Updated stable APIs to the latest version
153
+
84
154
  ## 8.7.0 - 2023-08-10
85
155
  * [#1256](https://github.com/stripe/stripe-ruby/pull/1256) Update generated code
86
156
  Add resources `Tax::CalculationLineItem`, `Tax::TransactionLineItem`, and `Treasury::FinancialAccountFeatures`. These resources have no methods on them, but do represent the return type of methods elsewhere.
87
157
 
158
+ ## 8.7.0-beta.3 - 2023-08-03
159
+ * [#1254](https://github.com/stripe/stripe-ruby/pull/1254) Update generated code for beta
160
+ * Add support for `submit_card` test helper method on resource `Issuing.Card`
161
+ * [#1252](https://github.com/stripe/stripe-ruby/pull/1252) Remove developer_message support
162
+
163
+ ## 8.7.0-beta.2 - 2023-07-28
164
+ * [#1251](https://github.com/stripe/stripe-ruby/pull/1251) Update generated code for beta
165
+ * Add support for new resource `Tax.Form`
166
+ * Add support for `list`, `pdf`, and `retrieve` methods on resource `Form`
167
+ * [#1249](https://github.com/stripe/stripe-ruby/pull/1249) Update generated code for beta
168
+ * [#1246](https://github.com/stripe/stripe-ruby/pull/1246) Update generated code for beta
169
+
170
+ ## 8.7.0-beta.1 - 2023-07-13
171
+ * [#1245](https://github.com/stripe/stripe-ruby/pull/1245) Update generated code for beta
172
+ Release specs are identical.
173
+ * [#1243](https://github.com/stripe/stripe-ruby/pull/1243) Update generated code for beta
174
+ * Add support for new resource `PaymentMethodConfiguration`
175
+ * Add support for `create`, `list`, `retrieve`, and `update` methods on resource `PaymentMethodConfiguration`
176
+ * [#1239](https://github.com/stripe/stripe-ruby/pull/1239) Update generated code for beta
177
+
88
178
  ## 8.6.0 - 2023-07-13
89
179
  * [#1244](https://github.com/stripe/stripe-ruby/pull/1244) Update generated code
90
180
  * Add support for new resource `Tax.Settings`
@@ -113,6 +203,37 @@
113
203
 
114
204
  * [#1204](https://github.com/stripe/stripe-ruby/pull/1204) Update generated code
115
205
 
206
+ ## 8.6.0-beta.6 - 2023-06-22
207
+ * [#1237](https://github.com/stripe/stripe-ruby/pull/1237) Update generated code for beta
208
+ * Add support for new resource `CustomerSession`
209
+ * Add support for `create` method on resource `CustomerSession`
210
+ * [#1233](https://github.com/stripe/stripe-ruby/pull/1233) Update generated code for beta
211
+ * [#1229](https://github.com/stripe/stripe-ruby/pull/1229) Update generated code for beta
212
+
213
+ ## 8.6.0-beta.5 - 2023-06-01
214
+ * [#1227](https://github.com/stripe/stripe-ruby/pull/1227) Update generated code for beta
215
+ * [#1228](https://github.com/stripe/stripe-ruby/pull/1228) Document raw_request
216
+ * [#1222](https://github.com/stripe/stripe-ruby/pull/1222) Update generated code for beta
217
+ * [#1224](https://github.com/stripe/stripe-ruby/pull/1224) Handle developer message in preview error responses
218
+
219
+ ## 8.6.0-beta.4 - 2023-05-19
220
+ * [#1220](https://github.com/stripe/stripe-ruby/pull/1220) Update generated code for beta
221
+ * Add support for `subscribe` and `unsubscribe` methods on resource `FinancialConnections.Account`
222
+ * [#1217](https://github.com/stripe/stripe-ruby/pull/1217) Add raw_request
223
+ * [#1216](https://github.com/stripe/stripe-ruby/pull/1216) Update generated code for beta
224
+ * [#1214](https://github.com/stripe/stripe-ruby/pull/1214) Update generated code for beta
225
+
226
+ ## 8.6.0-beta.3 - 2023-04-17
227
+ * [#1211](https://github.com/stripe/stripe-ruby/pull/1211) Update generated code for beta
228
+ * [#1210](https://github.com/stripe/stripe-ruby/pull/1210), [#1212](https://github.com/stripe/stripe-ruby/pull/1212), [#1213](https://github.com/stripe/stripe-ruby/pull/1213) Add support for request signing
229
+
230
+ ## 8.6.0-beta.2 - 2023-04-13
231
+ * [#1206](https://github.com/stripe/stripe-ruby/pull/1206) Update generated code for beta
232
+ * Add support for `collect_payment_method` and `confirm_payment_intent` methods on resource `Terminal.Reader`
233
+ * [#1205](https://github.com/stripe/stripe-ruby/pull/1205) Update generated code for beta
234
+
235
+ ## 8.6.0-beta.1 - 2023-03-30
236
+ * [#1202](https://github.com/stripe/stripe-ruby/pull/1202) Update generated code for beta
116
237
 
117
238
  ## 8.5.0 - 2023-03-30
118
239
  * [#1203](https://github.com/stripe/stripe-ruby/pull/1203) Update generated code
@@ -120,6 +241,11 @@
120
241
  * This is not a breaking change, as this method was deprecated before the Tax Transactions API was released in favor of the `create_from_calculation` method.
121
242
  * [#1201](https://github.com/stripe/stripe-ruby/pull/1201) Update save deprecation message
122
243
 
244
+ ## 8.5.0-beta.1 - 2023-03-23
245
+ * [#1194](https://github.com/stripe/stripe-ruby/pull/1194) Update generated code for beta (new)
246
+ * Add support for new resources `Tax.CalculationLineItem` and `Tax.TransactionLineItem`
247
+ * Add support for `collect_inputs` method on resource `Terminal.Reader`
248
+
123
249
  ## 8.4.0 - 2023-03-23
124
250
  * [#1197](https://github.com/stripe/stripe-ruby/pull/1197) Update generated code (new)
125
251
  * Add support for new resources `Tax.CalculationLineItem`, `Tax.Calculation`, `Tax.TransactionLineItem`, and `Tax.Transaction`
@@ -127,18 +253,91 @@
127
253
  * Add support for `create_from_calculation`, `create_reversal`, `create`, `list_line_items`, and `retrieve` methods on resource `Transaction`
128
254
  * [#1152](https://github.com/stripe/stripe-ruby/pull/1152) Symbolize hash keys inside `convert_to_stripe_object_with_params`
129
255
 
256
+ ## 8.4.0-beta.4 - 2023-03-16
257
+ * [#1189](https://github.com/stripe/stripe-ruby/pull/1189) Update generated code for beta (new)
258
+ * Add support for `create_from_calculation` method on resource `Tax.Transaction`
259
+ * [#1188](https://github.com/stripe/stripe-ruby/pull/1188) Update generated code for beta (new)
260
+ * Remove support for resources `Capital.FinancingOffer` and `Capital.FinancingSummary`
261
+ * Remove support for `list`, `mark_delivered`, and `retrieve` methods on resource `FinancingOffer`
262
+ * Remove support for `retrieve` method on resource `FinancingSummary`
263
+ * [#1187](https://github.com/stripe/stripe-ruby/pull/1187) Merge upstream master
264
+
265
+ ## 8.4.0-beta.3 - 2023-03-09
266
+ * [#1184](https://github.com/stripe/stripe-ruby/pull/1184) API Updates for beta branch
267
+ * Updated stable APIs to the latest version
268
+ * Remove support for `list_transactions` method on resource `Tax.Transaction`
269
+
270
+ ## 8.4.0-beta.2 - 2023-03-03
271
+ * [#1183](https://github.com/stripe/stripe-ruby/pull/1183) API Updates for beta branch
272
+ * Updated stable APIs to the latest version
273
+ * Add support for new resources `Issuing.CardBundle` and `Issuing.CardDesign`
274
+ * Add support for `list` and `retrieve` methods on resource `CardBundle`
275
+ * Add support for `list`, `retrieve`, and `update` methods on resource `CardDesign`
276
+
277
+ ## 8.4.0-beta.1 - 2023-02-23
278
+ * [#1182](https://github.com/stripe/stripe-ruby/pull/1182) API Updates for beta branch
279
+ * Updated stable APIs to the latest version
280
+
130
281
  ## 8.3.0 - 2023-02-16
131
282
  * [#1175](https://github.com/stripe/stripe-ruby/pull/1175) API Updates
132
283
  * Add support for `refund_payment` method on resource `Terminal.Reader`
133
284
 
285
+ ## 8.3.0-beta.1 - 2023-02-02
286
+ * [#1174](https://github.com/stripe/stripe-ruby/pull/1174) API Updates for beta branch
287
+ * Updated stable APIs to the latest version
288
+ * Add support for new resource `FinancialConnections.Transaction`
289
+ * Add support for `list` method on resource `Transaction`
290
+
134
291
  ## 8.2.0 - 2023-02-02
135
292
  * [#1173](https://github.com/stripe/stripe-ruby/pull/1173) API Updates
136
293
  * Add support for `resume` method on resource `Subscription`
137
294
  * [#1171](https://github.com/stripe/stripe-ruby/pull/1171) Remove unused `partial` param from `initialize_from`
138
295
 
296
+ ## 8.2.0-beta.3 - 2023-01-26
297
+ * [#1172](https://github.com/stripe/stripe-ruby/pull/1172) API Updates for beta branch
298
+ * Updated stable APIs to the latest version
299
+ * Add support for `list_transactions` method on resource `Tax.Transaction`
300
+
301
+ ## 8.2.0-beta.2 - 2023-01-19
302
+ * [#1170](https://github.com/stripe/stripe-ruby/pull/1170) API Updates for beta branch
303
+ * Updated stable APIs to the latest version
304
+ * Add support for `Tax.Settings` resource.
305
+
306
+ ## 8.2.0-beta.1 - 2023-01-12
307
+ * [#1167](https://github.com/stripe/stripe-ruby/pull/1167) API Updates for beta branch
308
+ * Updated stable APIs to the latest version
309
+ * Change `quote.draft_quote` implementation to from calling `POST /v1/quotes/{quote}/draft` to `POST /v1/quotes/{quote}/mark_draft`
310
+ * Add support for `Tax::Register` resource
311
+
139
312
  ## 8.1.0 - 2023-01-12
140
313
  * [#1162](https://github.com/stripe/stripe-ruby/pull/1162) Improve request events instrumentation
141
314
 
315
+ ## 8.1.0-beta.4 - 2023-01-05
316
+ * [#1164](https://github.com/stripe/stripe-ruby/pull/1164) API Updates for beta branch
317
+ * Updated stable APIs to the latest version
318
+ * Add support for `mark_stale_quote` method on resource `Quote`
319
+
320
+ ## 8.1.0-beta.3 - 2022-12-22
321
+ * [#1158](https://github.com/stripe/stripe-ruby/pull/1158) API Updates for beta branch
322
+ * Updated stable APIs to the latest version
323
+ * Move `TaxCalculation` and `TaxTransaction` to `Tax::Calculation` and `Tax::Transaction`.
324
+
325
+ ## 8.1.0-beta.2 - 2022-12-15
326
+ * [#1156](https://github.com/stripe/stripe-ruby/pull/1156) API Updates for beta branch
327
+ * Updated stable APIs to the latest version
328
+ * Add support for new resources `TaxCalculation`, and `TaxTransaction`
329
+ * Add support for `create` and `list_line_items` methods on resource `TaxCalculation`
330
+ * Add support for `create_reversal`, `create`, and `retrieve` methods on resource `TaxTransaction`
331
+ * [#1155](https://github.com/stripe/stripe-ruby/pull/1155) API Updates for beta branch
332
+ * Updated stable APIs to the latest version
333
+ * Add support for new resource `QuoteLine`.
334
+
335
+ ## 8.1.0-beta.1 - 2022-12-08
336
+ * [#1153](https://github.com/stripe/stripe-ruby/pull/1153) API Updates for beta branch
337
+ * Updated stable APIs to the latest version
338
+ * [#1146](https://github.com/stripe/stripe-ruby/pull/1146) API Updates for beta branch
339
+ * Updated stable APIs to the latest version
340
+
142
341
  ## 8.0.0 - 2022-11-16
143
342
  * [#1144](https://github.com/stripe/stripe-ruby/pull/1144) Next major release changes
144
343
 
@@ -146,30 +345,29 @@ Breaking changes that arose during code generation of the library that we postpo
146
345
 
147
346
  "⚠️" symbol highlights breaking changes.
148
347
 
149
- ### Deprecated
150
- - The `save` method is deprecated. Prefer the static `update` method that doesn't require retrieval of the resource to update it.
151
- ``` ruby
152
- # before
153
- refund = Stripe::Refund.retrieve("re_123")
154
- refund.description = "Refund description"
155
- refund.save
156
-
157
- # after
158
- Stripe::Refund.update("re_123", description: "Refund description")
159
- ```
348
+ ## 7.2.0-beta.5 - 2022-11-02
349
+ * [#1139](https://github.com/stripe/stripe-ruby/pull/1139) API Updates for beta branch
350
+ * Updated beta APIs to the latest stable version
351
+ * [#1135](https://github.com/stripe/stripe-ruby/pull/1135) API Updates for beta branch
352
+ * Updated stable APIs to the latest version
160
353
 
161
- ### ⚠️ Removed
162
- - Removed deprecated `Sku` resource.
163
- - Removed deprecated `Orders` resource.
164
- - Removed deprecated `delete` method on `Subscription` resource. Please use `cancel` method instead.
165
- ```ruby
166
- # before
167
- Stripe::Subscription::delete("sub_12345")
354
+ ## 7.2.0-beta.4 - 2022-10-07
355
+ * [#999](https://github.com/stripe/stripe-ruby/pull/999) DESCRIBE CHANGES HERE (try to use the same style, tense, etc. as the other entries)
168
356
 
169
- # after
170
- Stripe::Subscription::cancel("sub_12345")
171
- ```
357
+ ## 7.2.0-beta.3 - 2022-09-26
358
+ * [#1129](https://github.com/stripe/stripe-ruby/pull/1129) API Updates for beta branch
359
+ * Updated stable APIs to the latest version
360
+ * Add `FinancingOffer`, `FinancingSummary` and `FinancingTransaction` resources.
172
361
 
362
+ ## 7.2.0-beta.2 - 2022-08-26
363
+ * [#1127](https://github.com/stripe/stripe-ruby/pull/1127) API Updates for beta branch
364
+ * Updated stable APIs to the latest version
365
+ * Add support for the beta [Gift Card API](https://stripe.com/docs/gift-cards).
366
+
367
+ ## 7.2.0-beta.1 - 2022-08-23
368
+ * [#1122](https://github.com/stripe/stripe-ruby/pull/1122) API Updates for beta branch
369
+ - Updated stable APIs to the latest version
370
+ - `Stripe-Version` beta headers are not pinned by-default and need to be manually specified, please refer to [beta SDKs README section](https://github.com/stripe/stripe-ruby/blob/master/README.md#beta-sdks)
173
371
 
174
372
  ## 7.1.0 - 2022-08-19
175
373
  * [#1116](https://github.com/stripe/stripe-ruby/pull/1116) API Updates
@@ -178,6 +376,16 @@ Breaking changes that arose during code generation of the library that we postpo
178
376
  * [#1117](https://github.com/stripe/stripe-ruby/pull/1117) Refresh rubocop config.
179
377
  * [#1115](https://github.com/stripe/stripe-ruby/pull/1115) Add a support section to the readme
180
378
 
379
+ ## 7.1.0-beta.2 - 2022-08-11
380
+ * [#1113](https://github.com/stripe/stripe-ruby/pull/1113) API Updates for beta branch
381
+ - Updated stable APIs to the latest version
382
+ - Add `refund_payment` method to Terminal resource
383
+
384
+ ## 7.1.0-beta.1 - 2022-08-03
385
+ * [#1107](https://github.com/stripe/stripe-ruby/pull/1107) API Updates for beta branch
386
+ - Updated stable APIs to the latest version
387
+ - Added the `Order` resource support
388
+
181
389
  ## 7.0.0 - 2022-08-02
182
390
 
183
391
  Breaking changes that arose during code generation of the library that we postponed for the next major version. For changes to the SDK, read more detailed description at https://github.com/stripe/stripe-ruby/wiki/Migration-guide-for-v7. For changes to the Stripe products, read more at https://stripe.com/docs/upgrades#2022-08-01.
@@ -189,21 +397,19 @@ Breaking changes that arose during code generation of the library that we postpo
189
397
  * [#1090](https://github.com/stripe/stripe-ruby/pull/1090) Use auto-generation for `Invoice` methods
190
398
  * [#1103](https://github.com/stripe/stripe-ruby/pull/1103) Next major release changes
191
399
 
192
- ### ⚠️ Changed
193
- * `retrieve_cash_balance` and `update_cash_balance` methods on `Customer` resource no longer requires the second argument to always be `nil`. The methods now now take in `customer_id`, `params`, and `opts` parameters.
194
- * Update default bundle of CA certificates to April 26, 2022.
195
-
196
- ### Deprecated
197
- * Deprecate `delete` method on `Subscription` resource. Please use `cancel` method instead.
198
-
199
- ### ⚠️ Removed
200
- * Remove `details` method from `Issuing.Card` resource. The method was not supported.
201
- * Remove `Issuing.CardDetails` resource. Read more at https://stripe.com/docs/issuing/cards/virtual.
202
- * Remove `create` method from `ReportType` resource. The method was not supported.
203
- * Remove `usage_record_summaries` method from `SubscriptionItem` resource. Please use `list_usage_record_summaries` method instead.
204
- * Remove `AlipayAccount`, `BitcoinReceiver`, `BitcoinTransaction`, `Issuing::CardDetails`, `Recipient`, ` RecipientTransfer`, and `ThreeDSecure` resources. The resources were deprecated or no longer in use.
205
- * Remove ability to list `Card` resource for a `Recipient`.
206
- * Remove `cancel` method from `Transfer` resource. The method was deprecated.
400
+ ## 6.6.0-beta.1 - 2022-07-22
401
+ * [#1100](https://github.com/stripe/stripe-ruby/pull/1100) API Updates for beta branch
402
+ - Updated stable APIs to the latest version
403
+ - Add `QuotePhase` resource
404
+ * [#1097](https://github.com/stripe/stripe-ruby/pull/1097) API Updates for beta branch
405
+ - Updated stable APIs to the latest version
406
+ - Add `SubscriptionSchedule.amend` method.
407
+ * [#1093](https://github.com/stripe/stripe-ruby/pull/1093) API Updates for beta branch
408
+ - Include `server_side_confirmation_beta=v1` beta
409
+ - Add `secretKeyConfirmation` to `PaymentIntent`
410
+ * [#1085](https://github.com/stripe/stripe-ruby/pull/1085) API Updates for beta branch
411
+ - Updated stable APIs to the latest version
412
+ * [#1075](https://github.com/stripe/stripe-ruby/pull/1075) Use the generated API version
207
413
 
208
414
  ## 6.5.0 - 2022-06-29
209
415
  * [#1084](https://github.com/stripe/stripe-ruby/pull/1084) API Updates
@@ -233,8 +439,6 @@ Breaking changes that arose during code generation of the library that we postpo
233
439
  * Add support for new resources `Treasury.CreditReversal`, `Treasury.DebitReversal`, `Treasury.FinancialAccountFeatures`, `Treasury.FinancialAccount`, `Treasury.FlowDetails`, `Treasury.InboundTransfer`, `Treasury.OutboundPayment`, `Treasury.OutboundTransfer`, `Treasury.ReceivedCredit`, `Treasury.ReceivedDebit`, `Treasury.TransactionEntry`, and `Treasury.Transaction`
234
440
  * Add support for `retrieve_payment_method` method on resource `Customer`
235
441
  * Add support for `list_owners` and `list` methods on resource `FinancialConnections.Account`
236
-
237
-
238
442
 
239
443
  ## 6.0.0 - 2022-05-09
240
444
  * [#1056](https://github.com/stripe/stripe-ruby/pull/1056) API Updates
@@ -250,7 +454,6 @@ Breaking changes that arose during code generation of the library that we postpo
250
454
  ## 5.55.0 - 2022-05-05
251
455
  * [#1055](https://github.com/stripe/stripe-ruby/pull/1055) API Updates
252
456
  * Add support for new resources `FinancialConnections.AccountOwner`, `FinancialConnections.AccountOwnership`, `FinancialConnections.Account`, and `FinancialConnections.Session`
253
-
254
457
 
255
458
  ## 5.54.0 - 2022-05-03
256
459
  * [#1053](https://github.com/stripe/stripe-ruby/pull/1053) API Updates
@@ -1281,3 +1484,4 @@ Identical to 1.56.0 above. I incorrectly cut a patch-level release.
1281
1484
  <!--
1282
1485
  # vim: set tw=0:
1283
1486
  -->
1487
+
data/OPENAPI_VERSION CHANGED
@@ -1 +1 @@
1
- v682
1
+ v691
data/README.md CHANGED
@@ -323,6 +323,17 @@ If your beta feature requires a `Stripe-Version` header to be sent, use the `Str
323
323
  Stripe.api_version += "; feature_beta=v3"
324
324
  ```
325
325
 
326
+ ### Custom requests
327
+
328
+ If you would like to send a request to an undocumented API (for example you are in a private beta), or if you prefer to bypass the method definitions in the library and specify your request details directly, you can use the `raw_request` method on `Stripe`.
329
+
330
+ ```ruby
331
+ resp = Stripe.raw_request(:post, "/v1/beta_endpoint", {param: 123}, {stripe_version: "2022-11-15; feature_beta=v3"})
332
+
333
+ # (Optional) resp is a StripeResponse. You can use `Stripe.deserialize` to get a StripeObject.
334
+ deserialized_resp = Stripe.deserialize(resp.http_body)
335
+ ```
336
+
326
337
  ## Support
327
338
 
328
339
  New features and bug fixes are released on the latest major version of the Stripe Ruby library. If you are on an older major version, we recommend that you upgrade to the latest in order to use the new features and bug fixes including those for security vulnerabilities. Older major versions of the package will continue to be available for use, but will not be receiving any updates.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 10.2.0
1
+ 10.3.0-beta.1
@@ -47,6 +47,7 @@ module Stripe
47
47
  api_key = headers.delete(:api_key)
48
48
  api_base = headers.delete(:api_base)
49
49
  client = headers.delete(:client)
50
+ api_mode = headers.delete(:api_mode)
50
51
  # Assume all remaining opts must be headers
51
52
 
52
53
  resp, opts[:api_key] = client.send(
@@ -54,6 +55,7 @@ module Stripe
54
55
  method, url,
55
56
  api_base: api_base, api_key: api_key,
56
57
  headers: headers, params: params,
58
+ api_mode: api_mode,
57
59
  &read_body_chunk_block
58
60
  )
59
61
 
@@ -4,5 +4,6 @@
4
4
  module Stripe
5
5
  module ApiVersion
6
6
  CURRENT = "2023-10-16"
7
+ PREVIEW = "2023-10-26.preview-v2"
7
8
  end
8
9
  end
@@ -14,6 +14,7 @@ module Stripe
14
14
  # business objects
15
15
  Account::OBJECT_NAME => Account,
16
16
  AccountLink::OBJECT_NAME => AccountLink,
17
+ AccountNotice::OBJECT_NAME => AccountNotice,
17
18
  AccountSession::OBJECT_NAME => AccountSession,
18
19
  ApplePayDomain::OBJECT_NAME => ApplePayDomain,
19
20
  ApplicationFee::OBJECT_NAME => ApplicationFee,
@@ -25,6 +26,9 @@ module Stripe
25
26
  BillingPortal::Configuration::OBJECT_NAME => BillingPortal::Configuration,
26
27
  BillingPortal::Session::OBJECT_NAME => BillingPortal::Session,
27
28
  Capability::OBJECT_NAME => Capability,
29
+ Capital::FinancingOffer::OBJECT_NAME => Capital::FinancingOffer,
30
+ Capital::FinancingSummary::OBJECT_NAME => Capital::FinancingSummary,
31
+ Capital::FinancingTransaction::OBJECT_NAME => Capital::FinancingTransaction,
28
32
  Card::OBJECT_NAME => Card,
29
33
  CashBalance::OBJECT_NAME => CashBalance,
30
34
  Charge::OBJECT_NAME => Charge,
@@ -32,6 +36,7 @@ module Stripe
32
36
  Climate::Order::OBJECT_NAME => Climate::Order,
33
37
  Climate::Product::OBJECT_NAME => Climate::Product,
34
38
  Climate::Supplier::OBJECT_NAME => Climate::Supplier,
39
+ ConfirmationToken::OBJECT_NAME => ConfirmationToken,
35
40
  CountrySpec::OBJECT_NAME => CountrySpec,
36
41
  Coupon::OBJECT_NAME => Coupon,
37
42
  CreditNote::OBJECT_NAME => CreditNote,
@@ -39,6 +44,7 @@ module Stripe
39
44
  Customer::OBJECT_NAME => Customer,
40
45
  CustomerBalanceTransaction::OBJECT_NAME => CustomerBalanceTransaction,
41
46
  CustomerCashBalanceTransaction::OBJECT_NAME => CustomerCashBalanceTransaction,
47
+ CustomerSession::OBJECT_NAME => CustomerSession,
42
48
  Discount::OBJECT_NAME => Discount,
43
49
  Dispute::OBJECT_NAME => Dispute,
44
50
  EphemeralKey::OBJECT_NAME => EphemeralKey,
@@ -48,25 +54,36 @@ module Stripe
48
54
  File::OBJECT_NAME_ALT => File,
49
55
  FileLink::OBJECT_NAME => FileLink,
50
56
  FinancialConnections::Account::OBJECT_NAME => FinancialConnections::Account,
57
+ FinancialConnections::AccountInferredBalance::OBJECT_NAME =>
58
+ FinancialConnections::AccountInferredBalance,
51
59
  FinancialConnections::AccountOwner::OBJECT_NAME => FinancialConnections::AccountOwner,
52
60
  FinancialConnections::AccountOwnership::OBJECT_NAME =>
53
61
  FinancialConnections::AccountOwnership,
54
62
  FinancialConnections::Session::OBJECT_NAME => FinancialConnections::Session,
63
+ FinancialConnections::Transaction::OBJECT_NAME => FinancialConnections::Transaction,
55
64
  FundingInstructions::OBJECT_NAME => FundingInstructions,
65
+ GiftCards::Card::OBJECT_NAME => GiftCards::Card,
66
+ GiftCards::Transaction::OBJECT_NAME => GiftCards::Transaction,
56
67
  Identity::VerificationReport::OBJECT_NAME => Identity::VerificationReport,
57
68
  Identity::VerificationSession::OBJECT_NAME => Identity::VerificationSession,
58
69
  Invoice::OBJECT_NAME => Invoice,
59
70
  InvoiceItem::OBJECT_NAME => InvoiceItem,
60
71
  InvoiceLineItem::OBJECT_NAME => InvoiceLineItem,
72
+ InvoicePayment::OBJECT_NAME => InvoicePayment,
61
73
  Issuing::Authorization::OBJECT_NAME => Issuing::Authorization,
62
74
  Issuing::Card::OBJECT_NAME => Issuing::Card,
63
75
  Issuing::Cardholder::OBJECT_NAME => Issuing::Cardholder,
76
+ Issuing::CreditUnderwritingRecord::OBJECT_NAME => Issuing::CreditUnderwritingRecord,
64
77
  Issuing::Dispute::OBJECT_NAME => Issuing::Dispute,
78
+ Issuing::PersonalizationDesign::OBJECT_NAME => Issuing::PersonalizationDesign,
79
+ Issuing::PhysicalBundle::OBJECT_NAME => Issuing::PhysicalBundle,
65
80
  Issuing::Token::OBJECT_NAME => Issuing::Token,
66
81
  Issuing::Transaction::OBJECT_NAME => Issuing::Transaction,
67
82
  LineItem::OBJECT_NAME => LineItem,
68
83
  LoginLink::OBJECT_NAME => LoginLink,
69
84
  Mandate::OBJECT_NAME => Mandate,
85
+ Margin::OBJECT_NAME => Margin,
86
+ Order::OBJECT_NAME => Order,
70
87
  PaymentIntent::OBJECT_NAME => PaymentIntent,
71
88
  PaymentLink::OBJECT_NAME => PaymentLink,
72
89
  PaymentMethod::OBJECT_NAME => PaymentMethod,
@@ -79,6 +96,9 @@ module Stripe
79
96
  Product::OBJECT_NAME => Product,
80
97
  PromotionCode::OBJECT_NAME => PromotionCode,
81
98
  Quote::OBJECT_NAME => Quote,
99
+ QuotePhase::OBJECT_NAME => QuotePhase,
100
+ QuotePreviewInvoice::OBJECT_NAME => QuotePreviewInvoice,
101
+ QuotePreviewSubscriptionSchedule::OBJECT_NAME => QuotePreviewSubscriptionSchedule,
82
102
  Radar::EarlyFraudWarning::OBJECT_NAME => Radar::EarlyFraudWarning,
83
103
  Radar::ValueList::OBJECT_NAME => Radar::ValueList,
84
104
  Radar::ValueListItem::OBJECT_NAME => Radar::ValueListItem,
@@ -98,6 +118,7 @@ module Stripe
98
118
  SubscriptionSchedule::OBJECT_NAME => SubscriptionSchedule,
99
119
  Tax::Calculation::OBJECT_NAME => Tax::Calculation,
100
120
  Tax::CalculationLineItem::OBJECT_NAME => Tax::CalculationLineItem,
121
+ Tax::Form::OBJECT_NAME => Tax::Form,
101
122
  Tax::Registration::OBJECT_NAME => Tax::Registration,
102
123
  Tax::Settings::OBJECT_NAME => Tax::Settings,
103
124
  Tax::Transaction::OBJECT_NAME => Tax::Transaction,
@@ -0,0 +1,79 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Stripe
4
+ class RequestSigningAuthenticator
5
+ AUTHORIZATION_HEADER_NAME = "Authorization"
6
+ CONTENT_TYPE_HEADER_NAME = "Content-Type"
7
+ STRIPE_CONTEXT_HEADER_NAME = "Stripe-Context"
8
+ STRIPE_ACCOUNT_HEADER_NAME = "Stripe-Account"
9
+ CONTENT_DIGEST_HEADER_NAME = "Content-Digest"
10
+ SIGNATURE_INPUT_HEADER_NAME = "Signature-Input"
11
+ SIGNATURE_HEADER_NAME = "Signature"
12
+
13
+ attr_reader :auth_token, :sign_lambda
14
+
15
+ def initialize(auth_token, sign_lambda)
16
+ raise ArgumentError, "auth_token must be a string" unless auth_token.is_a?(String)
17
+ raise ArgumentError, "sign_lambda must be a lambda" unless sign_lambda.is_a?(Proc)
18
+
19
+ @auth_token = auth_token
20
+ @sign_lambda = sign_lambda
21
+ end
22
+
23
+ def authenticate(method, headers, body)
24
+ covered_headers = [CONTENT_TYPE_HEADER_NAME,
25
+ CONTENT_DIGEST_HEADER_NAME,
26
+ STRIPE_CONTEXT_HEADER_NAME,
27
+ STRIPE_ACCOUNT_HEADER_NAME,
28
+ AUTHORIZATION_HEADER_NAME,]
29
+
30
+ headers[AUTHORIZATION_HEADER_NAME] = "STRIPE-V2-SIG #{auth_token}"
31
+
32
+ if method == :get
33
+ covered_headers -= [CONTENT_TYPE_HEADER_NAME,
34
+ CONTENT_DIGEST_HEADER_NAME,]
35
+ else
36
+ content = body || ""
37
+ headers[CONTENT_DIGEST_HEADER_NAME] =
38
+ %(sha-256=:#{content_digest(content)}:)
39
+ end
40
+
41
+ covered_headers_formatted = covered_headers
42
+ .map { |string| %("#{string.downcase}") }
43
+ .join(" ")
44
+
45
+ signature_input = "(#{covered_headers_formatted});created=#{created_time}"
46
+
47
+ inputs = covered_headers
48
+ .map { |header| %("#{header.downcase}": #{headers[header]}) }
49
+ .join("\n")
50
+
51
+ signature_base = %(#{inputs}\n"@signature-params": #{signature_input})
52
+ .encode(Encoding::UTF_8)
53
+
54
+ headers[SIGNATURE_INPUT_HEADER_NAME] = "sig1=#{signature_input}"
55
+
56
+ headers[SIGNATURE_HEADER_NAME] =
57
+ "sig1=:#{encoded_signature(signature_base)}:"
58
+ end
59
+
60
+ private def sign(signature_base)
61
+ @sign_lambda.call(signature_base)
62
+ end
63
+
64
+ private def encoded_signature(signature_base)
65
+ Base64.strict_encode64(sign(signature_base))
66
+ rescue StandardError
67
+ raise AuthenticationError, "Encountered '#{e.message} (#{e.class})' " \
68
+ "when calculating request signature."
69
+ end
70
+
71
+ private def content_digest(content)
72
+ Base64.strict_encode64(OpenSSL::Digest.new("SHA256").digest(content))
73
+ end
74
+
75
+ private def created_time
76
+ Time.now.to_i
77
+ end
78
+ end
79
+ end