stripe 17.2.1 → 17.3.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 (82) hide show
  1. package/CHANGELOG.md +38 -0
  2. package/VERSION +1 -1
  3. package/cjs/apiVersion.js +1 -1
  4. package/cjs/resources/TestHelpers/Issuing/Cards.js +4 -0
  5. package/cjs/resources/V2/Core/EventDestinations.js +41 -0
  6. package/cjs/resources/V2/Core.js +2 -0
  7. package/cjs/stripe.core.js +1 -1
  8. package/esm/apiVersion.js +1 -1
  9. package/esm/resources/TestHelpers/Issuing/Cards.js +4 -0
  10. package/esm/resources/V2/Core/EventDestinations.js +38 -0
  11. package/esm/resources/V2/Core.js +2 -0
  12. package/esm/stripe.core.js +1 -1
  13. package/package.json +1 -1
  14. package/types/AccountSessions.d.ts +30 -5
  15. package/types/AccountSessionsResource.d.ts +30 -5
  16. package/types/Accounts.d.ts +56 -2
  17. package/types/AccountsResource.d.ts +171 -3
  18. package/types/Billing/CreditBalanceSummary.d.ts +4 -4
  19. package/types/Billing/CreditBalanceSummaryResource.d.ts +2 -2
  20. package/types/Billing/CreditBalanceTransactions.d.ts +10 -10
  21. package/types/Billing/CreditGrants.d.ts +11 -8
  22. package/types/Billing/CreditGrantsResource.d.ts +6 -6
  23. package/types/Billing/Meters.d.ts +2 -0
  24. package/types/BillingPortal/Configurations.d.ts +22 -0
  25. package/types/BillingPortal/ConfigurationsResource.d.ts +56 -4
  26. package/types/Charges.d.ts +85 -0
  27. package/types/Checkout/Sessions.d.ts +82 -1
  28. package/types/Checkout/SessionsResource.d.ts +86 -0
  29. package/types/ConfirmationTokens.d.ts +75 -0
  30. package/types/CreditNoteLineItems.d.ts +3 -0
  31. package/types/CreditNotes.d.ts +3 -0
  32. package/types/CreditNotesResource.d.ts +3 -3
  33. package/types/CustomersResource.d.ts +21 -3
  34. package/types/Disputes.d.ts +152 -0
  35. package/types/DisputesResource.d.ts +120 -0
  36. package/types/EventTypes.d.ts +37 -2
  37. package/types/Events.d.ts +2 -0
  38. package/types/Forwarding/Requests.d.ts +5 -0
  39. package/types/Forwarding/RequestsResource.d.ts +5 -0
  40. package/types/InvoiceLineItems.d.ts +3 -0
  41. package/types/Invoices.d.ts +15 -1
  42. package/types/InvoicesResource.d.ts +44 -3
  43. package/types/Issuing/CardsResource.d.ts +1 -1
  44. package/types/Mandates.d.ts +8 -0
  45. package/types/PaymentIntents.d.ts +84 -0
  46. package/types/PaymentIntentsResource.d.ts +554 -7
  47. package/types/PaymentLinks.d.ts +1 -0
  48. package/types/PaymentLinksResource.d.ts +2 -0
  49. package/types/PaymentMethodConfigurations.d.ts +36 -0
  50. package/types/PaymentMethodConfigurationsResource.d.ts +52 -2
  51. package/types/PaymentMethodDomains.d.ts +28 -0
  52. package/types/PaymentMethods.d.ts +75 -0
  53. package/types/PaymentMethodsResource.d.ts +80 -1
  54. package/types/Persons.d.ts +1 -1
  55. package/types/Refunds.d.ts +5 -4
  56. package/types/SetupAttempts.d.ts +8 -0
  57. package/types/SetupIntentsResource.d.ts +174 -3
  58. package/types/Subscriptions.d.ts +5 -0
  59. package/types/SubscriptionsResource.d.ts +12 -2
  60. package/types/Tax/CalculationLineItems.d.ts +1 -0
  61. package/types/Tax/Calculations.d.ts +33 -1
  62. package/types/Tax/CalculationsResource.d.ts +7 -1
  63. package/types/Tax/Registrations.d.ts +82 -0
  64. package/types/Tax/RegistrationsResource.d.ts +109 -0
  65. package/types/Tax/Transactions.d.ts +8 -1
  66. package/types/TaxIds.d.ts +7 -1
  67. package/types/TaxIdsResource.d.ts +7 -1
  68. package/types/TaxRates.d.ts +25 -0
  69. package/types/TaxRatesResource.d.ts +2 -0
  70. package/types/Terminal/Configurations.d.ts +19 -0
  71. package/types/Terminal/ConfigurationsResource.d.ts +44 -0
  72. package/types/TestHelpers/ConfirmationTokensResource.d.ts +58 -1
  73. package/types/TestHelpers/Issuing/CardsResource.d.ts +22 -0
  74. package/types/TokensResource.d.ts +2 -2
  75. package/types/Treasury/FinancialAccounts.d.ts +1 -1
  76. package/types/UsageRecordSummaries.d.ts +1 -1
  77. package/types/V2/Core/EventDestinationsResource.d.ts +281 -0
  78. package/types/V2/Core/EventsResource.d.ts +1 -1
  79. package/types/V2/CoreResource.d.ts +1 -0
  80. package/types/V2/EventDestinations.d.ts +164 -0
  81. package/types/WebhookEndpointsResource.d.ts +6 -1
  82. package/types/index.d.ts +2 -0
@@ -0,0 +1,164 @@
1
+ // File generated from our OpenAPI spec
2
+
3
+ declare module 'stripe' {
4
+ namespace Stripe {
5
+ namespace V2 {
6
+ /**
7
+ * The EventDestination object.
8
+ */
9
+ interface EventDestination {
10
+ /**
11
+ * Unique identifier for the object.
12
+ */
13
+ id: string;
14
+
15
+ /**
16
+ * String representing the object's type. Objects of the same type share the same value of the object field.
17
+ */
18
+ object: 'v2.core.event_destination';
19
+
20
+ /**
21
+ * Amazon EventBridge configuration.
22
+ */
23
+ amazon_eventbridge: EventDestination.AmazonEventbridge | null;
24
+
25
+ /**
26
+ * Time at which the object was created.
27
+ */
28
+ created: string;
29
+
30
+ /**
31
+ * An optional description of what the event destination is used for.
32
+ */
33
+ description: string;
34
+
35
+ /**
36
+ * The list of events to enable for this endpoint.
37
+ */
38
+ enabled_events: Array<string>;
39
+
40
+ /**
41
+ * Payload type of events being subscribed to.
42
+ */
43
+ event_payload: EventDestination.EventPayload;
44
+
45
+ /**
46
+ * Where events should be routed from.
47
+ */
48
+ events_from: Array<EventDestination.EventsFrom> | null;
49
+
50
+ /**
51
+ * Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
52
+ */
53
+ livemode: boolean;
54
+
55
+ /**
56
+ * Metadata.
57
+ */
58
+ metadata: Stripe.Metadata | null;
59
+
60
+ /**
61
+ * Event destination name.
62
+ */
63
+ name: string;
64
+
65
+ /**
66
+ * If using the snapshot event payload, the API version events are rendered as.
67
+ */
68
+ snapshot_api_version: string | null;
69
+
70
+ /**
71
+ * Status. It can be set to either enabled or disabled.
72
+ */
73
+ status: EventDestination.Status;
74
+
75
+ /**
76
+ * Additional information about event destination status.
77
+ */
78
+ status_details: EventDestination.StatusDetails | null;
79
+
80
+ /**
81
+ * Event destination type.
82
+ */
83
+ type: EventDestination.Type;
84
+
85
+ /**
86
+ * Time at which the object was last updated.
87
+ */
88
+ updated: string;
89
+
90
+ /**
91
+ * Webhook endpoint configuration.
92
+ */
93
+ webhook_endpoint: EventDestination.WebhookEndpoint | null;
94
+ }
95
+
96
+ namespace EventDestination {
97
+ interface AmazonEventbridge {
98
+ /**
99
+ * The AWS account ID.
100
+ */
101
+ aws_account_id: string;
102
+
103
+ /**
104
+ * The ARN of the AWS event source.
105
+ */
106
+ aws_event_source_arn: string;
107
+
108
+ /**
109
+ * The state of the AWS event source.
110
+ */
111
+ aws_event_source_status: AmazonEventbridge.AwsEventSourceStatus;
112
+ }
113
+
114
+ namespace AmazonEventbridge {
115
+ type AwsEventSourceStatus =
116
+ | 'active'
117
+ | 'deleted'
118
+ | 'pending'
119
+ | 'unknown';
120
+ }
121
+
122
+ type EventPayload = 'snapshot' | 'thin';
123
+
124
+ type EventsFrom = 'other_accounts' | 'self';
125
+
126
+ type Status = 'disabled' | 'enabled';
127
+
128
+ interface StatusDetails {
129
+ /**
130
+ * Details about why the event destination has been disabled.
131
+ */
132
+ disabled: StatusDetails.Disabled | null;
133
+ }
134
+
135
+ namespace StatusDetails {
136
+ interface Disabled {
137
+ /**
138
+ * Reason event destination has been disabled.
139
+ */
140
+ reason: Disabled.Reason;
141
+ }
142
+
143
+ namespace Disabled {
144
+ type Reason = 'no_aws_event_source_exists' | 'user';
145
+ }
146
+ }
147
+
148
+ type Type = 'amazon_eventbridge' | 'webhook_endpoint';
149
+
150
+ interface WebhookEndpoint {
151
+ /**
152
+ * The signing secret of the webhook endpoint, only includable on creation.
153
+ */
154
+ signing_secret: string | null;
155
+
156
+ /**
157
+ * The URL of the webhook endpoint, includable.
158
+ */
159
+ url: string | null;
160
+ }
161
+ }
162
+ }
163
+ }
164
+ }
@@ -143,7 +143,8 @@ declare module 'stripe' {
143
143
  | '2023-10-16'
144
144
  | '2024-04-10'
145
145
  | '2024-06-20'
146
- | '2024-09-30.acacia';
146
+ | '2024-09-30.acacia'
147
+ | '2024-10-28.acacia';
147
148
 
148
149
  type EnabledEvent =
149
150
  | '*'
@@ -267,6 +268,7 @@ declare module 'stripe' {
267
268
  | 'issuing_token.created'
268
269
  | 'issuing_token.updated'
269
270
  | 'issuing_transaction.created'
271
+ | 'issuing_transaction.purchase_details_receipt_updated'
270
272
  | 'issuing_transaction.updated'
271
273
  | 'mandate.updated'
272
274
  | 'payment_intent.amount_capturable_updated'
@@ -310,6 +312,7 @@ declare module 'stripe' {
310
312
  | 'radar.early_fraud_warning.created'
311
313
  | 'radar.early_fraud_warning.updated'
312
314
  | 'refund.created'
315
+ | 'refund.failed'
313
316
  | 'refund.updated'
314
317
  | 'reporting.report_run.failed'
315
318
  | 'reporting.report_run.succeeded'
@@ -548,6 +551,7 @@ declare module 'stripe' {
548
551
  | 'issuing_token.created'
549
552
  | 'issuing_token.updated'
550
553
  | 'issuing_transaction.created'
554
+ | 'issuing_transaction.purchase_details_receipt_updated'
551
555
  | 'issuing_transaction.updated'
552
556
  | 'mandate.updated'
553
557
  | 'payment_intent.amount_capturable_updated'
@@ -591,6 +595,7 @@ declare module 'stripe' {
591
595
  | 'radar.early_fraud_warning.created'
592
596
  | 'radar.early_fraud_warning.updated'
593
597
  | 'refund.created'
598
+ | 'refund.failed'
594
599
  | 'refund.updated'
595
600
  | 'reporting.report_run.failed'
596
601
  | 'reporting.report_run.succeeded'
package/types/index.d.ts CHANGED
@@ -134,6 +134,7 @@
134
134
  ///<reference path='./V2/Billing/MeterEventStreamResource.d.ts' />
135
135
  ///<reference path='./V2/Billing/MeterEventsResource.d.ts' />
136
136
  ///<reference path='./V2/BillingResource.d.ts' />
137
+ ///<reference path='./V2/Core/EventDestinationsResource.d.ts' />
137
138
  ///<reference path='./V2/Core/EventsResource.d.ts' />
138
139
  ///<reference path='./V2/CoreResource.d.ts' />
139
140
  ///<reference path='./V2Resource.d.ts' />
@@ -281,6 +282,7 @@
281
282
  ///<reference path='./V2/Billing/MeterEventAdjustments.d.ts' />
282
283
  ///<reference path='./V2/Billing/MeterEventSessions.d.ts' />
283
284
  ///<reference path='./V2/Billing/MeterEvents.d.ts' />
285
+ ///<reference path='./V2/EventDestinations.d.ts' />
284
286
  ///<reference path='./V2/Events.d.ts' />
285
287
  ///<reference path='./WebhookEndpoints.d.ts' />
286
288
  // Imports: The end of the section generated from our OpenAPI spec