stripe 19.2.0-beta.1 → 19.3.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/CHANGELOG.md +90 -0
  2. package/OPENAPI_VERSION +1 -1
  3. package/VERSION +1 -1
  4. package/cjs/apiVersion.js +1 -1
  5. package/cjs/resources/PaymentRecords.js +4 -0
  6. package/cjs/resources/V2/Core/Vault/GbBankAccounts.js +5 -0
  7. package/cjs/resources/V2/Core/Vault/UsBankAccounts.js +13 -0
  8. package/cjs/resources/V2/MoneyManagement/FinancialAccounts.js +4 -0
  9. package/cjs/stripe.core.js +1 -1
  10. package/esm/apiVersion.js +1 -1
  11. package/esm/resources/PaymentRecords.js +4 -0
  12. package/esm/resources/V2/Core/Vault/GbBankAccounts.js +5 -0
  13. package/esm/resources/V2/Core/Vault/UsBankAccounts.js +13 -0
  14. package/esm/resources/V2/MoneyManagement/FinancialAccounts.js +4 -0
  15. package/esm/stripe.core.js +1 -1
  16. package/package.json +1 -1
  17. package/types/Accounts.d.ts +24 -0
  18. package/types/AccountsResource.d.ts +44 -0
  19. package/types/BankAccounts.d.ts +2 -0
  20. package/types/Billing/CreditGrantsResource.d.ts +2 -2
  21. package/types/BillingPortal/Configurations.d.ts +1 -1
  22. package/types/BillingPortal/ConfigurationsResource.d.ts +10 -0
  23. package/types/Capabilities.d.ts +2 -0
  24. package/types/Charges.d.ts +7 -2
  25. package/types/ChargesResource.d.ts +16 -4
  26. package/types/Checkout/Sessions.d.ts +15 -0
  27. package/types/Checkout/SessionsResource.d.ts +21 -3
  28. package/types/ConfirmationTokens.d.ts +1 -0
  29. package/types/CreditNotes.d.ts +26 -0
  30. package/types/CreditNotesResource.d.ts +78 -0
  31. package/types/CustomerSessions.d.ts +161 -0
  32. package/types/CustomerSessionsResource.d.ts +161 -0
  33. package/types/Customers.d.ts +7 -0
  34. package/types/CustomersResource.d.ts +1 -0
  35. package/types/Files.d.ts +1 -0
  36. package/types/FilesResource.d.ts +2 -0
  37. package/types/FinancialConnections/AccountsResource.d.ts +1 -1
  38. package/types/Invoices.d.ts +1 -0
  39. package/types/PaymentAttemptRecords.d.ts +7 -2
  40. package/types/PaymentAttemptRecordsResource.d.ts +5 -0
  41. package/types/PaymentIntentAmountDetailsLineItems.d.ts +17 -7
  42. package/types/PaymentIntents.d.ts +20 -9
  43. package/types/PaymentIntentsResource.d.ts +170 -65
  44. package/types/PaymentLinks.d.ts +34 -0
  45. package/types/PaymentLinksResource.d.ts +88 -0
  46. package/types/PaymentMethodConfigurations.d.ts +72 -0
  47. package/types/PaymentMethodConfigurationsResource.d.ts +100 -0
  48. package/types/PaymentMethods.d.ts +34 -0
  49. package/types/PaymentMethodsResource.d.ts +15 -1
  50. package/types/PaymentRecords.d.ts +7 -2
  51. package/types/PaymentRecordsResource.d.ts +89 -0
  52. package/types/PayoutsResource.d.ts +1 -1
  53. package/types/Persons.d.ts +2 -0
  54. package/types/QuotePreviewInvoices.d.ts +1 -0
  55. package/types/Refunds.d.ts +9 -0
  56. package/types/SetupAttempts.d.ts +1 -0
  57. package/types/SetupIntents.d.ts +66 -0
  58. package/types/SetupIntentsResource.d.ts +130 -0
  59. package/types/Tax/Registrations.d.ts +9 -0
  60. package/types/Tax/RegistrationsResource.d.ts +12 -0
  61. package/types/Terminal/Configurations.d.ts +19 -0
  62. package/types/Terminal/ConfigurationsResource.d.ts +44 -0
  63. package/types/Terminal/Readers.d.ts +14 -9
  64. package/types/Terminal/ReadersResource.d.ts +30 -30
  65. package/types/TestHelpers/Terminal/ReadersResource.d.ts +1 -1
  66. package/types/TokensResource.d.ts +22 -0
  67. package/types/V2/Billing/Cadences.d.ts +2 -2
  68. package/types/V2/Billing/CollectionSettingVersions.d.ts +2 -2
  69. package/types/V2/Billing/CollectionSettings.d.ts +2 -2
  70. package/types/V2/Billing/CollectionSettingsResource.d.ts +4 -4
  71. package/types/V2/Core/Accounts.d.ts +93 -2
  72. package/types/V2/Core/AccountsResource.d.ts +110 -5
  73. package/types/V2/Core/EventTypes.d.ts +11 -34
  74. package/types/V2/Core/EventsResource.d.ts +29 -3
  75. package/types/V2/Core/Vault/GbBankAccountsResource.d.ts +22 -0
  76. package/types/V2/Core/Vault/UsBankAccounts.d.ts +46 -0
  77. package/types/V2/Core/Vault/UsBankAccountsResource.d.ts +75 -0
  78. package/types/V2/MoneyManagement/FinancialAccountsResource.d.ts +25 -0
  79. package/types/V2/MoneyManagement/OutboundPaymentsResource.d.ts +1 -1
  80. package/types/WebhookEndpointsResource.d.ts +2 -1
  81. package/types/apiVersion.d.ts +1 -1
  82. package/types/crypto/crypto.d.ts +1 -1
@@ -134,6 +134,8 @@ declare module 'stripe' {
134
134
 
135
135
  cashapp?: DestinationDetails.Cashapp;
136
136
 
137
+ crypto?: DestinationDetails.Crypto;
138
+
137
139
  customer_cash_balance?: DestinationDetails.CustomerCashBalance;
138
140
 
139
141
  eps?: DestinationDetails.Eps;
@@ -256,6 +258,13 @@ declare module 'stripe' {
256
258
 
257
259
  interface Cashapp {}
258
260
 
261
+ interface Crypto {
262
+ /**
263
+ * The transaction hash of the refund.
264
+ */
265
+ reference: string | null;
266
+ }
267
+
259
268
  interface CustomerCashBalance {}
260
269
 
261
270
  interface Eps {}
@@ -817,6 +817,7 @@ declare module 'stripe' {
817
817
  | 'payment_intent_mandate_invalid'
818
818
  | 'payment_intent_payment_attempt_expired'
819
819
  | 'payment_intent_payment_attempt_failed'
820
+ | 'payment_intent_rate_limit_exceeded'
820
821
  | 'payment_intent_unexpected_state'
821
822
  | 'payment_method_bank_account_already_verified'
822
823
  | 'payment_method_bank_account_blocked'
@@ -89,6 +89,13 @@ declare module 'stripe' {
89
89
  */
90
90
  description: string | null;
91
91
 
92
+ /**
93
+ * Payment method types that are excluded from this SetupIntent.
94
+ */
95
+ excluded_payment_method_types: Array<
96
+ SetupIntent.ExcludedPaymentMethodType
97
+ > | null;
98
+
92
99
  /**
93
100
  * Indicates the directions of money movement for which this payment method is intended to be used.
94
101
  *
@@ -193,6 +200,64 @@ declare module 'stripe' {
193
200
  | 'duplicate'
194
201
  | 'requested_by_customer';
195
202
 
203
+ type ExcludedPaymentMethodType =
204
+ | 'acss_debit'
205
+ | 'affirm'
206
+ | 'afterpay_clearpay'
207
+ | 'alipay'
208
+ | 'alma'
209
+ | 'amazon_pay'
210
+ | 'au_becs_debit'
211
+ | 'bacs_debit'
212
+ | 'bancontact'
213
+ | 'billie'
214
+ | 'blik'
215
+ | 'boleto'
216
+ | 'card'
217
+ | 'cashapp'
218
+ | 'crypto'
219
+ | 'customer_balance'
220
+ | 'eps'
221
+ | 'fpx'
222
+ | 'giropay'
223
+ | 'gopay'
224
+ | 'grabpay'
225
+ | 'id_bank_transfer'
226
+ | 'ideal'
227
+ | 'kakao_pay'
228
+ | 'klarna'
229
+ | 'konbini'
230
+ | 'kr_card'
231
+ | 'mb_way'
232
+ | 'mobilepay'
233
+ | 'multibanco'
234
+ | 'naver_pay'
235
+ | 'nz_bank_account'
236
+ | 'oxxo'
237
+ | 'p24'
238
+ | 'pay_by_bank'
239
+ | 'payco'
240
+ | 'paynow'
241
+ | 'paypal'
242
+ | 'paypay'
243
+ | 'payto'
244
+ | 'pix'
245
+ | 'promptpay'
246
+ | 'qris'
247
+ | 'rechnung'
248
+ | 'revolut_pay'
249
+ | 'samsung_pay'
250
+ | 'satispay'
251
+ | 'sepa_debit'
252
+ | 'shopeepay'
253
+ | 'sofort'
254
+ | 'stripe_balance'
255
+ | 'swish'
256
+ | 'twint'
257
+ | 'us_bank_account'
258
+ | 'wechat_pay'
259
+ | 'zip';
260
+
196
261
  type FlowDirection = 'inbound' | 'outbound';
197
262
 
198
263
  interface LastSetupError {
@@ -421,6 +486,7 @@ declare module 'stripe' {
421
486
  | 'payment_intent_mandate_invalid'
422
487
  | 'payment_intent_payment_attempt_expired'
423
488
  | 'payment_intent_payment_attempt_failed'
489
+ | 'payment_intent_rate_limit_exceeded'
424
490
  | 'payment_intent_unexpected_state'
425
491
  | 'payment_method_bank_account_already_verified'
426
492
  | 'payment_method_bank_account_blocked'
@@ -46,6 +46,13 @@ declare module 'stripe' {
46
46
  */
47
47
  description?: string;
48
48
 
49
+ /**
50
+ * The list of payment method types to exclude from use with this SetupIntent.
51
+ */
52
+ excluded_payment_method_types?: Array<
53
+ SetupIntentCreateParams.ExcludedPaymentMethodType
54
+ >;
55
+
49
56
  /**
50
57
  * Specifies which fields in the response should be expanded.
51
58
  */
@@ -141,6 +148,64 @@ declare module 'stripe' {
141
148
  type AllowRedirects = 'always' | 'never';
142
149
  }
143
150
 
151
+ type ExcludedPaymentMethodType =
152
+ | 'acss_debit'
153
+ | 'affirm'
154
+ | 'afterpay_clearpay'
155
+ | 'alipay'
156
+ | 'alma'
157
+ | 'amazon_pay'
158
+ | 'au_becs_debit'
159
+ | 'bacs_debit'
160
+ | 'bancontact'
161
+ | 'billie'
162
+ | 'blik'
163
+ | 'boleto'
164
+ | 'card'
165
+ | 'cashapp'
166
+ | 'crypto'
167
+ | 'customer_balance'
168
+ | 'eps'
169
+ | 'fpx'
170
+ | 'giropay'
171
+ | 'gopay'
172
+ | 'grabpay'
173
+ | 'id_bank_transfer'
174
+ | 'ideal'
175
+ | 'kakao_pay'
176
+ | 'klarna'
177
+ | 'konbini'
178
+ | 'kr_card'
179
+ | 'mb_way'
180
+ | 'mobilepay'
181
+ | 'multibanco'
182
+ | 'naver_pay'
183
+ | 'nz_bank_account'
184
+ | 'oxxo'
185
+ | 'p24'
186
+ | 'pay_by_bank'
187
+ | 'payco'
188
+ | 'paynow'
189
+ | 'paypal'
190
+ | 'paypay'
191
+ | 'payto'
192
+ | 'pix'
193
+ | 'promptpay'
194
+ | 'qris'
195
+ | 'rechnung'
196
+ | 'revolut_pay'
197
+ | 'samsung_pay'
198
+ | 'satispay'
199
+ | 'sepa_debit'
200
+ | 'shopeepay'
201
+ | 'sofort'
202
+ | 'stripe_balance'
203
+ | 'swish'
204
+ | 'twint'
205
+ | 'us_bank_account'
206
+ | 'wechat_pay'
207
+ | 'zip';
208
+
144
209
  type FlowDirection = 'inbound' | 'outbound';
145
210
 
146
211
  interface MandateData {
@@ -1884,6 +1949,13 @@ declare module 'stripe' {
1884
1949
  */
1885
1950
  description?: string;
1886
1951
 
1952
+ /**
1953
+ * The list of payment method types to exclude from use with this SetupIntent.
1954
+ */
1955
+ excluded_payment_method_types?: Stripe.Emptyable<
1956
+ Array<SetupIntentUpdateParams.ExcludedPaymentMethodType>
1957
+ >;
1958
+
1887
1959
  /**
1888
1960
  * Specifies which fields in the response should be expanded.
1889
1961
  */
@@ -1929,6 +2001,64 @@ declare module 'stripe' {
1929
2001
  }
1930
2002
 
1931
2003
  namespace SetupIntentUpdateParams {
2004
+ type ExcludedPaymentMethodType =
2005
+ | 'acss_debit'
2006
+ | 'affirm'
2007
+ | 'afterpay_clearpay'
2008
+ | 'alipay'
2009
+ | 'alma'
2010
+ | 'amazon_pay'
2011
+ | 'au_becs_debit'
2012
+ | 'bacs_debit'
2013
+ | 'bancontact'
2014
+ | 'billie'
2015
+ | 'blik'
2016
+ | 'boleto'
2017
+ | 'card'
2018
+ | 'cashapp'
2019
+ | 'crypto'
2020
+ | 'customer_balance'
2021
+ | 'eps'
2022
+ | 'fpx'
2023
+ | 'giropay'
2024
+ | 'gopay'
2025
+ | 'grabpay'
2026
+ | 'id_bank_transfer'
2027
+ | 'ideal'
2028
+ | 'kakao_pay'
2029
+ | 'klarna'
2030
+ | 'konbini'
2031
+ | 'kr_card'
2032
+ | 'mb_way'
2033
+ | 'mobilepay'
2034
+ | 'multibanco'
2035
+ | 'naver_pay'
2036
+ | 'nz_bank_account'
2037
+ | 'oxxo'
2038
+ | 'p24'
2039
+ | 'pay_by_bank'
2040
+ | 'payco'
2041
+ | 'paynow'
2042
+ | 'paypal'
2043
+ | 'paypay'
2044
+ | 'payto'
2045
+ | 'pix'
2046
+ | 'promptpay'
2047
+ | 'qris'
2048
+ | 'rechnung'
2049
+ | 'revolut_pay'
2050
+ | 'samsung_pay'
2051
+ | 'satispay'
2052
+ | 'sepa_debit'
2053
+ | 'shopeepay'
2054
+ | 'sofort'
2055
+ | 'stripe_balance'
2056
+ | 'swish'
2057
+ | 'twint'
2058
+ | 'us_bank_account'
2059
+ | 'wechat_pay'
2060
+ | 'zip';
2061
+
1932
2062
  type FlowDirection = 'inbound' | 'outbound';
1933
2063
 
1934
2064
  interface PaymentMethodData {
@@ -234,6 +234,8 @@ declare module 'stripe' {
234
234
 
235
235
  tr?: CountryOptions.Tr;
236
236
 
237
+ tw?: CountryOptions.Tw;
238
+
237
239
  tz?: CountryOptions.Tz;
238
240
 
239
241
  ua?: CountryOptions.Ua;
@@ -1552,6 +1554,13 @@ declare module 'stripe' {
1552
1554
  type: 'simplified';
1553
1555
  }
1554
1556
 
1557
+ interface Tw {
1558
+ /**
1559
+ * Type of registration in `country`.
1560
+ */
1561
+ type: 'simplified';
1562
+ }
1563
+
1555
1564
  interface Tz {
1556
1565
  /**
1557
1566
  * Type of registration in `country`.
@@ -477,6 +477,11 @@ declare module 'stripe' {
477
477
  */
478
478
  tr?: CountryOptions.Tr;
479
479
 
480
+ /**
481
+ * Options for the registration in TW.
482
+ */
483
+ tw?: CountryOptions.Tw;
484
+
480
485
  /**
481
486
  * Options for the registration in TZ.
482
487
  */
@@ -2275,6 +2280,13 @@ declare module 'stripe' {
2275
2280
  type: 'simplified';
2276
2281
  }
2277
2282
 
2283
+ interface Tw {
2284
+ /**
2285
+ * Type of registration to be created in `country`.
2286
+ */
2287
+ type: 'simplified';
2288
+ }
2289
+
2278
2290
  interface Tz {
2279
2291
  /**
2280
2292
  * Type of registration to be created in `country`.
@@ -124,6 +124,8 @@ declare module 'stripe' {
124
124
 
125
125
  gbp?: Tipping.Gbp;
126
126
 
127
+ gip?: Tipping.Gip;
128
+
127
129
  hkd?: Tipping.Hkd;
128
130
 
129
131
  huf?: Tipping.Huf;
@@ -303,6 +305,23 @@ declare module 'stripe' {
303
305
  smart_tip_threshold?: number;
304
306
  }
305
307
 
308
+ interface Gip {
309
+ /**
310
+ * Fixed amounts displayed when collecting a tip
311
+ */
312
+ fixed_amounts?: Array<number> | null;
313
+
314
+ /**
315
+ * Percentages displayed when collecting a tip
316
+ */
317
+ percentages?: Array<number> | null;
318
+
319
+ /**
320
+ * Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
321
+ */
322
+ smart_tip_threshold?: number;
323
+ }
324
+
306
325
  interface Hkd {
307
326
  /**
308
327
  * Fixed amounts displayed when collecting a tip
@@ -156,6 +156,11 @@ declare module 'stripe' {
156
156
  */
157
157
  gbp?: Tipping.Gbp;
158
158
 
159
+ /**
160
+ * Tipping configuration for GIP
161
+ */
162
+ gip?: Tipping.Gip;
163
+
159
164
  /**
160
165
  * Tipping configuration for HKD
161
166
  */
@@ -371,6 +376,23 @@ declare module 'stripe' {
371
376
  smart_tip_threshold?: number;
372
377
  }
373
378
 
379
+ interface Gip {
380
+ /**
381
+ * Fixed amounts displayed when collecting a tip
382
+ */
383
+ fixed_amounts?: Array<number>;
384
+
385
+ /**
386
+ * Percentages displayed when collecting a tip
387
+ */
388
+ percentages?: Array<number>;
389
+
390
+ /**
391
+ * Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
392
+ */
393
+ smart_tip_threshold?: number;
394
+ }
395
+
374
396
  interface Hkd {
375
397
  /**
376
398
  * Fixed amounts displayed when collecting a tip
@@ -842,6 +864,11 @@ declare module 'stripe' {
842
864
  */
843
865
  gbp?: Tipping.Gbp;
844
866
 
867
+ /**
868
+ * Tipping configuration for GIP
869
+ */
870
+ gip?: Tipping.Gip;
871
+
845
872
  /**
846
873
  * Tipping configuration for HKD
847
874
  */
@@ -1057,6 +1084,23 @@ declare module 'stripe' {
1057
1084
  smart_tip_threshold?: number;
1058
1085
  }
1059
1086
 
1087
+ interface Gip {
1088
+ /**
1089
+ * Fixed amounts displayed when collecting a tip
1090
+ */
1091
+ fixed_amounts?: Array<number>;
1092
+
1093
+ /**
1094
+ * Percentages displayed when collecting a tip
1095
+ */
1096
+ percentages?: Array<number>;
1097
+
1098
+ /**
1099
+ * Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
1100
+ */
1101
+ smart_tip_threshold?: number;
1102
+ }
1103
+
1060
1104
  interface Hkd {
1061
1105
  /**
1062
1106
  * Fixed amounts displayed when collecting a tip
@@ -69,6 +69,11 @@ declare module 'stripe' {
69
69
  */
70
70
  label: string;
71
71
 
72
+ /**
73
+ * The last time this reader reported to Stripe backend.
74
+ */
75
+ last_seen_at: number | null;
76
+
72
77
  /**
73
78
  * Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
74
79
  */
@@ -288,17 +293,17 @@ declare module 'stripe' {
288
293
  namespace Selection {
289
294
  interface Choice {
290
295
  /**
291
- * The id to be selected
296
+ * The identifier for the selected choice. Maximum 50 characters.
292
297
  */
293
298
  id: string | null;
294
299
 
295
300
  /**
296
- * The button style for the choice
301
+ * The button style for the choice. Can be `primary` or `secondary`.
297
302
  */
298
303
  style: Choice.Style | null;
299
304
 
300
305
  /**
301
- * The text to be selected
306
+ * The text to be selected. Maximum 30 characters.
302
307
  */
303
308
  text: string;
304
309
  }
@@ -324,22 +329,22 @@ declare module 'stripe' {
324
329
 
325
330
  interface Toggle {
326
331
  /**
327
- * The toggle's default value
332
+ * The toggle's default value. Can be `enabled` or `disabled`.
328
333
  */
329
334
  default_value: Toggle.DefaultValue | null;
330
335
 
331
336
  /**
332
- * The toggle's description text
337
+ * The toggle's description text. Maximum 50 characters.
333
338
  */
334
339
  description: string | null;
335
340
 
336
341
  /**
337
- * The toggle's title text
342
+ * The toggle's title text. Maximum 50 characters.
338
343
  */
339
344
  title: string | null;
340
345
 
341
346
  /**
342
- * The toggle's collected value
347
+ * The toggle's collected value. Can be `enabled` or `disabled`.
343
348
  */
344
349
  value: Toggle.Value | null;
345
350
  }
@@ -581,12 +586,12 @@ declare module 'stripe' {
581
586
 
582
587
  interface SetReaderDisplay {
583
588
  /**
584
- * Cart object to be displayed by the reader.
589
+ * Cart object to be displayed by the reader, including line items, amounts, and currency.
585
590
  */
586
591
  cart: SetReaderDisplay.Cart | null;
587
592
 
588
593
  /**
589
- * Type of information to be displayed by the reader.
594
+ * Type of information to be displayed by the reader. Only `cart` is currently supported.
590
595
  */
591
596
  type: 'cart';
592
597
  }