stripe 18.4.0-beta.2 → 18.5.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.
- package/CHANGELOG.md +39 -10
- package/OPENAPI_VERSION +1 -1
- package/VERSION +1 -1
- package/cjs/apiVersion.js +1 -1
- package/cjs/resources/Billing/MeterUsage.js +12 -0
- package/cjs/resources/Terminal/OnboardingLinks.js +12 -0
- package/cjs/resources.js +4 -0
- package/cjs/stripe.core.js +2 -1
- package/esm/apiVersion.js +1 -1
- package/esm/resources/Billing/MeterUsage.js +9 -0
- package/esm/resources/Terminal/OnboardingLinks.js +9 -0
- package/esm/resources.js +4 -0
- package/esm/stripe.core.js +2 -1
- package/package.json +1 -1
- package/types/AccountLinksResource.d.ts +3 -1
- package/types/AccountSessions.d.ts +30 -0
- package/types/AccountSessionsResource.d.ts +36 -0
- package/types/Accounts.d.ts +1 -1
- package/types/AccountsResource.d.ts +3 -3
- package/types/BalanceSettings.d.ts +6 -4
- package/types/BalanceSettingsResource.d.ts +8 -6
- package/types/Billing/CreditGrantsResource.d.ts +1 -1
- package/types/Billing/MeterUsage.d.ts +32 -0
- package/types/Billing/MeterUsageResource.d.ts +685 -0
- package/types/Billing/MeterUsageRows.d.ts +49 -0
- package/types/BillingPortal/Configurations.d.ts +21 -0
- package/types/BillingPortal/ConfigurationsResource.d.ts +48 -0
- package/types/Capabilities.d.ts +1 -6
- package/types/Charges.d.ts +10 -5
- package/types/Checkout/Sessions.d.ts +24 -1
- package/types/Checkout/SessionsResource.d.ts +108 -0
- package/types/ConfirmationTokens.d.ts +3 -3
- package/types/Customers.d.ts +1 -1
- package/types/Disputes.d.ts +23 -1
- package/types/Events.d.ts +14 -26
- package/types/FxQuotes.d.ts +6 -4
- package/types/Identity/VerificationSessions.d.ts +2 -2
- package/types/InvoiceItemsResource.d.ts +1 -1
- package/types/Invoices.d.ts +38 -0
- package/types/InvoicesResource.d.ts +115 -6
- package/types/PaymentAttemptRecords.d.ts +9 -4
- package/types/PaymentIntents.d.ts +1 -1
- package/types/PaymentIntentsResource.d.ts +966 -40
- package/types/PaymentLinks.d.ts +5 -0
- package/types/PaymentLinksResource.d.ts +102 -3
- package/types/PaymentMethods.d.ts +3 -3
- package/types/PaymentMethodsResource.d.ts +1 -1
- package/types/PaymentRecords.d.ts +9 -4
- package/types/QuotePreviewInvoices.d.ts +38 -0
- package/types/QuotesResource.d.ts +3 -0
- package/types/Radar/ValueLists.d.ts +1 -1
- package/types/Radar/ValueListsResource.d.ts +1 -1
- package/types/Refunds.d.ts +1 -1
- package/types/Reporting/ReportRunsResource.d.ts +1 -0
- package/types/Reviews.d.ts +2 -2
- package/types/SetupAttempts.d.ts +1 -1
- package/types/SubscriptionItemsResource.d.ts +2 -2
- package/types/SubscriptionSchedulesResource.d.ts +47 -2
- package/types/Subscriptions.d.ts +38 -0
- package/types/SubscriptionsResource.d.ts +86 -1
- package/types/Tax/Registrations.d.ts +228 -27
- package/types/Tax/RegistrationsResource.d.ts +648 -27
- package/types/Terminal/Configurations.d.ts +76 -0
- package/types/Terminal/ConfigurationsResource.d.ts +176 -0
- package/types/Terminal/OnboardingLinks.d.ts +57 -0
- package/types/Terminal/OnboardingLinksResource.d.ts +62 -0
- package/types/V2/Core/AccountLinks.d.ts +66 -4
- package/types/V2/Core/AccountLinksResource.d.ts +65 -3
- package/types/V2/Core/Accounts.d.ts +22 -0
- package/types/V2/Core/AccountsResource.d.ts +44 -0
- package/types/V2/EventTypes.d.ts +32 -25
- package/types/V2/MoneyManagement/PayoutMethods.d.ts +9 -0
- package/types/V2/Payments/OffSessionPayments.d.ts +40 -23
- package/types/V2/Payments/OffSessionPaymentsResource.d.ts +34 -19
- package/types/V2/TestHelpers/FinancialAddressesResource.d.ts +2 -0
- package/types/WebhookEndpointsResource.d.ts +2 -1
- package/types/index.d.ts +7 -0
- package/types/lib.d.ts +2 -1
- package/types/test/typescriptTest.ts +3 -3
|
@@ -6,57 +6,65 @@ declare module 'stripe' {
|
|
|
6
6
|
namespace Payments {
|
|
7
7
|
interface OffSessionPaymentCreateParams {
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
9
|
+
* The “presentment amount” to be collected from the customer.
|
|
10
10
|
*/
|
|
11
11
|
amount: Amount;
|
|
12
12
|
|
|
13
13
|
/**
|
|
14
|
-
* The frequency of the
|
|
14
|
+
* The frequency of the underlying payment.
|
|
15
15
|
*/
|
|
16
16
|
cadence: OffSessionPaymentCreateParams.Cadence;
|
|
17
17
|
|
|
18
18
|
/**
|
|
19
|
-
* Customer
|
|
19
|
+
* ID of the Customer to which this OffSessionPayment belongs.
|
|
20
20
|
*/
|
|
21
21
|
customer: string;
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
|
-
*
|
|
24
|
+
* Set of [key-value pairs](https://docs.corp.stripe.com/api/metadata) that you can
|
|
25
|
+
* attach to an object. This can be useful for storing additional information about
|
|
26
|
+
* the object in a structured format. Learn more about
|
|
27
|
+
* [storing information in metadata](https://docs.corp.stripe.com/payments/payment-intents#storing-information-in-metadata).
|
|
25
28
|
*/
|
|
26
29
|
metadata: Stripe.MetadataParam;
|
|
27
30
|
|
|
28
31
|
/**
|
|
29
|
-
*
|
|
32
|
+
* ID of the payment method used in this OffSessionPayment.
|
|
30
33
|
*/
|
|
31
34
|
payment_method: string;
|
|
32
35
|
|
|
33
36
|
/**
|
|
34
|
-
* The
|
|
37
|
+
* The account (if any) for which the funds of the OffSessionPayment are intended.
|
|
35
38
|
*/
|
|
36
39
|
on_behalf_of?: string;
|
|
37
40
|
|
|
38
41
|
/**
|
|
39
|
-
*
|
|
42
|
+
* Details about the OffSessionPayment retries.
|
|
40
43
|
*/
|
|
41
44
|
retry_details?: OffSessionPaymentCreateParams.RetryDetails;
|
|
42
45
|
|
|
43
46
|
/**
|
|
44
|
-
*
|
|
47
|
+
* Text that appears on the customer's statement as the statement descriptor for a
|
|
48
|
+
* non-card charge. This value overrides the account's default statement descriptor.
|
|
49
|
+
* For information about requirements, including the 22-character limit, see the
|
|
50
|
+
* [Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
|
|
45
51
|
*/
|
|
46
52
|
statement_descriptor?: string;
|
|
47
53
|
|
|
48
54
|
/**
|
|
49
|
-
*
|
|
55
|
+
* Provides information about a card charge. Concatenated to the account's
|
|
56
|
+
* [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static)
|
|
57
|
+
* to form the complete statement descriptor that appears on the customer's statement.
|
|
50
58
|
*/
|
|
51
59
|
statement_descriptor_suffix?: string;
|
|
52
60
|
|
|
53
61
|
/**
|
|
54
|
-
* Test clock
|
|
62
|
+
* Test clock that can be used to advance the retry attempts in a sandbox.
|
|
55
63
|
*/
|
|
56
64
|
test_clock?: string;
|
|
57
65
|
|
|
58
66
|
/**
|
|
59
|
-
*
|
|
67
|
+
* The data that automatically creates a Transfer after the payment finalizes. Learn more about the use case for [connected accounts](https://docs.corp.stripe.com/payments/connected-accounts).
|
|
60
68
|
*/
|
|
61
69
|
transfer_data?: OffSessionPaymentCreateParams.TransferData;
|
|
62
70
|
}
|
|
@@ -66,7 +74,7 @@ declare module 'stripe' {
|
|
|
66
74
|
|
|
67
75
|
interface RetryDetails {
|
|
68
76
|
/**
|
|
69
|
-
*
|
|
77
|
+
* Indicates the strategy for how you want Stripe to retry the payment.
|
|
70
78
|
*/
|
|
71
79
|
retry_strategy: RetryDetails.RetryStrategy;
|
|
72
80
|
}
|
|
@@ -77,12 +85,19 @@ declare module 'stripe' {
|
|
|
77
85
|
|
|
78
86
|
interface TransferData {
|
|
79
87
|
/**
|
|
80
|
-
*
|
|
88
|
+
* The amount transferred to the destination account. This transfer will occur
|
|
89
|
+
* automatically after the payment succeeds. If no amount is specified, by default
|
|
90
|
+
* the entire payment amount is transferred to the destination account. The amount
|
|
91
|
+
* must be less than or equal to the
|
|
92
|
+
* [amount_requested](https://docs.corp.stripe.com/api/v2/off-session-payments/object?api-version=2025-05-28.preview#v2_off_session_payment_object-amount_requested),
|
|
93
|
+
* and must be a positive integer representing how much to transfer in the smallest
|
|
94
|
+
* currency unit (e.g., 100 cents to charge $1.00).
|
|
81
95
|
*/
|
|
82
96
|
amount?: number;
|
|
83
97
|
|
|
84
98
|
/**
|
|
85
|
-
*
|
|
99
|
+
* The account (if any) that the payment is attributed to for tax reporting, and
|
|
100
|
+
* where funds from the payment are transferred to after payment success.
|
|
86
101
|
*/
|
|
87
102
|
destination: string;
|
|
88
103
|
}
|
|
@@ -96,7 +111,7 @@ declare module 'stripe' {
|
|
|
96
111
|
namespace Payments {
|
|
97
112
|
interface OffSessionPaymentListParams {
|
|
98
113
|
/**
|
|
99
|
-
* The page size limit
|
|
114
|
+
* The page size limit. If not provided, the default is 20.
|
|
100
115
|
*/
|
|
101
116
|
limit?: number;
|
|
102
117
|
}
|
|
@@ -109,7 +124,7 @@ declare module 'stripe' {
|
|
|
109
124
|
namespace Payments {
|
|
110
125
|
class OffSessionPaymentsResource {
|
|
111
126
|
/**
|
|
112
|
-
*
|
|
127
|
+
* Creates an OffSessionPayment object.
|
|
113
128
|
*/
|
|
114
129
|
create(
|
|
115
130
|
params: OffSessionPaymentCreateParams,
|
|
@@ -117,7 +132,7 @@ declare module 'stripe' {
|
|
|
117
132
|
): Promise<Stripe.Response<Stripe.V2.Payments.OffSessionPayment>>;
|
|
118
133
|
|
|
119
134
|
/**
|
|
120
|
-
*
|
|
135
|
+
* Retrieves the details of an OffSessionPayment that has previously been created.
|
|
121
136
|
*/
|
|
122
137
|
retrieve(
|
|
123
138
|
id: string,
|
|
@@ -130,7 +145,7 @@ declare module 'stripe' {
|
|
|
130
145
|
): Promise<Stripe.Response<Stripe.V2.Payments.OffSessionPayment>>;
|
|
131
146
|
|
|
132
147
|
/**
|
|
133
|
-
*
|
|
148
|
+
* Returns a list of OffSessionPayments matching a filter.
|
|
134
149
|
*/
|
|
135
150
|
list(
|
|
136
151
|
params?: OffSessionPaymentListParams,
|
|
@@ -141,7 +156,7 @@ declare module 'stripe' {
|
|
|
141
156
|
): ApiListPromise<Stripe.V2.Payments.OffSessionPayment>;
|
|
142
157
|
|
|
143
158
|
/**
|
|
144
|
-
* Cancel
|
|
159
|
+
* Cancel an OffSessionPayment that has previously been created.
|
|
145
160
|
*/
|
|
146
161
|
cancel(
|
|
147
162
|
id: string,
|
|
@@ -34,6 +34,7 @@ declare module 'stripe' {
|
|
|
34
34
|
class FinancialAddressesResource {
|
|
35
35
|
/**
|
|
36
36
|
* Simulate crediting a FinancialAddress in a Sandbox environment. This can be used to add virtual funds and increase your balance for testing.
|
|
37
|
+
* @throws Stripe.FeatureNotEnabledError
|
|
37
38
|
*/
|
|
38
39
|
credit(
|
|
39
40
|
id: string,
|
|
@@ -45,6 +46,7 @@ declare module 'stripe' {
|
|
|
45
46
|
|
|
46
47
|
/**
|
|
47
48
|
* Generates microdeposits for a FinancialAddress in a Sandbox environment.
|
|
49
|
+
* @throws Stripe.FeatureNotEnabledError
|
|
48
50
|
*/
|
|
49
51
|
generateMicrodeposits(
|
|
50
52
|
id: string,
|
package/types/index.d.ts
CHANGED
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
///<reference path='./Billing/CreditGrantsResource.d.ts' />
|
|
27
27
|
///<reference path='./Billing/MeterEventAdjustmentsResource.d.ts' />
|
|
28
28
|
///<reference path='./Billing/MeterEventsResource.d.ts' />
|
|
29
|
+
///<reference path='./Billing/MeterUsageResource.d.ts' />
|
|
29
30
|
///<reference path='./Billing/MetersResource.d.ts' />
|
|
30
31
|
///<reference path='./BillingPortal/ConfigurationsResource.d.ts' />
|
|
31
32
|
///<reference path='./BillingPortal/SessionsResource.d.ts' />
|
|
@@ -118,6 +119,7 @@
|
|
|
118
119
|
///<reference path='./Terminal/ConfigurationsResource.d.ts' />
|
|
119
120
|
///<reference path='./Terminal/ConnectionTokensResource.d.ts' />
|
|
120
121
|
///<reference path='./Terminal/LocationsResource.d.ts' />
|
|
122
|
+
///<reference path='./Terminal/OnboardingLinksResource.d.ts' />
|
|
121
123
|
///<reference path='./Terminal/ReaderCollectedDataResource.d.ts' />
|
|
122
124
|
///<reference path='./Terminal/ReadersResource.d.ts' />
|
|
123
125
|
///<reference path='./TestHelpers/ConfirmationTokensResource.d.ts' />
|
|
@@ -196,6 +198,8 @@
|
|
|
196
198
|
///<reference path='./Billing/MeterEventAdjustments.d.ts' />
|
|
197
199
|
///<reference path='./Billing/MeterEventSummaries.d.ts' />
|
|
198
200
|
///<reference path='./Billing/MeterEvents.d.ts' />
|
|
201
|
+
///<reference path='./Billing/MeterUsage.d.ts' />
|
|
202
|
+
///<reference path='./Billing/MeterUsageRows.d.ts' />
|
|
199
203
|
///<reference path='./Billing/Meters.d.ts' />
|
|
200
204
|
///<reference path='./BillingPortal/Configurations.d.ts' />
|
|
201
205
|
///<reference path='./BillingPortal/Sessions.d.ts' />
|
|
@@ -321,6 +325,7 @@
|
|
|
321
325
|
///<reference path='./Terminal/Configurations.d.ts' />
|
|
322
326
|
///<reference path='./Terminal/ConnectionTokens.d.ts' />
|
|
323
327
|
///<reference path='./Terminal/Locations.d.ts' />
|
|
328
|
+
///<reference path='./Terminal/OnboardingLinks.d.ts' />
|
|
324
329
|
///<reference path='./Terminal/ReaderCollectedData.d.ts' />
|
|
325
330
|
///<reference path='./Terminal/Readers.d.ts' />
|
|
326
331
|
///<reference path='./TestHelpers/TestClocks.d.ts' />
|
|
@@ -457,6 +462,7 @@ declare module 'stripe' {
|
|
|
457
462
|
meters: Stripe.Billing.MetersResource;
|
|
458
463
|
meterEvents: Stripe.Billing.MeterEventsResource;
|
|
459
464
|
meterEventAdjustments: Stripe.Billing.MeterEventAdjustmentsResource;
|
|
465
|
+
meterUsage: Stripe.Billing.MeterUsageResource;
|
|
460
466
|
};
|
|
461
467
|
billingPortal: {
|
|
462
468
|
configurations: Stripe.BillingPortal.ConfigurationsResource;
|
|
@@ -532,6 +538,7 @@ declare module 'stripe' {
|
|
|
532
538
|
configurations: Stripe.Terminal.ConfigurationsResource;
|
|
533
539
|
connectionTokens: Stripe.Terminal.ConnectionTokensResource;
|
|
534
540
|
locations: Stripe.Terminal.LocationsResource;
|
|
541
|
+
onboardingLinks: Stripe.Terminal.OnboardingLinksResource;
|
|
535
542
|
readers: Stripe.Terminal.ReadersResource;
|
|
536
543
|
readerCollectedData: Stripe.Terminal.ReaderCollectedDataResource;
|
|
537
544
|
};
|
package/types/lib.d.ts
CHANGED
|
@@ -27,7 +27,8 @@ declare module 'stripe' {
|
|
|
27
27
|
}): (...args: any[]) => Response<ResponseObject>; //eslint-disable-line @typescript-eslint/no-explicit-any
|
|
28
28
|
static MAX_BUFFERED_REQUEST_METRICS: number;
|
|
29
29
|
}
|
|
30
|
-
export type LatestApiVersion = '2025-
|
|
30
|
+
export type LatestApiVersion = '2025-07-30.preview';
|
|
31
|
+
export const API_VERSION: string;
|
|
31
32
|
export type HttpAgent = Agent;
|
|
32
33
|
export type HttpProtocol = 'http' | 'https';
|
|
33
34
|
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import Stripe from 'stripe';
|
|
10
10
|
|
|
11
11
|
let stripe = new Stripe('sk_test_123', {
|
|
12
|
-
apiVersion: '2025-
|
|
12
|
+
apiVersion: '2025-07-30.preview',
|
|
13
13
|
});
|
|
14
14
|
|
|
15
15
|
stripe = new Stripe('sk_test_123');
|
|
@@ -26,7 +26,7 @@ stripe = new Stripe('sk_test_123', {
|
|
|
26
26
|
|
|
27
27
|
// Check config object.
|
|
28
28
|
stripe = new Stripe('sk_test_123', {
|
|
29
|
-
apiVersion: '2025-
|
|
29
|
+
apiVersion: '2025-07-30.preview',
|
|
30
30
|
typescript: true,
|
|
31
31
|
maxNetworkRetries: 1,
|
|
32
32
|
timeout: 1000,
|
|
@@ -44,7 +44,7 @@ stripe = new Stripe('sk_test_123', {
|
|
|
44
44
|
description: 'test',
|
|
45
45
|
};
|
|
46
46
|
const opts: Stripe.RequestOptions = {
|
|
47
|
-
apiVersion: '2025-
|
|
47
|
+
apiVersion: '2025-07-30.preview',
|
|
48
48
|
};
|
|
49
49
|
const customer: Stripe.Customer = await stripe.customers.create(params, opts);
|
|
50
50
|
|