stripe 18.1.1 → 18.2.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.
- package/CHANGELOG.md +66 -32
- package/OPENAPI_VERSION +1 -1
- package/VERSION +1 -1
- package/cjs/apiVersion.js +1 -1
- package/cjs/resources/Invoices.js +4 -0
- package/cjs/resources/Terminal/Readers.js +4 -0
- package/cjs/resources/TestHelpers/Terminal/Readers.js +8 -0
- package/cjs/stripe.core.js +1 -1
- package/esm/apiVersion.js +1 -1
- package/esm/resources/Invoices.js +4 -0
- package/esm/resources/Terminal/Readers.js +4 -0
- package/esm/resources/TestHelpers/Terminal/Readers.js +8 -0
- package/esm/stripe.core.js +1 -1
- package/package.json +1 -1
- package/types/AccountSessions.d.ts +65 -0
- package/types/AccountSessionsResource.d.ts +77 -0
- package/types/Accounts.d.ts +22 -15
- package/types/AccountsResource.d.ts +79 -55
- package/types/Balance.d.ts +83 -1
- package/types/BalanceResource.d.ts +1 -1
- package/types/BalanceTransactions.d.ts +10 -0
- package/types/BankAccounts.d.ts +3 -3
- package/types/Billing/Alerts.d.ts +1 -1
- package/types/Billing/AlertsResource.d.ts +2 -2
- package/types/BillingPortal/Sessions.d.ts +1 -1
- package/types/Capabilities.d.ts +1 -1
- package/types/Cards.d.ts +2 -2
- package/types/Charges.d.ts +20 -0
- package/types/ChargesResource.d.ts +4 -4
- package/types/Checkout/Sessions.d.ts +120 -105
- package/types/Checkout/SessionsResource.d.ts +117 -108
- package/types/ConfirmationTokens.d.ts +4 -4
- package/types/CountrySpecs.d.ts +1 -1
- package/types/CreditNotes.d.ts +13 -3
- package/types/CreditNotesResource.d.ts +7 -8
- package/types/CustomerSessions.d.ts +3 -3
- package/types/CustomersResource.d.ts +7 -7
- package/types/Disputes.d.ts +1 -1
- package/types/DisputesResource.d.ts +1 -1
- package/types/EventTypes.d.ts +17 -0
- package/types/Events.d.ts +4 -0
- package/types/Files.d.ts +1 -1
- package/types/FilesResource.d.ts +1 -1
- package/types/Identity/VerificationReports.d.ts +17 -0
- package/types/Identity/VerificationSessions.d.ts +19 -2
- package/types/Identity/VerificationSessionsResource.d.ts +5 -5
- package/types/InvoiceItems.d.ts +1 -1
- package/types/InvoiceLineItems.d.ts +1 -1
- package/types/InvoicePayments.d.ts +9 -2
- package/types/Invoices.d.ts +7 -6
- package/types/InvoicesResource.d.ts +88 -11
- package/types/Issuing/AuthorizationsResource.d.ts +4 -4
- package/types/Issuing/CardsResource.d.ts +3 -0
- package/types/Issuing/DisputesResource.d.ts +2 -2
- package/types/LineItems.d.ts +2 -2
- package/types/PaymentIntents.d.ts +143 -128
- package/types/PaymentIntentsResource.d.ts +492 -441
- package/types/PaymentMethodConfigurations.d.ts +180 -0
- package/types/PaymentMethodConfigurationsResource.d.ts +254 -4
- package/types/PaymentMethodDomainsResource.d.ts +1 -1
- package/types/PaymentMethods.d.ts +4 -4
- package/types/PaymentMethodsResource.d.ts +8 -8
- package/types/Payouts.d.ts +2 -2
- package/types/PayoutsResource.d.ts +2 -2
- package/types/Persons.d.ts +10 -10
- package/types/PlansResource.d.ts +1 -1
- package/types/PricesResource.d.ts +2 -2
- package/types/ProductsResource.d.ts +1 -1
- package/types/PromotionCodesResource.d.ts +1 -1
- package/types/Quotes.d.ts +6 -6
- package/types/Radar/EarlyFraudWarningsResource.d.ts +1 -1
- package/types/Refunds.d.ts +6 -1
- package/types/Reviews.d.ts +1 -1
- package/types/SetupAttempts.d.ts +1 -0
- package/types/SetupIntents.d.ts +2 -1
- package/types/SetupIntentsResource.d.ts +3 -3
- package/types/SourcesResource.d.ts +1 -1
- package/types/SubscriptionItems.d.ts +14 -0
- package/types/SubscriptionItemsResource.d.ts +28 -0
- package/types/SubscriptionSchedules.d.ts +47 -1
- package/types/SubscriptionSchedulesResource.d.ts +99 -3
- package/types/Subscriptions.d.ts +19 -2
- package/types/SubscriptionsResource.d.ts +76 -14
- package/types/Tax/CalculationLineItems.d.ts +5 -0
- package/types/Tax/CalculationsResource.d.ts +5 -0
- package/types/Tax/RegistrationsResource.d.ts +1 -1
- package/types/TaxRates.d.ts +2 -2
- package/types/Terminal/LocationsResource.d.ts +1 -1
- package/types/Terminal/Readers.d.ts +219 -1
- package/types/Terminal/ReadersResource.d.ts +144 -0
- package/types/TestHelpers/Terminal/ReadersResource.d.ts +53 -0
- package/types/Tokens.d.ts +3 -3
- package/types/TokensResource.d.ts +8 -8
- package/types/TransferReversals.d.ts +1 -1
- package/types/TransfersResource.d.ts +2 -2
- package/types/Treasury/ReceivedCredits.d.ts +2 -2
- package/types/WebhookEndpointsResource.d.ts +4 -1
- package/types/lib.d.ts +1 -1
- package/types/test/typescriptTest.ts +3 -3
|
@@ -755,7 +755,7 @@ declare module 'stripe' {
|
|
|
755
755
|
|
|
756
756
|
interface Networks {
|
|
757
757
|
/**
|
|
758
|
-
* All networks available for selection via [payment_method_options.card.network](https://stripe.com/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
|
|
758
|
+
* All networks available for selection via [payment_method_options.card.network](https://docs.stripe.com/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
|
|
759
759
|
*/
|
|
760
760
|
available: Array<string>;
|
|
761
761
|
|
|
@@ -955,7 +955,7 @@ declare module 'stripe' {
|
|
|
955
955
|
namespace CardPresent {
|
|
956
956
|
interface Networks {
|
|
957
957
|
/**
|
|
958
|
-
* All networks available for selection via [payment_method_options.card.network](https://stripe.com/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
|
|
958
|
+
* All networks available for selection via [payment_method_options.card.network](https://docs.stripe.com/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
|
|
959
959
|
*/
|
|
960
960
|
available: Array<string>;
|
|
961
961
|
|
|
@@ -1221,7 +1221,7 @@ declare module 'stripe' {
|
|
|
1221
1221
|
namespace InteracPresent {
|
|
1222
1222
|
interface Networks {
|
|
1223
1223
|
/**
|
|
1224
|
-
* All networks available for selection via [payment_method_options.card.network](https://stripe.com/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
|
|
1224
|
+
* All networks available for selection via [payment_method_options.card.network](https://docs.stripe.com/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
|
|
1225
1225
|
*/
|
|
1226
1226
|
available: Array<string>;
|
|
1227
1227
|
|
|
@@ -1328,7 +1328,7 @@ declare module 'stripe' {
|
|
|
1328
1328
|
/**
|
|
1329
1329
|
* Uniquely identifies this particular Naver Pay account. You can use this attribute to check whether two Naver Pay accounts are the same.
|
|
1330
1330
|
*/
|
|
1331
|
-
buyer_id
|
|
1331
|
+
buyer_id: string | null;
|
|
1332
1332
|
|
|
1333
1333
|
/**
|
|
1334
1334
|
* Whether to fund this transaction with Naver Pay points or a card.
|
package/types/CountrySpecs.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ declare module 'stripe' {
|
|
|
8
8
|
* Country Specs API makes these rules available to your integration.
|
|
9
9
|
*
|
|
10
10
|
* You can also view the information from this API call as [an online
|
|
11
|
-
* guide](https://stripe.com/docs/connect/required-verification-information).
|
|
11
|
+
* guide](https://docs.stripe.com/docs/connect/required-verification-information).
|
|
12
12
|
*/
|
|
13
13
|
interface CountrySpec {
|
|
14
14
|
/**
|
package/types/CreditNotes.d.ts
CHANGED
|
@@ -106,6 +106,16 @@ declare module 'stripe' {
|
|
|
106
106
|
*/
|
|
107
107
|
pdf: string;
|
|
108
108
|
|
|
109
|
+
/**
|
|
110
|
+
* The amount of the credit note that was refunded to the customer, credited to the customer's balance, credited outside of Stripe, or any combination thereof.
|
|
111
|
+
*/
|
|
112
|
+
post_payment_amount: number;
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* The amount of the credit note by which the invoice's `amount_remaining` and `amount_due` were reduced.
|
|
116
|
+
*/
|
|
117
|
+
pre_payment_amount: number;
|
|
118
|
+
|
|
109
119
|
/**
|
|
110
120
|
* The pretax credit amounts (ex: discount, credit grants, etc) for all line items.
|
|
111
121
|
*/
|
|
@@ -261,9 +271,9 @@ declare module 'stripe' {
|
|
|
261
271
|
amount: number;
|
|
262
272
|
|
|
263
273
|
/**
|
|
264
|
-
* Tax rates can be applied to [invoices](https://stripe.com/invoicing/taxes/tax-rates), [subscriptions](https://stripe.com/billing/taxes/tax-rates) and [Checkout Sessions](https://stripe.com/payments/checkout/use-manual-tax-rates) to collect tax.
|
|
274
|
+
* Tax rates can be applied to [invoices](https://docs.stripe.com/invoicing/taxes/tax-rates), [subscriptions](https://docs.stripe.com/billing/taxes/tax-rates) and [Checkout Sessions](https://docs.stripe.com/payments/checkout/use-manual-tax-rates) to collect tax.
|
|
265
275
|
*
|
|
266
|
-
* Related guide: [Tax rates](https://stripe.com/billing/taxes/tax-rates)
|
|
276
|
+
* Related guide: [Tax rates](https://docs.stripe.com/billing/taxes/tax-rates)
|
|
267
277
|
*/
|
|
268
278
|
rate: Stripe.TaxRate;
|
|
269
279
|
|
|
@@ -358,7 +368,7 @@ declare module 'stripe' {
|
|
|
358
368
|
}
|
|
359
369
|
}
|
|
360
370
|
|
|
361
|
-
type Type = 'post_payment' | 'pre_payment';
|
|
371
|
+
type Type = 'mixed' | 'post_payment' | 'pre_payment';
|
|
362
372
|
}
|
|
363
373
|
}
|
|
364
374
|
}
|
|
@@ -571,20 +571,19 @@ declare module 'stripe' {
|
|
|
571
571
|
|
|
572
572
|
class CreditNotesResource {
|
|
573
573
|
/**
|
|
574
|
-
* Issue a credit note to adjust the amount of a finalized invoice.
|
|
575
|
-
*
|
|
576
|
-
* in any combination of the following:
|
|
574
|
+
* Issue a credit note to adjust the amount of a finalized invoice. A credit note will first reduce the invoice's amount_remaining (and amount_due), but not below zero.
|
|
575
|
+
* This amount is indicated by the credit note's pre_payment_amount. The excess amount is indicated by post_payment_amount, and it can result in any combination of the following:
|
|
577
576
|
*
|
|
578
577
|
*
|
|
579
|
-
*
|
|
578
|
+
* Refunds: create a new refund (using refund_amount) or link existing refunds (using refunds).
|
|
580
579
|
* Customer balance credit: credit the customer's balance (using credit_amount) which will be automatically applied to their next invoice when it's finalized.
|
|
581
580
|
* Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
|
|
582
581
|
*
|
|
583
582
|
*
|
|
584
|
-
*
|
|
583
|
+
* The sum of refunds, customer balance credits, and outside of Stripe credits must equal the post_payment_amount.
|
|
585
584
|
*
|
|
586
|
-
* You may issue multiple credit notes for an invoice. Each credit note
|
|
587
|
-
* or
|
|
585
|
+
* You may issue multiple credit notes for an invoice. Each credit note may increment the invoice's pre_payment_credit_notes_amount,
|
|
586
|
+
* post_payment_credit_notes_amount, or both, depending on the invoice's amount_remaining at the time of credit note creation.
|
|
588
587
|
*/
|
|
589
588
|
create(
|
|
590
589
|
params: CreditNoteCreateParams,
|
|
@@ -652,7 +651,7 @@ declare module 'stripe' {
|
|
|
652
651
|
): Promise<Stripe.Response<Stripe.CreditNote>>;
|
|
653
652
|
|
|
654
653
|
/**
|
|
655
|
-
* Marks a credit note as void. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding).
|
|
654
|
+
* Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding).
|
|
656
655
|
*/
|
|
657
656
|
voidCreditNote(
|
|
658
657
|
id: string,
|
|
@@ -6,9 +6,9 @@ declare module 'stripe' {
|
|
|
6
6
|
* A Customer Session allows you to grant Stripe's frontend SDKs (like Stripe.js) client-side access
|
|
7
7
|
* control over a Customer.
|
|
8
8
|
*
|
|
9
|
-
* Related guides: [Customer Session with the Payment Element](https://stripe.com/payments/accept-a-payment-deferred?platform=web&type=payment#save-payment-methods),
|
|
10
|
-
* [Customer Session with the Pricing Table](https://stripe.com/payments/checkout/pricing-table#customer-session),
|
|
11
|
-
* [Customer Session with the Buy Button](https://stripe.com/payment-links/buy-button#pass-an-existing-customer).
|
|
9
|
+
* Related guides: [Customer Session with the Payment Element](https://docs.stripe.com/payments/accept-a-payment-deferred?platform=web&type=payment#save-payment-methods),
|
|
10
|
+
* [Customer Session with the Pricing Table](https://docs.stripe.com/payments/checkout/pricing-table#customer-session),
|
|
11
|
+
* [Customer Session with the Buy Button](https://docs.stripe.com/payment-links/buy-button#pass-an-existing-customer).
|
|
12
12
|
*/
|
|
13
13
|
interface CustomerSession {
|
|
14
14
|
/**
|
|
@@ -1201,7 +1201,7 @@ declare module 'stripe' {
|
|
|
1201
1201
|
): Promise<Stripe.Response<Stripe.DeletedCustomer>>;
|
|
1202
1202
|
|
|
1203
1203
|
/**
|
|
1204
|
-
* Creates an immutable transaction that updates the customer's credit [balance](https://stripe.com/docs/billing/customer/balance).
|
|
1204
|
+
* Creates an immutable transaction that updates the customer's credit [balance](https://docs.stripe.com/docs/billing/customer/balance).
|
|
1205
1205
|
*/
|
|
1206
1206
|
createBalanceTransaction(
|
|
1207
1207
|
id: string,
|
|
@@ -1225,7 +1225,7 @@ declare module 'stripe' {
|
|
|
1225
1225
|
*
|
|
1226
1226
|
* If the card's owner has no default card, then the new card will become the default.
|
|
1227
1227
|
* However, if the owner already has a default, then it will not change.
|
|
1228
|
-
* To change the default, you should [update the customer](https://stripe.com/docs/api#update_customer) to have a new default_source.
|
|
1228
|
+
* To change the default, you should [update the customer](https://docs.stripe.com/docs/api#update_customer) to have a new default_source.
|
|
1229
1229
|
*/
|
|
1230
1230
|
createSource(
|
|
1231
1231
|
id: string,
|
|
@@ -1290,7 +1290,7 @@ declare module 'stripe' {
|
|
|
1290
1290
|
): Promise<Stripe.Response<Stripe.DeletedTaxId>>;
|
|
1291
1291
|
|
|
1292
1292
|
/**
|
|
1293
|
-
* Returns a list of transactions that updated the customer's [balances](https://stripe.com/docs/billing/customer/balance).
|
|
1293
|
+
* Returns a list of transactions that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
|
|
1294
1294
|
*/
|
|
1295
1295
|
listBalanceTransactions(
|
|
1296
1296
|
id: string,
|
|
@@ -1303,7 +1303,7 @@ declare module 'stripe' {
|
|
|
1303
1303
|
): ApiListPromise<Stripe.CustomerBalanceTransaction>;
|
|
1304
1304
|
|
|
1305
1305
|
/**
|
|
1306
|
-
* Returns a list of transactions that modified the customer's [cash balance](https://stripe.com/docs/payments/customer-balance).
|
|
1306
|
+
* Returns a list of transactions that modified the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
|
|
1307
1307
|
*/
|
|
1308
1308
|
listCashBalanceTransactions(
|
|
1309
1309
|
id: string,
|
|
@@ -1355,7 +1355,7 @@ declare module 'stripe' {
|
|
|
1355
1355
|
): ApiListPromise<Stripe.TaxId>;
|
|
1356
1356
|
|
|
1357
1357
|
/**
|
|
1358
|
-
* Retrieves a specific customer balance transaction that updated the customer's [balances](https://stripe.com/docs/billing/customer/balance).
|
|
1358
|
+
* Retrieves a specific customer balance transaction that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
|
|
1359
1359
|
*/
|
|
1360
1360
|
retrieveBalanceTransaction(
|
|
1361
1361
|
customerId: string,
|
|
@@ -1383,7 +1383,7 @@ declare module 'stripe' {
|
|
|
1383
1383
|
): Promise<Stripe.Response<Stripe.CashBalance>>;
|
|
1384
1384
|
|
|
1385
1385
|
/**
|
|
1386
|
-
* Retrieves a specific cash balance transaction, which updated the customer's [cash balance](https://stripe.com/docs/payments/customer-balance).
|
|
1386
|
+
* Retrieves a specific cash balance transaction, which updated the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
|
|
1387
1387
|
*/
|
|
1388
1388
|
retrieveCashBalanceTransaction(
|
|
1389
1389
|
customerId: string,
|
|
@@ -1443,7 +1443,7 @@ declare module 'stripe' {
|
|
|
1443
1443
|
): Promise<Stripe.Response<Stripe.TaxId>>;
|
|
1444
1444
|
|
|
1445
1445
|
/**
|
|
1446
|
-
* Search for customers you've previously created using Stripe's [Search Query Language](https://stripe.com/docs/search#search-query-language).
|
|
1446
|
+
* Search for customers you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
|
|
1447
1447
|
* Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
|
|
1448
1448
|
* conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
|
|
1449
1449
|
* to an hour behind during outages. Search functionality is not available to merchants in India.
|
package/types/Disputes.d.ts
CHANGED
|
@@ -82,7 +82,7 @@ declare module 'stripe' {
|
|
|
82
82
|
payment_method_details?: Dispute.PaymentMethodDetails;
|
|
83
83
|
|
|
84
84
|
/**
|
|
85
|
-
* Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Learn more about [dispute reasons](https://stripe.com/docs/disputes/categories).
|
|
85
|
+
* Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `noncompliant`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Learn more about [dispute reasons](https://stripe.com/docs/disputes/categories).
|
|
86
86
|
*/
|
|
87
87
|
reason: string;
|
|
88
88
|
|
|
@@ -348,7 +348,7 @@ declare module 'stripe' {
|
|
|
348
348
|
/**
|
|
349
349
|
* When you get a dispute, contacting your customer is always the best first step. If that doesn't work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your [dashboard](https://dashboard.stripe.com/disputes), but if you prefer, you can use the API to submit evidence programmatically.
|
|
350
350
|
*
|
|
351
|
-
* Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our [guide to dispute types](https://stripe.com/docs/disputes/categories).
|
|
351
|
+
* Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our [guide to dispute types](https://docs.stripe.com/docs/disputes/categories).
|
|
352
352
|
*/
|
|
353
353
|
update(
|
|
354
354
|
id: string,
|
package/types/EventTypes.d.ts
CHANGED
|
@@ -109,6 +109,7 @@ declare module 'stripe' {
|
|
|
109
109
|
| InvoiceUpdatedEvent
|
|
110
110
|
| InvoiceVoidedEvent
|
|
111
111
|
| InvoiceWillBeDueEvent
|
|
112
|
+
| InvoicePaymentPaidEvent
|
|
112
113
|
| InvoiceItemCreatedEvent
|
|
113
114
|
| InvoiceItemDeletedEvent
|
|
114
115
|
| IssuingAuthorizationCreatedEvent
|
|
@@ -1955,6 +1956,22 @@ declare module 'stripe' {
|
|
|
1955
1956
|
}
|
|
1956
1957
|
}
|
|
1957
1958
|
|
|
1959
|
+
/**
|
|
1960
|
+
* Occurs when an InvoicePayment is successfully paid.
|
|
1961
|
+
*/
|
|
1962
|
+
interface InvoicePaymentPaidEvent extends EventBase {
|
|
1963
|
+
type: 'invoice_payment.paid';
|
|
1964
|
+
data: InvoicePaymentPaidEvent.Data;
|
|
1965
|
+
}
|
|
1966
|
+
|
|
1967
|
+
namespace InvoicePaymentPaidEvent {
|
|
1968
|
+
interface Data extends Stripe.Event.Data {
|
|
1969
|
+
object: Stripe.InvoicePayment;
|
|
1970
|
+
|
|
1971
|
+
previous_attributes?: Partial<Stripe.InvoicePayment>;
|
|
1972
|
+
}
|
|
1973
|
+
}
|
|
1974
|
+
|
|
1958
1975
|
/**
|
|
1959
1976
|
* Occurs whenever an invoice item is created.
|
|
1960
1977
|
*/
|
package/types/Events.d.ts
CHANGED
|
@@ -133,6 +133,7 @@ declare module 'stripe' {
|
|
|
133
133
|
| 'invoice.updated'
|
|
134
134
|
| 'invoice.voided'
|
|
135
135
|
| 'invoice.will_be_due'
|
|
136
|
+
| 'invoice_payment.paid'
|
|
136
137
|
| 'invoiceitem.created'
|
|
137
138
|
| 'invoiceitem.deleted'
|
|
138
139
|
| 'issuing_authorization.created'
|
|
@@ -336,6 +337,9 @@ declare module 'stripe' {
|
|
|
336
337
|
*/
|
|
337
338
|
api_version: string | null;
|
|
338
339
|
|
|
340
|
+
/**
|
|
341
|
+
* Authentication context needed to fetch the event or related object.
|
|
342
|
+
*/
|
|
339
343
|
context?: string;
|
|
340
344
|
|
|
341
345
|
/**
|
package/types/Files.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ declare module 'stripe' {
|
|
|
7
7
|
* files with the [create file](https://stripe.com/docs/api#create_file) request
|
|
8
8
|
* (for example, when uploading dispute evidence). Stripe also
|
|
9
9
|
* creates files independently (for example, the results of a [Sigma scheduled
|
|
10
|
-
* query](https://stripe.com/
|
|
10
|
+
* query](https://docs.stripe.com/api#scheduled_queries)).
|
|
11
11
|
*
|
|
12
12
|
* Related guide: [File upload guide](https://stripe.com/docs/file-upload)
|
|
13
13
|
*/
|
package/types/FilesResource.d.ts
CHANGED
|
@@ -113,7 +113,7 @@ declare module 'stripe' {
|
|
|
113
113
|
): Promise<Stripe.Response<Stripe.File>>;
|
|
114
114
|
|
|
115
115
|
/**
|
|
116
|
-
* Retrieves the details of an existing file object. After you supply a unique file ID, Stripe returns the corresponding file object. Learn how to [access file contents](https://stripe.com/docs/file-upload#download-file-contents).
|
|
116
|
+
* Retrieves the details of an existing file object. After you supply a unique file ID, Stripe returns the corresponding file object. Learn how to [access file contents](https://docs.stripe.com/docs/file-upload#download-file-contents).
|
|
117
117
|
*/
|
|
118
118
|
retrieve(
|
|
119
119
|
id: string,
|
|
@@ -137,6 +137,11 @@ declare module 'stripe' {
|
|
|
137
137
|
*/
|
|
138
138
|
number?: string | null;
|
|
139
139
|
|
|
140
|
+
/**
|
|
141
|
+
* Sex of the person in the document.
|
|
142
|
+
*/
|
|
143
|
+
sex?: Document.Sex | null;
|
|
144
|
+
|
|
140
145
|
/**
|
|
141
146
|
* Status of this `document` check.
|
|
142
147
|
*/
|
|
@@ -146,6 +151,16 @@ declare module 'stripe' {
|
|
|
146
151
|
* Type of the document.
|
|
147
152
|
*/
|
|
148
153
|
type: Document.Type | null;
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* Place of birth as it appears in the document.
|
|
157
|
+
*/
|
|
158
|
+
unparsed_place_of_birth?: string | null;
|
|
159
|
+
|
|
160
|
+
/**
|
|
161
|
+
* Sex as it appears in the document.
|
|
162
|
+
*/
|
|
163
|
+
unparsed_sex?: string | null;
|
|
149
164
|
}
|
|
150
165
|
|
|
151
166
|
namespace Document {
|
|
@@ -219,6 +234,8 @@ declare module 'stripe' {
|
|
|
219
234
|
year: number | null;
|
|
220
235
|
}
|
|
221
236
|
|
|
237
|
+
type Sex = '[redacted]' | 'female' | 'male' | 'unknown';
|
|
238
|
+
|
|
222
239
|
type Status = 'unverified' | 'verified';
|
|
223
240
|
|
|
224
241
|
type Type = 'driving_license' | 'id_card' | 'passport';
|
|
@@ -6,11 +6,11 @@ declare module 'stripe' {
|
|
|
6
6
|
/**
|
|
7
7
|
* A VerificationSession guides you through the process of collecting and verifying the identities
|
|
8
8
|
* of your users. It contains details about the type of verification, such as what [verification
|
|
9
|
-
* check](https://stripe.com/docs/identity/verification-checks) to perform. Only create one VerificationSession for
|
|
9
|
+
* check](https://docs.stripe.com/docs/identity/verification-checks) to perform. Only create one VerificationSession for
|
|
10
10
|
* each verification in your system.
|
|
11
11
|
*
|
|
12
12
|
* A VerificationSession transitions through [multiple
|
|
13
|
-
* statuses](https://stripe.com/docs/identity/how-sessions-work) throughout its lifetime as it progresses through
|
|
13
|
+
* statuses](https://docs.stripe.com/docs/identity/how-sessions-work) throughout its lifetime as it progresses through
|
|
14
14
|
* the verification flow. The VerificationSession contains the user's verified data after
|
|
15
15
|
* verification checks are complete.
|
|
16
16
|
*
|
|
@@ -268,6 +268,21 @@ declare module 'stripe' {
|
|
|
268
268
|
* The user's verified phone number
|
|
269
269
|
*/
|
|
270
270
|
phone: string | null;
|
|
271
|
+
|
|
272
|
+
/**
|
|
273
|
+
* The user's verified sex.
|
|
274
|
+
*/
|
|
275
|
+
sex?: VerifiedOutputs.Sex | null;
|
|
276
|
+
|
|
277
|
+
/**
|
|
278
|
+
* The user's verified place of birth as it appears in the document.
|
|
279
|
+
*/
|
|
280
|
+
unparsed_place_of_birth?: string | null;
|
|
281
|
+
|
|
282
|
+
/**
|
|
283
|
+
* The user's verified sex as it appears in the document.
|
|
284
|
+
*/
|
|
285
|
+
unparsed_sex?: string | null;
|
|
271
286
|
}
|
|
272
287
|
|
|
273
288
|
namespace VerifiedOutputs {
|
|
@@ -289,6 +304,8 @@ declare module 'stripe' {
|
|
|
289
304
|
}
|
|
290
305
|
|
|
291
306
|
type IdNumberType = 'br_cpf' | 'sg_nric' | 'us_ssn';
|
|
307
|
+
|
|
308
|
+
type Sex = '[redacted]' | 'female' | 'male' | 'unknown';
|
|
292
309
|
}
|
|
293
310
|
}
|
|
294
311
|
}
|
|
@@ -236,7 +236,7 @@ declare module 'stripe' {
|
|
|
236
236
|
*
|
|
237
237
|
* If your API key is in test mode, verification checks won't actually process, though everything else will occur as if in live mode.
|
|
238
238
|
*
|
|
239
|
-
* Related guide: [Verify your users' identity documents](https://stripe.com/docs/identity/verify-identity-documents)
|
|
239
|
+
* Related guide: [Verify your users' identity documents](https://docs.stripe.com/docs/identity/verify-identity-documents)
|
|
240
240
|
*/
|
|
241
241
|
create(
|
|
242
242
|
params?: VerificationSessionCreateParams,
|
|
@@ -286,9 +286,9 @@ declare module 'stripe' {
|
|
|
286
286
|
): ApiListPromise<Stripe.Identity.VerificationSession>;
|
|
287
287
|
|
|
288
288
|
/**
|
|
289
|
-
* A VerificationSession object can be canceled when it is in requires_input [status](https://stripe.com/docs/identity/how-sessions-work).
|
|
289
|
+
* A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work).
|
|
290
290
|
*
|
|
291
|
-
* Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://stripe.com/docs/identity/verification-sessions#cancel).
|
|
291
|
+
* Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#cancel).
|
|
292
292
|
*/
|
|
293
293
|
cancel(
|
|
294
294
|
id: string,
|
|
@@ -306,7 +306,7 @@ declare module 'stripe' {
|
|
|
306
306
|
* request logs, etc.
|
|
307
307
|
*
|
|
308
308
|
* A VerificationSession object can be redacted when it is in requires_input or verified
|
|
309
|
-
* [status](https://stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action
|
|
309
|
+
* [status](https://docs.stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action
|
|
310
310
|
* state will automatically cancel it.
|
|
311
311
|
*
|
|
312
312
|
* The redaction process may take up to four days. When the redaction process is in progress, the
|
|
@@ -319,7 +319,7 @@ declare module 'stripe' {
|
|
|
319
319
|
* placeholder. The metadata field will also be erased. Redacted objects cannot be updated or
|
|
320
320
|
* used for any purpose.
|
|
321
321
|
*
|
|
322
|
-
* [Learn more](https://stripe.com/docs/identity/verification-sessions#redact).
|
|
322
|
+
* [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#redact).
|
|
323
323
|
*/
|
|
324
324
|
redact(
|
|
325
325
|
id: string,
|
package/types/InvoiceItems.d.ts
CHANGED
|
@@ -3,7 +3,14 @@
|
|
|
3
3
|
declare module 'stripe' {
|
|
4
4
|
namespace Stripe {
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
6
|
+
* Invoice Payments represent payments made against invoices. Invoice Payments can
|
|
7
|
+
* be accessed in two ways:
|
|
8
|
+
* 1. By expanding the `payments` field on the [Invoice](https://stripe.com/docs/api#invoice) resource.
|
|
9
|
+
* 2. By using the Invoice Payment retrieve and list endpoints.
|
|
10
|
+
*
|
|
11
|
+
* Invoice Payments include the mapping between payment objects, such as Payment Intent, and Invoices.
|
|
12
|
+
* This resource and its endpoints allows you to easily track if a payment is associated with a specific invoice and
|
|
13
|
+
* monitor the allocation details of the payments.
|
|
7
14
|
*/
|
|
8
15
|
interface InvoicePayment {
|
|
9
16
|
/**
|
|
@@ -64,7 +71,7 @@ declare module 'stripe' {
|
|
|
64
71
|
namespace InvoicePayment {
|
|
65
72
|
interface Payment {
|
|
66
73
|
/**
|
|
67
|
-
* ID of the successful charge for this payment when `type` is `charge`.
|
|
74
|
+
* ID of the successful charge for this payment when `type` is `charge`.Note: charge is only surfaced if the charge object is not associated with a payment intent. If the charge object does have a payment intent, the Invoice Payment surfaces the payment intent instead.
|
|
68
75
|
*/
|
|
69
76
|
charge?: string | Stripe.Charge;
|
|
70
77
|
|
package/types/Invoices.d.ts
CHANGED
|
@@ -47,7 +47,7 @@ declare module 'stripe' {
|
|
|
47
47
|
* Stripe applies any customer credit on the account before determining the
|
|
48
48
|
* amount due for the invoice (i.e., the amount that will be actually
|
|
49
49
|
* charged). If the amount due for the invoice is less than Stripe's [minimum allowed charge
|
|
50
|
-
* per currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts), the
|
|
50
|
+
* per currency](https://docs.stripe.com/docs/currencies#minimum-and-maximum-charge-amounts), the
|
|
51
51
|
* invoice is automatically marked paid, and we add the amount due to the
|
|
52
52
|
* customer's credit balance which is applied to the next invoice.
|
|
53
53
|
*
|
|
@@ -58,7 +58,7 @@ declare module 'stripe' {
|
|
|
58
58
|
*/
|
|
59
59
|
interface Invoice {
|
|
60
60
|
/**
|
|
61
|
-
* Unique identifier for the object.
|
|
61
|
+
* Unique identifier for the object. For preview invoices created using the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint, this id will be prefixed with `upcoming_in`.
|
|
62
62
|
*/
|
|
63
63
|
id?: string;
|
|
64
64
|
|
|
@@ -338,12 +338,12 @@ declare module 'stripe' {
|
|
|
338
338
|
payments?: ApiList<Stripe.InvoicePayment>;
|
|
339
339
|
|
|
340
340
|
/**
|
|
341
|
-
* 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.
|
|
341
|
+
* 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://docs.stripe.com/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
|
|
342
342
|
*/
|
|
343
343
|
period_end: number;
|
|
344
344
|
|
|
345
345
|
/**
|
|
346
|
-
* Start 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.
|
|
346
|
+
* Start 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://docs.stripe.com/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
|
|
347
347
|
*/
|
|
348
348
|
period_start: number;
|
|
349
349
|
|
|
@@ -883,6 +883,7 @@ declare module 'stripe' {
|
|
|
883
883
|
| 'forwarding_api_retryable_upstream_error'
|
|
884
884
|
| 'forwarding_api_upstream_connection_error'
|
|
885
885
|
| 'forwarding_api_upstream_connection_timeout'
|
|
886
|
+
| 'forwarding_api_upstream_error'
|
|
886
887
|
| 'idempotency_key_in_use'
|
|
887
888
|
| 'incorrect_address'
|
|
888
889
|
| 'incorrect_cvc'
|
|
@@ -1366,9 +1367,9 @@ declare module 'stripe' {
|
|
|
1366
1367
|
amount: number;
|
|
1367
1368
|
|
|
1368
1369
|
/**
|
|
1369
|
-
* Tax rates can be applied to [invoices](https://stripe.com/invoicing/taxes/tax-rates), [subscriptions](https://stripe.com/billing/taxes/tax-rates) and [Checkout Sessions](https://stripe.com/payments/checkout/use-manual-tax-rates) to collect tax.
|
|
1370
|
+
* Tax rates can be applied to [invoices](https://docs.stripe.com/invoicing/taxes/tax-rates), [subscriptions](https://docs.stripe.com/billing/taxes/tax-rates) and [Checkout Sessions](https://docs.stripe.com/payments/checkout/use-manual-tax-rates) to collect tax.
|
|
1370
1371
|
*
|
|
1371
|
-
* Related guide: [Tax rates](https://stripe.com/billing/taxes/tax-rates)
|
|
1372
|
+
* Related guide: [Tax rates](https://docs.stripe.com/billing/taxes/tax-rates)
|
|
1372
1373
|
*/
|
|
1373
1374
|
rate: Stripe.TaxRate;
|
|
1374
1375
|
|