stripe 10.12.0 → 10.13.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 +14 -4
- package/VERSION +1 -1
- package/package.json +16 -17
- package/types/.eslintrc.js +4 -0
- package/types/2022-08-01/Accounts.d.ts +2 -0
- package/types/2022-08-01/Capabilities.d.ts +2 -0
- package/types/2022-08-01/Charges.d.ts +2 -1
- package/types/2022-08-01/Customers.d.ts +2 -2
- package/types/2022-08-01/Invoices.d.ts +1 -1
- package/types/2022-08-01/PaymentIntents.d.ts +3 -0
- package/types/2022-08-01/PaymentMethods.d.ts +3 -1
- package/types/2022-08-01/Persons.d.ts +2 -0
- package/types/2022-08-01/Quotes.d.ts +3 -3
- package/types/2022-08-01/Reporting/ReportRuns.d.ts +3 -0
- package/types/2022-08-01/SetupAttempts.d.ts +4 -0
- package/types/2022-08-01/SetupIntents.d.ts +3 -0
- package/types/2022-08-01/SubscriptionSchedules.d.ts +6 -6
- package/types/2022-08-01/Subscriptions.d.ts +7 -3
- package/types/2022-08-01/Treasury/FinancialAccountFeatures.d.ts +3 -3
- package/types/Webhooks.d.ts +0 -8
- package/types/test/.eslintrc.js +6 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,11 +1,21 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 10.13.0 - 2022-10-06
|
|
4
|
+
* [#1571](https://github.com/stripe/stripe-node/pull/1571) API Updates
|
|
5
|
+
* Add support for new value `invalid_dob_age_under_18` on enums `Account.future_requirements.errors[].code`, `Account.requirements.errors[].code`, `Capability.future_requirements.errors[].code`, `Capability.requirements.errors[].code`, `Person.future_requirements.errors[].code`, and `Person.requirements.errors[].code`
|
|
6
|
+
* Add support for new value `bank_of_china` on enums `Charge.payment_method_details.fpx.bank`, `PaymentIntentConfirmParams.payment_method_data.fpx.bank`, `PaymentIntentCreateParams.payment_method_data.fpx.bank`, `PaymentIntentUpdateParams.payment_method_data.fpx.bank`, `PaymentMethod.fpx.bank`, `PaymentMethodCreateParams.fpx.bank`, `SetupIntentConfirmParams.payment_method_data.fpx.bank`, `SetupIntentCreateParams.payment_method_data.fpx.bank`, and `SetupIntentUpdateParams.payment_method_data.fpx.bank`
|
|
7
|
+
* Add support for new values `America/Nuuk`, `Europe/Kyiv`, and `Pacific/Kanton` on enum `ReportingReportRunCreateParams.parameters.timezone`
|
|
8
|
+
* Add support for `klarna` on `SetupAttempt.payment_method_details`
|
|
9
|
+
* [#1570](https://github.com/stripe/stripe-node/pull/1570) Update node-fetch to 2.6.7
|
|
10
|
+
* [#1568](https://github.com/stripe/stripe-node/pull/1568) Upgrade dependencies
|
|
11
|
+
* [#1567](https://github.com/stripe/stripe-node/pull/1567) Fix release tag calculation
|
|
12
|
+
|
|
3
13
|
## 10.12.0 - 2022-09-29
|
|
4
14
|
* [#1564](https://github.com/stripe/stripe-node/pull/1564) API Updates
|
|
5
|
-
* Change type of `Charge.payment_method_details.card_present.incremental_authorization_supported` and `Charge.payment_method_details.card_present.overcapture_supported` from `boolean | null` to `boolean`
|
|
6
|
-
* Add support for `created` on `Checkout.Session`
|
|
7
|
-
* Add support for `setup_future_usage` on `PaymentIntent.payment_method_options.pix`, `PaymentIntentConfirmParams.payment_method_options.pix`, `PaymentIntentCreateParams.payment_method_options.pix`, and `PaymentIntentUpdateParams.payment_method_options.pix`
|
|
8
|
-
* Deprecate `CheckoutSessionCreateParams.subscription_data.items` (use the `line_items` param instead). This will be removed in the next major version.
|
|
15
|
+
* Change type of `Charge.payment_method_details.card_present.incremental_authorization_supported` and `Charge.payment_method_details.card_present.overcapture_supported` from `boolean | null` to `boolean`
|
|
16
|
+
* Add support for `created` on `Checkout.Session`
|
|
17
|
+
* Add support for `setup_future_usage` on `PaymentIntent.payment_method_options.pix`, `PaymentIntentConfirmParams.payment_method_options.pix`, `PaymentIntentCreateParams.payment_method_options.pix`, and `PaymentIntentUpdateParams.payment_method_options.pix`
|
|
18
|
+
* Deprecate `CheckoutSessionCreateParams.subscription_data.items` (use the `line_items` param instead). This will be removed in the next major version.
|
|
9
19
|
* [#1563](https://github.com/stripe/stripe-node/pull/1563) Migrate other Stripe infrastructure to TS
|
|
10
20
|
* [#1562](https://github.com/stripe/stripe-node/pull/1562) Restore lib after generating
|
|
11
21
|
* [#1551](https://github.com/stripe/stripe-node/pull/1551) Re-introduce Typescript changes
|
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
10.
|
|
1
|
+
10.13.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "stripe",
|
|
3
|
-
"version": "10.
|
|
3
|
+
"version": "10.13.0",
|
|
4
4
|
"description": "Stripe API wrapper",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"stripe",
|
|
@@ -27,31 +27,30 @@
|
|
|
27
27
|
"main": "lib/stripe.js",
|
|
28
28
|
"types": "types/2022-08-01/index.d.ts",
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
31
|
-
"@typescript-eslint/parser": "^
|
|
32
|
-
"chai": "
|
|
30
|
+
"@typescript-eslint/eslint-plugin": "^4.33.0",
|
|
31
|
+
"@typescript-eslint/parser": "^4.33.0",
|
|
32
|
+
"chai": "^4.3.6",
|
|
33
33
|
"chai-as-promised": "~7.1.1",
|
|
34
34
|
"coveralls": "^3.1.1",
|
|
35
|
-
"eslint": "^
|
|
36
|
-
"eslint-config-prettier": "^
|
|
37
|
-
"eslint-plugin-chai-friendly": "^0.
|
|
38
|
-
"eslint-plugin-prettier": "^3.
|
|
39
|
-
"mocha": "^8.
|
|
40
|
-
"mocha-junit-reporter": "^1.
|
|
41
|
-
"nock": "^13.
|
|
42
|
-
"node-fetch": "^2.6.
|
|
35
|
+
"eslint": "^7.32.0",
|
|
36
|
+
"eslint-config-prettier": "^8.5.0",
|
|
37
|
+
"eslint-plugin-chai-friendly": "^0.7.2",
|
|
38
|
+
"eslint-plugin-prettier": "^3.4.1",
|
|
39
|
+
"mocha": "^8.4.0",
|
|
40
|
+
"mocha-junit-reporter": "^2.1.0",
|
|
41
|
+
"nock": "^13.2.9",
|
|
42
|
+
"node-fetch": "^2.6.7",
|
|
43
43
|
"nyc": "^15.1.0",
|
|
44
44
|
"prettier": "^1.16.4",
|
|
45
|
-
"typescript": "^4.8.
|
|
45
|
+
"typescript": "^4.8.4"
|
|
46
46
|
},
|
|
47
47
|
"resolutions": {
|
|
48
|
-
"ansi-regex": "5.0.1",
|
|
49
48
|
"minimist": "1.2.6",
|
|
50
|
-
"nanoid": "3.2.0"
|
|
49
|
+
"nanoid": "^3.2.0"
|
|
51
50
|
},
|
|
52
51
|
"dependencies": {
|
|
53
52
|
"@types/node": ">=8.1.0",
|
|
54
|
-
"qs": "^6.
|
|
53
|
+
"qs": "^6.11.0"
|
|
55
54
|
},
|
|
56
55
|
"license": "MIT",
|
|
57
56
|
"scripts": {
|
|
@@ -68,5 +67,5 @@
|
|
|
68
67
|
"report": "nyc -r text -r lcov report",
|
|
69
68
|
"coveralls": "cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",
|
|
70
69
|
"prettier-format": "prettier --config .prettierrc 'lib/**/*.js' --write"
|
|
71
|
-
}
|
|
70
|
+
}
|
|
72
71
|
}
|
package/types/.eslintrc.js
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
module.exports = {
|
|
2
2
|
root: true,
|
|
3
|
+
env: {
|
|
4
|
+
node: true,
|
|
5
|
+
},
|
|
3
6
|
parser: '@typescript-eslint/parser',
|
|
4
7
|
plugins: ['@typescript-eslint', 'prettier'],
|
|
5
8
|
extends: [
|
|
@@ -14,5 +17,6 @@ module.exports = {
|
|
|
14
17
|
'@typescript-eslint/no-unused-vars': 0,
|
|
15
18
|
'@typescript-eslint/triple-slash-reference': 0,
|
|
16
19
|
'@typescript-eslint/ban-ts-ignore': 0,
|
|
20
|
+
'@typescript-eslint/ban-types': 0,
|
|
17
21
|
},
|
|
18
22
|
};
|
|
@@ -708,6 +708,7 @@ declare module 'stripe' {
|
|
|
708
708
|
namespace Error {
|
|
709
709
|
type Code =
|
|
710
710
|
| 'invalid_address_city_state_postal_code'
|
|
711
|
+
| 'invalid_dob_age_under_18'
|
|
711
712
|
| 'invalid_street_address'
|
|
712
713
|
| 'invalid_tos_acceptance'
|
|
713
714
|
| 'invalid_value_other'
|
|
@@ -831,6 +832,7 @@ declare module 'stripe' {
|
|
|
831
832
|
namespace Error {
|
|
832
833
|
type Code =
|
|
833
834
|
| 'invalid_address_city_state_postal_code'
|
|
835
|
+
| 'invalid_dob_age_under_18'
|
|
834
836
|
| 'invalid_street_address'
|
|
835
837
|
| 'invalid_tos_acceptance'
|
|
836
838
|
| 'invalid_value_other'
|
|
@@ -119,6 +119,7 @@ declare module 'stripe' {
|
|
|
119
119
|
namespace Error {
|
|
120
120
|
type Code =
|
|
121
121
|
| 'invalid_address_city_state_postal_code'
|
|
122
|
+
| 'invalid_dob_age_under_18'
|
|
122
123
|
| 'invalid_street_address'
|
|
123
124
|
| 'invalid_tos_acceptance'
|
|
124
125
|
| 'invalid_value_other'
|
|
@@ -248,6 +249,7 @@ declare module 'stripe' {
|
|
|
248
249
|
namespace Error {
|
|
249
250
|
type Code =
|
|
250
251
|
| 'invalid_address_city_state_postal_code'
|
|
252
|
+
| 'invalid_dob_age_under_18'
|
|
251
253
|
| 'invalid_street_address'
|
|
252
254
|
| 'invalid_tos_acceptance'
|
|
253
255
|
| 'invalid_value_other'
|
|
@@ -1178,7 +1178,7 @@ declare module 'stripe' {
|
|
|
1178
1178
|
account_holder_type: Fpx.AccountHolderType | null;
|
|
1179
1179
|
|
|
1180
1180
|
/**
|
|
1181
|
-
* The customer's bank. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `
|
|
1181
|
+
* The customer's bank. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
|
|
1182
1182
|
*/
|
|
1183
1183
|
bank: Fpx.Bank;
|
|
1184
1184
|
|
|
@@ -1198,6 +1198,7 @@ declare module 'stripe' {
|
|
|
1198
1198
|
| 'ambank'
|
|
1199
1199
|
| 'bank_islam'
|
|
1200
1200
|
| 'bank_muamalat'
|
|
1201
|
+
| 'bank_of_china'
|
|
1201
1202
|
| 'bank_rakyat'
|
|
1202
1203
|
| 'bsn'
|
|
1203
1204
|
| 'cimb'
|
|
@@ -29,7 +29,7 @@ declare module 'stripe' {
|
|
|
29
29
|
balance: number;
|
|
30
30
|
|
|
31
31
|
/**
|
|
32
|
-
* The current funds being held by Stripe on behalf of the customer. These funds can be applied towards payment intents with source "cash_balance".The settings[reconciliation_mode] field describes whether these funds are applied to such payment intents manually or automatically.
|
|
32
|
+
* The current funds being held by Stripe on behalf of the customer. These funds can be applied towards payment intents with source "cash_balance". The settings[reconciliation_mode] field describes whether these funds are applied to such payment intents manually or automatically.
|
|
33
33
|
*/
|
|
34
34
|
cash_balance?: Stripe.CashBalance | null;
|
|
35
35
|
|
|
@@ -75,7 +75,7 @@ declare module 'stripe' {
|
|
|
75
75
|
email: string | null;
|
|
76
76
|
|
|
77
77
|
/**
|
|
78
|
-
* The current multi-currency balances, if any, being stored on the customer.If positive in a currency, the customer has a credit to apply to their next invoice denominated in that currency.If negative, the customer has an amount owed that will be added to their next invoice denominated in that currency. These balances do not refer to any unpaid invoices.They solely track amounts that have yet to be successfully applied to any invoice. A balance in a particular currency is only applied to any invoice as an invoice in that currency is finalized.
|
|
78
|
+
* The current multi-currency balances, if any, being stored on the customer. If positive in a currency, the customer has a credit to apply to their next invoice denominated in that currency. If negative, the customer has an amount owed that will be added to their next invoice denominated in that currency. These balances do not refer to any unpaid invoices. They solely track amounts that have yet to be successfully applied to any invoice. A balance in a particular currency is only applied to any invoice as an invoice in that currency is finalized.
|
|
79
79
|
*/
|
|
80
80
|
invoice_credit_balance?: {
|
|
81
81
|
[key: string]: number;
|
|
@@ -337,7 +337,7 @@ declare module 'stripe' {
|
|
|
337
337
|
rendering_options: Invoice.RenderingOptions | null;
|
|
338
338
|
|
|
339
339
|
/**
|
|
340
|
-
* Starting customer balance before the invoice is finalized. If the invoice has not been finalized yet, this will be the current customer balance.
|
|
340
|
+
* Starting customer balance before the invoice is finalized. If the invoice has not been finalized yet, this will be the current customer balance. For revision invoices, this also includes any customer balance that was applied to the original invoice.
|
|
341
341
|
*/
|
|
342
342
|
starting_balance: number;
|
|
343
343
|
|
|
@@ -2328,6 +2328,7 @@ declare module 'stripe' {
|
|
|
2328
2328
|
| 'ambank'
|
|
2329
2329
|
| 'bank_islam'
|
|
2330
2330
|
| 'bank_muamalat'
|
|
2331
|
+
| 'bank_of_china'
|
|
2331
2332
|
| 'bank_rakyat'
|
|
2332
2333
|
| 'bsn'
|
|
2333
2334
|
| 'cimb'
|
|
@@ -4085,6 +4086,7 @@ declare module 'stripe' {
|
|
|
4085
4086
|
| 'ambank'
|
|
4086
4087
|
| 'bank_islam'
|
|
4087
4088
|
| 'bank_muamalat'
|
|
4089
|
+
| 'bank_of_china'
|
|
4088
4090
|
| 'bank_rakyat'
|
|
4089
4091
|
| 'bsn'
|
|
4090
4092
|
| 'cimb'
|
|
@@ -5977,6 +5979,7 @@ declare module 'stripe' {
|
|
|
5977
5979
|
| 'ambank'
|
|
5978
5980
|
| 'bank_islam'
|
|
5979
5981
|
| 'bank_muamalat'
|
|
5982
|
+
| 'bank_of_china'
|
|
5980
5983
|
| 'bank_rakyat'
|
|
5981
5984
|
| 'bsn'
|
|
5982
5985
|
| 'cimb'
|
|
@@ -462,7 +462,7 @@ declare module 'stripe' {
|
|
|
462
462
|
account_holder_type: Fpx.AccountHolderType | null;
|
|
463
463
|
|
|
464
464
|
/**
|
|
465
|
-
* The customer's bank, if provided. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, or `
|
|
465
|
+
* The customer's bank, if provided. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
|
|
466
466
|
*/
|
|
467
467
|
bank: Fpx.Bank;
|
|
468
468
|
}
|
|
@@ -477,6 +477,7 @@ declare module 'stripe' {
|
|
|
477
477
|
| 'ambank'
|
|
478
478
|
| 'bank_islam'
|
|
479
479
|
| 'bank_muamalat'
|
|
480
|
+
| 'bank_of_china'
|
|
480
481
|
| 'bank_rakyat'
|
|
481
482
|
| 'bsn'
|
|
482
483
|
| 'cimb'
|
|
@@ -1139,6 +1140,7 @@ declare module 'stripe' {
|
|
|
1139
1140
|
| 'ambank'
|
|
1140
1141
|
| 'bank_islam'
|
|
1141
1142
|
| 'bank_muamalat'
|
|
1143
|
+
| 'bank_of_china'
|
|
1142
1144
|
| 'bank_rakyat'
|
|
1143
1145
|
| 'bsn'
|
|
1144
1146
|
| 'cimb'
|
|
@@ -306,6 +306,7 @@ declare module 'stripe' {
|
|
|
306
306
|
namespace Error {
|
|
307
307
|
type Code =
|
|
308
308
|
| 'invalid_address_city_state_postal_code'
|
|
309
|
+
| 'invalid_dob_age_under_18'
|
|
309
310
|
| 'invalid_street_address'
|
|
310
311
|
| 'invalid_tos_acceptance'
|
|
311
312
|
| 'invalid_value_other'
|
|
@@ -453,6 +454,7 @@ declare module 'stripe' {
|
|
|
453
454
|
namespace Error {
|
|
454
455
|
type Code =
|
|
455
456
|
| 'invalid_address_city_state_postal_code'
|
|
457
|
+
| 'invalid_dob_age_under_18'
|
|
456
458
|
| 'invalid_street_address'
|
|
457
459
|
| 'invalid_tos_acceptance'
|
|
458
460
|
| 'invalid_value_other'
|
|
@@ -49,7 +49,7 @@ declare module 'stripe' {
|
|
|
49
49
|
automatic_tax: Quote.AutomaticTax;
|
|
50
50
|
|
|
51
51
|
/**
|
|
52
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or on finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
52
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or on finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
|
53
53
|
*/
|
|
54
54
|
collection_method: Quote.CollectionMethod;
|
|
55
55
|
|
|
@@ -533,7 +533,7 @@ declare module 'stripe' {
|
|
|
533
533
|
automatic_tax?: QuoteCreateParams.AutomaticTax;
|
|
534
534
|
|
|
535
535
|
/**
|
|
536
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
536
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
|
537
537
|
*/
|
|
538
538
|
collection_method?: QuoteCreateParams.CollectionMethod;
|
|
539
539
|
|
|
@@ -794,7 +794,7 @@ declare module 'stripe' {
|
|
|
794
794
|
automatic_tax?: QuoteUpdateParams.AutomaticTax;
|
|
795
795
|
|
|
796
796
|
/**
|
|
797
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
797
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
|
798
798
|
*/
|
|
799
799
|
collection_method?: QuoteUpdateParams.CollectionMethod;
|
|
800
800
|
|
|
@@ -384,6 +384,7 @@ declare module 'stripe' {
|
|
|
384
384
|
| 'America/North_Dakota/Beulah'
|
|
385
385
|
| 'America/North_Dakota/Center'
|
|
386
386
|
| 'America/North_Dakota/New_Salem'
|
|
387
|
+
| 'America/Nuuk'
|
|
387
388
|
| 'America/Ojinaga'
|
|
388
389
|
| 'America/Panama'
|
|
389
390
|
| 'America/Pangnirtung'
|
|
@@ -657,6 +658,7 @@ declare module 'stripe' {
|
|
|
657
658
|
| 'Europe/Kaliningrad'
|
|
658
659
|
| 'Europe/Kiev'
|
|
659
660
|
| 'Europe/Kirov'
|
|
661
|
+
| 'Europe/Kyiv'
|
|
660
662
|
| 'Europe/Lisbon'
|
|
661
663
|
| 'Europe/Ljubljana'
|
|
662
664
|
| 'Europe/London'
|
|
@@ -752,6 +754,7 @@ declare module 'stripe' {
|
|
|
752
754
|
| 'Pacific/Guam'
|
|
753
755
|
| 'Pacific/Honolulu'
|
|
754
756
|
| 'Pacific/Johnston'
|
|
757
|
+
| 'Pacific/Kanton'
|
|
755
758
|
| 'Pacific/Kiritimati'
|
|
756
759
|
| 'Pacific/Kosrae'
|
|
757
760
|
| 'Pacific/Kwajalein'
|
|
@@ -108,6 +108,8 @@ declare module 'stripe' {
|
|
|
108
108
|
|
|
109
109
|
ideal?: PaymentMethodDetails.Ideal;
|
|
110
110
|
|
|
111
|
+
klarna?: PaymentMethodDetails.Klarna;
|
|
112
|
+
|
|
111
113
|
link?: PaymentMethodDetails.Link;
|
|
112
114
|
|
|
113
115
|
sepa_debit?: PaymentMethodDetails.SepaDebit;
|
|
@@ -309,6 +311,8 @@ declare module 'stripe' {
|
|
|
309
311
|
| 'TRIONL2U';
|
|
310
312
|
}
|
|
311
313
|
|
|
314
|
+
interface Klarna {}
|
|
315
|
+
|
|
312
316
|
interface Link {}
|
|
313
317
|
|
|
314
318
|
interface SepaDebit {}
|
|
@@ -1032,6 +1032,7 @@ declare module 'stripe' {
|
|
|
1032
1032
|
| 'ambank'
|
|
1033
1033
|
| 'bank_islam'
|
|
1034
1034
|
| 'bank_muamalat'
|
|
1035
|
+
| 'bank_of_china'
|
|
1035
1036
|
| 'bank_rakyat'
|
|
1036
1037
|
| 'bsn'
|
|
1037
1038
|
| 'cimb'
|
|
@@ -1907,6 +1908,7 @@ declare module 'stripe' {
|
|
|
1907
1908
|
| 'ambank'
|
|
1908
1909
|
| 'bank_islam'
|
|
1909
1910
|
| 'bank_muamalat'
|
|
1911
|
+
| 'bank_of_china'
|
|
1910
1912
|
| 'bank_rakyat'
|
|
1911
1913
|
| 'bsn'
|
|
1912
1914
|
| 'cimb'
|
|
@@ -2864,6 +2866,7 @@ declare module 'stripe' {
|
|
|
2864
2866
|
| 'ambank'
|
|
2865
2867
|
| 'bank_islam'
|
|
2866
2868
|
| 'bank_muamalat'
|
|
2869
|
+
| 'bank_of_china'
|
|
2867
2870
|
| 'bank_rakyat'
|
|
2868
2871
|
| 'bsn'
|
|
2869
2872
|
| 'cimb'
|
|
@@ -132,7 +132,7 @@ declare module 'stripe' {
|
|
|
132
132
|
billing_thresholds: DefaultSettings.BillingThresholds | null;
|
|
133
133
|
|
|
134
134
|
/**
|
|
135
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
135
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
|
|
136
136
|
*/
|
|
137
137
|
collection_method: DefaultSettings.CollectionMethod | null;
|
|
138
138
|
|
|
@@ -227,7 +227,7 @@ declare module 'stripe' {
|
|
|
227
227
|
billing_thresholds: Phase.BillingThresholds | null;
|
|
228
228
|
|
|
229
229
|
/**
|
|
230
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
230
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
|
|
231
231
|
*/
|
|
232
232
|
collection_method: Phase.CollectionMethod | null;
|
|
233
233
|
|
|
@@ -474,7 +474,7 @@ declare module 'stripe' {
|
|
|
474
474
|
>;
|
|
475
475
|
|
|
476
476
|
/**
|
|
477
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
477
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
|
|
478
478
|
*/
|
|
479
479
|
collection_method?: DefaultSettings.CollectionMethod;
|
|
480
480
|
|
|
@@ -572,7 +572,7 @@ declare module 'stripe' {
|
|
|
572
572
|
billing_thresholds?: Stripe.Emptyable<Phase.BillingThresholds>;
|
|
573
573
|
|
|
574
574
|
/**
|
|
575
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
575
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
|
|
576
576
|
*/
|
|
577
577
|
collection_method?: Phase.CollectionMethod;
|
|
578
578
|
|
|
@@ -909,7 +909,7 @@ declare module 'stripe' {
|
|
|
909
909
|
>;
|
|
910
910
|
|
|
911
911
|
/**
|
|
912
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
912
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
|
|
913
913
|
*/
|
|
914
914
|
collection_method?: DefaultSettings.CollectionMethod;
|
|
915
915
|
|
|
@@ -1007,7 +1007,7 @@ declare module 'stripe' {
|
|
|
1007
1007
|
billing_thresholds?: Stripe.Emptyable<Phase.BillingThresholds>;
|
|
1008
1008
|
|
|
1009
1009
|
/**
|
|
1010
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
1010
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
|
|
1011
1011
|
*/
|
|
1012
1012
|
collection_method?: Phase.CollectionMethod;
|
|
1013
1013
|
|
|
@@ -60,7 +60,7 @@ declare module 'stripe' {
|
|
|
60
60
|
canceled_at: number | null;
|
|
61
61
|
|
|
62
62
|
/**
|
|
63
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
63
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
|
|
64
64
|
*/
|
|
65
65
|
collection_method: Subscription.CollectionMethod;
|
|
66
66
|
|
|
@@ -594,7 +594,7 @@ declare module 'stripe' {
|
|
|
594
594
|
cancel_at_period_end?: boolean;
|
|
595
595
|
|
|
596
596
|
/**
|
|
597
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
597
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
|
598
598
|
*/
|
|
599
599
|
collection_method?: SubscriptionCreateParams.CollectionMethod;
|
|
600
600
|
|
|
@@ -654,6 +654,8 @@ declare module 'stripe' {
|
|
|
654
654
|
off_session?: boolean;
|
|
655
655
|
|
|
656
656
|
/**
|
|
657
|
+
* Only applies to subscriptions with `collection_method=charge_automatically`.
|
|
658
|
+
*
|
|
657
659
|
* Use `allow_incomplete` to create subscriptions with `status=incomplete` if the first invoice cannot be paid. Creating subscriptions with this status allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
|
|
658
660
|
*
|
|
659
661
|
* Use `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the payment intent on the first invoice. This allows simpler management of scenarios where additional user actions are needed to pay a subscription's invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the payment intent is not confirmed within 23 hours subscriptions transition to `status=incomplete_expired`, which is a terminal state.
|
|
@@ -661,6 +663,8 @@ declare module 'stripe' {
|
|
|
661
663
|
* Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not create a subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
|
|
662
664
|
*
|
|
663
665
|
* `pending_if_incomplete` is only used with updates and cannot be passed when creating a subscription.
|
|
666
|
+
*
|
|
667
|
+
* Subscriptions with `collection_method=send_invoice` are automatically activated regardless of the first invoice status.
|
|
664
668
|
*/
|
|
665
669
|
payment_behavior?: SubscriptionCreateParams.PaymentBehavior;
|
|
666
670
|
|
|
@@ -1210,7 +1214,7 @@ declare module 'stripe' {
|
|
|
1210
1214
|
cancel_at_period_end?: boolean;
|
|
1211
1215
|
|
|
1212
1216
|
/**
|
|
1213
|
-
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions
|
|
1217
|
+
* Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
|
1214
1218
|
*/
|
|
1215
1219
|
collection_method?: SubscriptionUpdateParams.CollectionMethod;
|
|
1216
1220
|
|
|
@@ -235,7 +235,7 @@ declare module 'stripe' {
|
|
|
235
235
|
|
|
236
236
|
interface InboundTransfers {
|
|
237
237
|
/**
|
|
238
|
-
* Toggle settings for enabling/disabling
|
|
238
|
+
* Toggle settings for enabling/disabling an ACH specific feature
|
|
239
239
|
*/
|
|
240
240
|
ach?: InboundTransfers.Ach;
|
|
241
241
|
}
|
|
@@ -360,7 +360,7 @@ declare module 'stripe' {
|
|
|
360
360
|
|
|
361
361
|
interface OutboundPayments {
|
|
362
362
|
/**
|
|
363
|
-
* Toggle settings for enabling/disabling
|
|
363
|
+
* Toggle settings for enabling/disabling an ACH specific feature
|
|
364
364
|
*/
|
|
365
365
|
ach?: OutboundPayments.Ach;
|
|
366
366
|
|
|
@@ -490,7 +490,7 @@ declare module 'stripe' {
|
|
|
490
490
|
|
|
491
491
|
interface OutboundTransfers {
|
|
492
492
|
/**
|
|
493
|
-
* Toggle settings for enabling/disabling
|
|
493
|
+
* Toggle settings for enabling/disabling an ACH specific feature
|
|
494
494
|
*/
|
|
495
495
|
ach?: OutboundTransfers.Ach;
|
|
496
496
|
|
package/types/Webhooks.d.ts
CHANGED
|
@@ -13,7 +13,6 @@ declare module 'stripe' {
|
|
|
13
13
|
* Raw text body payload received from Stripe.
|
|
14
14
|
*/
|
|
15
15
|
payload: string | Buffer,
|
|
16
|
-
|
|
17
16
|
/**
|
|
18
17
|
* Value of the `stripe-signature` header from Stripe.
|
|
19
18
|
* Typically a string.
|
|
@@ -25,18 +24,15 @@ declare module 'stripe' {
|
|
|
25
24
|
* only a string.
|
|
26
25
|
*/
|
|
27
26
|
header: string | Buffer | Array<string>,
|
|
28
|
-
|
|
29
27
|
/**
|
|
30
28
|
* Your Webhook Signing Secret for this endpoint (e.g., 'whsec_...').
|
|
31
29
|
* You can get this [in your dashboard](https://dashboard.stripe.com/webhooks).
|
|
32
30
|
*/
|
|
33
31
|
secret: string,
|
|
34
|
-
|
|
35
32
|
/**
|
|
36
33
|
* Seconds of tolerance on timestamps.
|
|
37
34
|
*/
|
|
38
35
|
tolerance?: number,
|
|
39
|
-
|
|
40
36
|
/**
|
|
41
37
|
* Optional CryptoProvider to use for computing HMAC signatures.
|
|
42
38
|
*/
|
|
@@ -54,7 +50,6 @@ declare module 'stripe' {
|
|
|
54
50
|
* Raw text body payload received from Stripe.
|
|
55
51
|
*/
|
|
56
52
|
payload: string | Buffer,
|
|
57
|
-
|
|
58
53
|
/**
|
|
59
54
|
* Value of the `stripe-signature` header from Stripe.
|
|
60
55
|
* Typically a string.
|
|
@@ -66,18 +61,15 @@ declare module 'stripe' {
|
|
|
66
61
|
* only a string.
|
|
67
62
|
*/
|
|
68
63
|
header: string | Buffer | Array<string>,
|
|
69
|
-
|
|
70
64
|
/**
|
|
71
65
|
* Your Webhook Signing Secret for this endpoint (e.g., 'whsec_...').
|
|
72
66
|
* You can get this [in your dashboard](https://dashboard.stripe.com/webhooks).
|
|
73
67
|
*/
|
|
74
68
|
secret: string,
|
|
75
|
-
|
|
76
69
|
/**
|
|
77
70
|
* Seconds of tolerance on timestamps.
|
|
78
71
|
*/
|
|
79
72
|
tolerance?: number,
|
|
80
|
-
|
|
81
73
|
/**
|
|
82
74
|
* Optional CryptoProvider to use for computing HMAC signatures.
|
|
83
75
|
*/
|