stripe 17.7.0-beta.1 → 17.7.0

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 (176) hide show
  1. package/CHANGELOG.md +120 -1064
  2. package/OPENAPI_VERSION +1 -1
  3. package/README.md +0 -1
  4. package/VERSION +1 -1
  5. package/cjs/apiVersion.js +1 -1
  6. package/cjs/resources/FinancialConnections/Accounts.js +0 -5
  7. package/cjs/resources/Invoices.js +0 -17
  8. package/cjs/resources/PaymentIntents.js +0 -8
  9. package/cjs/resources/Quotes.js +0 -32
  10. package/cjs/resources/SubscriptionSchedules.js +0 -4
  11. package/cjs/resources/Terminal/Readers.js +0 -12
  12. package/cjs/resources.js +10 -48
  13. package/cjs/stripe.core.js +1 -1
  14. package/esm/apiVersion.js +1 -1
  15. package/esm/resources/FinancialConnections/Accounts.js +0 -5
  16. package/esm/resources/Invoices.js +0 -17
  17. package/esm/resources/PaymentIntents.js +0 -8
  18. package/esm/resources/Quotes.js +0 -32
  19. package/esm/resources/SubscriptionSchedules.js +0 -4
  20. package/esm/resources/Terminal/Readers.js +0 -12
  21. package/esm/resources.js +0 -33
  22. package/esm/stripe.core.js +1 -1
  23. package/package.json +1 -1
  24. package/types/AccountLinksResource.d.ts +1 -5
  25. package/types/AccountSessions.d.ts +0 -45
  26. package/types/AccountSessionsResource.d.ts +0 -243
  27. package/types/Accounts.d.ts +1 -205
  28. package/types/AccountsResource.d.ts +2 -526
  29. package/types/Billing/CreditBalanceSummaryResource.d.ts +1 -1
  30. package/types/Billing/CreditGrants.d.ts +5 -0
  31. package/types/Billing/CreditGrantsResource.d.ts +7 -2
  32. package/types/Cards.d.ts +0 -5
  33. package/types/Charges.d.ts +1 -149
  34. package/types/ChargesResource.d.ts +0 -1294
  35. package/types/Checkout/Sessions.d.ts +29 -302
  36. package/types/Checkout/SessionsResource.d.ts +30 -383
  37. package/types/ConfirmationTokens.d.ts +0 -99
  38. package/types/Coupons.d.ts +1 -1
  39. package/types/CouponsResource.d.ts +1 -1
  40. package/types/CreditNotes.d.ts +0 -21
  41. package/types/CreditNotesResource.d.ts +0 -51
  42. package/types/CustomersResource.d.ts +0 -7
  43. package/types/EventTypes.d.ts +0 -596
  44. package/types/Events.d.ts +0 -93
  45. package/types/FinancialConnections/Accounts.d.ts +1 -29
  46. package/types/FinancialConnections/AccountsResource.d.ts +3 -35
  47. package/types/FinancialConnections/Sessions.d.ts +1 -49
  48. package/types/FinancialConnections/SessionsResource.d.ts +1 -38
  49. package/types/InvoiceItems.d.ts +0 -5
  50. package/types/InvoiceItemsResource.d.ts +0 -98
  51. package/types/InvoiceLineItems.d.ts +1 -28
  52. package/types/Invoices.d.ts +2 -137
  53. package/types/InvoicesResource.d.ts +1882 -5567
  54. package/types/Issuing/Authorizations.d.ts +0 -1
  55. package/types/Issuing/CardholdersResource.d.ts +1 -2
  56. package/types/Issuing/Transactions.d.ts +0 -2
  57. package/types/Issuing/TransactionsResource.d.ts +0 -5
  58. package/types/LineItems.d.ts +0 -32
  59. package/types/Mandates.d.ts +0 -77
  60. package/types/PaymentIntents.d.ts +30 -648
  61. package/types/PaymentIntentsResource.d.ts +3848 -8060
  62. package/types/PaymentLinks.d.ts +0 -6
  63. package/types/PaymentLinksResource.d.ts +0 -12
  64. package/types/PaymentMethodConfigurations.d.ts +0 -180
  65. package/types/PaymentMethodConfigurationsResource.d.ts +0 -250
  66. package/types/PaymentMethods.d.ts +0 -99
  67. package/types/PaymentMethodsResource.d.ts +0 -133
  68. package/types/Prices.d.ts +0 -22
  69. package/types/PricesResource.d.ts +0 -22
  70. package/types/Products.d.ts +0 -39
  71. package/types/ProductsResource.d.ts +5 -36
  72. package/types/Quotes.d.ts +1 -591
  73. package/types/QuotesResource.d.ts +199 -2531
  74. package/types/Refunds.d.ts +0 -14
  75. package/types/SetupAttempts.d.ts +0 -38
  76. package/types/SetupIntents.d.ts +1 -111
  77. package/types/SetupIntentsResource.d.ts +3 -645
  78. package/types/Sources.d.ts +0 -29
  79. package/types/SubscriptionItems.d.ts +0 -21
  80. package/types/SubscriptionItemsResource.d.ts +0 -109
  81. package/types/SubscriptionSchedules.d.ts +0 -200
  82. package/types/SubscriptionSchedulesResource.d.ts +13 -1231
  83. package/types/Subscriptions.d.ts +1 -91
  84. package/types/SubscriptionsResource.d.ts +2 -369
  85. package/types/Terminal/Readers.d.ts +0 -290
  86. package/types/Terminal/ReadersResource.d.ts +0 -215
  87. package/types/TestHelpers/ConfirmationTokensResource.d.ts +0 -104
  88. package/types/TestHelpers/Treasury/ReceivedCreditsResource.d.ts +0 -26
  89. package/types/TestHelpers/Treasury/ReceivedDebitsResource.d.ts +0 -26
  90. package/types/TokensResource.d.ts +1 -3
  91. package/types/Treasury/FinancialAccountFeatures.d.ts +0 -7
  92. package/types/Treasury/FinancialAccounts.d.ts +0 -5
  93. package/types/Treasury/FinancialAccountsResource.d.ts +0 -37
  94. package/types/Treasury/OutboundTransfers.d.ts +0 -26
  95. package/types/Treasury/OutboundTransfersResource.d.ts +0 -26
  96. package/types/Treasury/ReceivedCredits.d.ts +0 -26
  97. package/types/Treasury/ReceivedDebits.d.ts +0 -31
  98. package/types/WebhookEndpointsResource.d.ts +2 -71
  99. package/types/index.d.ts +0 -62
  100. package/types/lib.d.ts +1 -1
  101. package/types/test/typescriptTest.ts +3 -3
  102. package/cjs/resources/AccountNotices.js +0 -21
  103. package/cjs/resources/Capital/FinancingOffers.js +0 -21
  104. package/cjs/resources/Capital/FinancingSummary.js +0 -12
  105. package/cjs/resources/Capital/FinancingTransactions.js +0 -17
  106. package/cjs/resources/FinancialConnections/Institutions.js +0 -17
  107. package/cjs/resources/GiftCards/Cards.js +0 -23
  108. package/cjs/resources/GiftCards/Transactions.js +0 -33
  109. package/cjs/resources/Issuing/CreditUnderwritingRecords.js +0 -33
  110. package/cjs/resources/Issuing/DisputeSettlementDetails.js +0 -17
  111. package/cjs/resources/Issuing/FraudLiabilityDebits.js +0 -17
  112. package/cjs/resources/Margins.js +0 -22
  113. package/cjs/resources/Orders.js +0 -24
  114. package/cjs/resources/PaymentAttemptRecords.js +0 -17
  115. package/cjs/resources/PaymentRecords.js +0 -29
  116. package/cjs/resources/Tax/Associations.js +0 -9
  117. package/cjs/resources/Tax/Forms.js +0 -20
  118. package/cjs/resources/Terminal/ReaderCollectedData.js +0 -12
  119. package/esm/resources/AccountNotices.js +0 -18
  120. package/esm/resources/Capital/FinancingOffers.js +0 -18
  121. package/esm/resources/Capital/FinancingSummary.js +0 -9
  122. package/esm/resources/Capital/FinancingTransactions.js +0 -14
  123. package/esm/resources/FinancialConnections/Institutions.js +0 -14
  124. package/esm/resources/GiftCards/Cards.js +0 -20
  125. package/esm/resources/GiftCards/Transactions.js +0 -30
  126. package/esm/resources/Issuing/CreditUnderwritingRecords.js +0 -30
  127. package/esm/resources/Issuing/DisputeSettlementDetails.js +0 -14
  128. package/esm/resources/Issuing/FraudLiabilityDebits.js +0 -14
  129. package/esm/resources/Margins.js +0 -19
  130. package/esm/resources/Orders.js +0 -21
  131. package/esm/resources/PaymentAttemptRecords.js +0 -14
  132. package/esm/resources/PaymentRecords.js +0 -26
  133. package/esm/resources/Tax/Associations.js +0 -6
  134. package/esm/resources/Tax/Forms.js +0 -17
  135. package/esm/resources/Terminal/ReaderCollectedData.js +0 -9
  136. package/types/AccountNotices.d.ts +0 -113
  137. package/types/AccountNoticesResource.d.ts +0 -98
  138. package/types/Billing/MeterErrorReports.d.ts +0 -106
  139. package/types/Capital/FinancingOffers.d.ts +0 -188
  140. package/types/Capital/FinancingOffersResource.d.ts +0 -97
  141. package/types/Capital/FinancingSummary.d.ts +0 -106
  142. package/types/Capital/FinancingSummaryResource.d.ts +0 -27
  143. package/types/Capital/FinancingTransactions.d.ts +0 -135
  144. package/types/Capital/FinancingTransactionsResource.d.ts +0 -68
  145. package/types/FinancialConnections/AccountInferredBalances.d.ts +0 -38
  146. package/types/FinancialConnections/Institutions.d.ts +0 -93
  147. package/types/FinancialConnections/InstitutionsResource.d.ts +0 -47
  148. package/types/GiftCards/Cards.d.ts +0 -118
  149. package/types/GiftCards/CardsResource.d.ts +0 -159
  150. package/types/GiftCards/Transactions.d.ts +0 -129
  151. package/types/GiftCards/TransactionsResource.d.ts +0 -201
  152. package/types/InvoicePayments.d.ts +0 -113
  153. package/types/Issuing/CreditUnderwritingRecords.d.ts +0 -451
  154. package/types/Issuing/CreditUnderwritingRecordsResource.d.ts +0 -1032
  155. package/types/Issuing/DisputeSettlementDetails.d.ts +0 -73
  156. package/types/Issuing/DisputeSettlementDetailsResource.d.ts +0 -52
  157. package/types/Issuing/FraudLiabilityDebits.d.ts +0 -52
  158. package/types/Issuing/FraudLiabilityDebitsResource.d.ts +0 -52
  159. package/types/Issuing/Settlements.d.ts +0 -103
  160. package/types/Margins.d.ts +0 -56
  161. package/types/MarginsResource.d.ts +0 -114
  162. package/types/Orders.d.ts +0 -1179
  163. package/types/OrdersResource.d.ts +0 -2961
  164. package/types/PaymentAttemptRecords.d.ts +0 -242
  165. package/types/PaymentAttemptRecordsResource.d.ts +0 -47
  166. package/types/PaymentRecords.d.ts +0 -242
  167. package/types/PaymentRecordsResource.d.ts +0 -455
  168. package/types/QuoteLines.d.ts +0 -634
  169. package/types/QuotePreviewInvoices.d.ts +0 -1658
  170. package/types/QuotePreviewSubscriptionSchedules.d.ts +0 -824
  171. package/types/Tax/Associations.d.ts +0 -126
  172. package/types/Tax/AssociationsResource.d.ts +0 -29
  173. package/types/Tax/Forms.d.ts +0 -220
  174. package/types/Tax/FormsResource.d.ts +0 -107
  175. package/types/Terminal/ReaderCollectedData.d.ts +0 -51
  176. package/types/Terminal/ReaderCollectedDataResource.d.ts +0 -29
@@ -89,11 +89,6 @@ declare module 'stripe' {
89
89
  */
90
90
  amount_due: number;
91
91
 
92
- /**
93
- * Amount that was overpaid on the invoice. Overpayments are debited to the customer's credit balance.
94
- */
95
- amount_overpaid?: number;
96
-
97
92
  /**
98
93
  * The amount, in cents (or local equivalent), that was paid.
99
94
  */
@@ -109,11 +104,6 @@ declare module 'stripe' {
109
104
  */
110
105
  amount_shipping: number;
111
106
 
112
- /**
113
- * List of expected payments and corresponding due dates. This value will be null for invoices where collection_method=charge_automatically.
114
- */
115
- amounts_due?: Array<Invoice.AmountsDue> | null;
116
-
117
107
  /**
118
108
  * ID of the Connect Application that created the invoice.
119
109
  */
@@ -228,11 +218,6 @@ declare module 'stripe' {
228
218
  */
229
219
  customer_tax_ids?: Array<Invoice.CustomerTaxId> | null;
230
220
 
231
- /**
232
- * The margins applied to the invoice. Can be overridden by line item `margins`. Use `expand[]=default_margins` to expand each margin.
233
- */
234
- default_margins?: Array<string | Stripe.Margin> | null;
235
-
236
221
  /**
237
222
  * ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
238
223
  */
@@ -362,11 +347,6 @@ declare module 'stripe' {
362
347
 
363
348
  payment_settings: Invoice.PaymentSettings;
364
349
 
365
- /**
366
- * Payments for this invoice
367
- */
368
- payments?: ApiList<Stripe.InvoicePayment>;
369
-
370
350
  /**
371
351
  * End of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](https://stripe.com/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
372
352
  */
@@ -481,11 +461,6 @@ declare module 'stripe' {
481
461
  */
482
462
  total_excluding_tax: number | null;
483
463
 
484
- /**
485
- * The aggregate amounts calculated per margin across all line items.
486
- */
487
- total_margin_amounts?: Array<Invoice.TotalMarginAmount> | null;
488
-
489
464
  /**
490
465
  * Contains pretax credit amounts (ex: discount, credit grants, etc) that apply to this invoice. This is a combined list of total_pretax_credit_amounts across all invoice line items.
491
466
  */
@@ -510,52 +485,6 @@ declare module 'stripe' {
510
485
  }
511
486
 
512
487
  namespace Invoice {
513
- interface AmountsDue {
514
- /**
515
- * Incremental amount due for this payment in cents (or local equivalent).
516
- */
517
- amount: number;
518
-
519
- /**
520
- * The amount in cents (or local equivalent) that was paid for this payment.
521
- */
522
- amount_paid: number;
523
-
524
- /**
525
- * The difference between the payment's amount and amount_paid, in cents (or local equivalent).
526
- */
527
- amount_remaining: number;
528
-
529
- /**
530
- * Number of days from when invoice is finalized until the payment is due.
531
- */
532
- days_until_due: number | null;
533
-
534
- /**
535
- * An arbitrary string attached to the object. Often useful for displaying to users.
536
- */
537
- description: string | null;
538
-
539
- /**
540
- * Date on which a payment plan's payment is due.
541
- */
542
- due_date: number | null;
543
-
544
- /**
545
- * Timestamp when the payment was paid.
546
- */
547
- paid_at: number | null;
548
-
549
- /**
550
- * The status of the payment, one of `open`, `paid`, or `past_due`
551
- */
552
- status: AmountsDue.Status;
553
- }
554
-
555
- namespace AmountsDue {
556
- type Status = 'open' | 'paid' | 'past_due';
557
- }
558
-
559
488
  interface AutomaticTax {
560
489
  /**
561
490
  * If Stripe disabled automatic tax, this enum describes why.
@@ -961,15 +890,11 @@ declare module 'stripe' {
961
890
  | 'email_invalid'
962
891
  | 'expired_card'
963
892
  | 'financial_connections_account_inactive'
964
- | 'financial_connections_institution_unavailable'
965
893
  | 'financial_connections_no_successful_transaction_refresh'
966
894
  | 'forwarding_api_inactive'
967
895
  | 'forwarding_api_invalid_parameter'
968
896
  | 'forwarding_api_upstream_connection_error'
969
897
  | 'forwarding_api_upstream_connection_timeout'
970
- | 'gift_card_balance_insufficient'
971
- | 'gift_card_code_exists'
972
- | 'gift_card_inactive'
973
898
  | 'idempotency_key_in_use'
974
899
  | 'incorrect_address'
975
900
  | 'incorrect_cvc'
@@ -1059,7 +984,6 @@ declare module 'stripe' {
1059
984
  | 'return_intent_already_processed'
1060
985
  | 'routing_number_invalid'
1061
986
  | 'secret_key_required'
1062
- | 'sensitive_data_access_expired'
1063
987
  | 'sepa_unsupported_account'
1064
988
  | 'setup_attempt_failed'
1065
989
  | 'setup_intent_authentication_failure'
@@ -1077,7 +1001,6 @@ declare module 'stripe' {
1077
1001
  | 'taxes_calculation_failed'
1078
1002
  | 'terminal_location_country_unsupported'
1079
1003
  | 'terminal_reader_busy'
1080
- | 'terminal_reader_collected_data_invalid'
1081
1004
  | 'terminal_reader_hardware_fault'
1082
1005
  | 'terminal_reader_invalid_location_for_activation'
1083
1006
  | 'terminal_reader_invalid_location_for_payment'
@@ -1138,11 +1061,6 @@ declare module 'stripe' {
1138
1061
  */
1139
1062
  customer_balance: PaymentMethodOptions.CustomerBalance | null;
1140
1063
 
1141
- /**
1142
- * If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice's PaymentIntent.
1143
- */
1144
- id_bank_transfer?: PaymentMethodOptions.IdBankTransfer | null;
1145
-
1146
1064
  /**
1147
1065
  * If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice's PaymentIntent.
1148
1066
  */
@@ -1248,8 +1166,6 @@ declare module 'stripe' {
1248
1166
  }
1249
1167
  }
1250
1168
 
1251
- interface IdBankTransfer {}
1252
-
1253
1169
  interface Konbini {}
1254
1170
 
1255
1171
  interface SepaDebit {}
@@ -1284,11 +1200,6 @@ declare module 'stripe' {
1284
1200
  * The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
1285
1201
  */
1286
1202
  account_subcategories?: Array<Filters.AccountSubcategory>;
1287
-
1288
- /**
1289
- * The institution to use to filter for possible accounts to link.
1290
- */
1291
- institution?: string;
1292
1203
  }
1293
1204
 
1294
1205
  namespace Filters {
@@ -1301,11 +1212,7 @@ declare module 'stripe' {
1301
1212
  | 'payment_method'
1302
1213
  | 'transactions';
1303
1214
 
1304
- type Prefetch =
1305
- | 'balances'
1306
- | 'inferred_balances'
1307
- | 'ownership'
1308
- | 'transactions';
1215
+ type Prefetch = 'balances' | 'ownership' | 'transactions';
1309
1216
  }
1310
1217
 
1311
1218
  type VerificationMethod = 'automatic' | 'instant' | 'microdeposits';
@@ -1323,13 +1230,11 @@ declare module 'stripe' {
1323
1230
  | 'boleto'
1324
1231
  | 'card'
1325
1232
  | 'cashapp'
1326
- | 'custom'
1327
1233
  | 'customer_balance'
1328
1234
  | 'eps'
1329
1235
  | 'fpx'
1330
1236
  | 'giropay'
1331
1237
  | 'grabpay'
1332
- | 'id_bank_transfer'
1333
1238
  | 'ideal'
1334
1239
  | 'jp_credit_transfer'
1335
1240
  | 'kakao_pay'
@@ -1513,29 +1418,6 @@ declare module 'stripe' {
1513
1418
  * *Note: This attribute is populated only for invoices created on or after June 29, 2023.*
1514
1419
  */
1515
1420
  metadata: Stripe.Metadata | null;
1516
-
1517
- /**
1518
- * If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
1519
- */
1520
- pause_collection?: SubscriptionDetails.PauseCollection | null;
1521
- }
1522
-
1523
- namespace SubscriptionDetails {
1524
- interface PauseCollection {
1525
- /**
1526
- * The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
1527
- */
1528
- behavior: PauseCollection.Behavior;
1529
-
1530
- /**
1531
- * The time after which the subscription will resume collecting payments.
1532
- */
1533
- resumes_at: number | null;
1534
- }
1535
-
1536
- namespace PauseCollection {
1537
- type Behavior = 'keep_as_draft' | 'mark_uncollectible' | 'void';
1538
- }
1539
1421
  }
1540
1422
 
1541
1423
  interface ThresholdReason {
@@ -1576,18 +1458,6 @@ declare module 'stripe' {
1576
1458
  discount: string | Stripe.Discount | Stripe.DeletedDiscount;
1577
1459
  }
1578
1460
 
1579
- interface TotalMarginAmount {
1580
- /**
1581
- * The amount, in cents (or local equivalent), of the reduction in line item amount.
1582
- */
1583
- amount: number;
1584
-
1585
- /**
1586
- * The margin that was applied to get this margin amount.
1587
- */
1588
- margin: string | Stripe.Margin;
1589
- }
1590
-
1591
1461
  interface TotalPretaxCreditAmount {
1592
1462
  /**
1593
1463
  * The amount, in cents (or local equivalent), of the pretax credit amount.
@@ -1607,11 +1477,6 @@ declare module 'stripe' {
1607
1477
  */
1608
1478
  discount?: string | Stripe.Discount | Stripe.DeletedDiscount;
1609
1479
 
1610
- /**
1611
- * The margin that was applied to get this pretax credit amount.
1612
- */
1613
- margin?: string | Stripe.Margin;
1614
-
1615
1480
  /**
1616
1481
  * Type of the pretax credit amount referenced.
1617
1482
  */
@@ -1619,7 +1484,7 @@ declare module 'stripe' {
1619
1484
  }
1620
1485
 
1621
1486
  namespace TotalPretaxCreditAmount {
1622
- type Type = 'credit_balance_transaction' | 'discount' | 'margin';
1487
+ type Type = 'credit_balance_transaction' | 'discount';
1623
1488
  }
1624
1489
 
1625
1490
  interface TotalTaxAmount {