Repository: stripe/stripe-node
Pull request #826 (2020-03-03 17:30:13)

Updates Typescript definitions for the latest API version `2020-03-02` and related changes
Multiple API changes:
* Types are now for the API version `2020-03-02`
* Remove `uob_regional` as a value on `bank` for FPX as this is deprecated and was never used
* Add support for `next_invoice_sequence` on `Customer`
* Add support for `proration_behavior` on `SubscriptionItem` delete

r? @ob-stripe 
cc @stripe/api-libraries 



Patch:
diff --git a/README.md b/README.md
index fc6d74a6..e1ecf692 100644
--- a/README.md
+++ b/README.md
@@ -67,7 +67,7 @@ and instantiate it as `new Stripe()` with the latest API version.
 ```ts
 import Stripe from 'stripe';
 const stripe = new Stripe('sk_test_...', {
-  apiVersion: '2019-12-03',
+  apiVersion: '2020-03-02',
 });
 
 const createCustomer = async () => {
diff --git a/examples/webhook-signing/typescript-node-express/express-ts.ts b/examples/webhook-signing/typescript-node-express/express-ts.ts
index 4b194401..92a11410 100644
--- a/examples/webhook-signing/typescript-node-express/express-ts.ts
+++ b/examples/webhook-signing/typescript-node-express/express-ts.ts
@@ -6,7 +6,7 @@ import env from 'dotenv';
 env.config();
 
 const stripe = new Stripe(process.env.STRIPE_SECRET_KEY, {
-  apiVersion: '2019-12-03',
+  apiVersion: '2020-03-02',
 });
 
 const webhookSecret: string = process.env.STRIPE_WEBHOOK_SECRET;
diff --git a/package.json b/package.json
index a871af3b..6ef7705d 100644
--- a/package.json
+++ b/package.json
@@ -25,7 +25,7 @@
     "node": "^8.1 || >=10.*"
   },
   "main": "lib/stripe.js",
-  "types": "types/2019-12-03/index.d.ts",
+  "types": "types/2020-03-02/index.d.ts",
   "devDependencies": {
     "@typescript-eslint/eslint-plugin": "^2.13.0",
     "@typescript-eslint/parser": "^2.13.0",
diff --git a/types/2019-12-03/AccountLinks.d.ts b/types/2020-03-02/AccountLinks.d.ts
similarity index 100%
rename from types/2019-12-03/AccountLinks.d.ts
rename to types/2020-03-02/AccountLinks.d.ts
diff --git a/types/2019-12-03/Accounts.d.ts b/types/2020-03-02/Accounts.d.ts
similarity index 100%
rename from types/2019-12-03/Accounts.d.ts
rename to types/2020-03-02/Accounts.d.ts
diff --git a/types/2019-12-03/Addresses.d.ts b/types/2020-03-02/Addresses.d.ts
similarity index 100%
rename from types/2019-12-03/Addresses.d.ts
rename to types/2020-03-02/Addresses.d.ts
diff --git a/types/2019-12-03/AlipayAccounts.d.ts b/types/2020-03-02/AlipayAccounts.d.ts
similarity index 100%
rename from types/2019-12-03/AlipayAccounts.d.ts
rename to types/2020-03-02/AlipayAccounts.d.ts
diff --git a/types/2019-12-03/ApplePayDomains.d.ts b/types/2020-03-02/ApplePayDomains.d.ts
similarity index 100%
rename from types/2019-12-03/ApplePayDomains.d.ts
rename to types/2020-03-02/ApplePayDomains.d.ts
diff --git a/types/2019-12-03/ApplicationFees.d.ts b/types/2020-03-02/ApplicationFees.d.ts
similarity index 100%
rename from types/2019-12-03/ApplicationFees.d.ts
rename to types/2020-03-02/ApplicationFees.d.ts
diff --git a/types/2019-12-03/Applications.d.ts b/types/2020-03-02/Applications.d.ts
similarity index 100%
rename from types/2019-12-03/Applications.d.ts
rename to types/2020-03-02/Applications.d.ts
diff --git a/types/2019-12-03/Balance.d.ts b/types/2020-03-02/Balance.d.ts
similarity index 100%
rename from types/2019-12-03/Balance.d.ts
rename to types/2020-03-02/Balance.d.ts
diff --git a/types/2019-12-03/BalanceTransactions.d.ts b/types/2020-03-02/BalanceTransactions.d.ts
similarity index 100%
rename from types/2019-12-03/BalanceTransactions.d.ts
rename to types/2020-03-02/BalanceTransactions.d.ts
diff --git a/types/2019-12-03/BankAccounts.d.ts b/types/2020-03-02/BankAccounts.d.ts
similarity index 100%
rename from types/2019-12-03/BankAccounts.d.ts
rename to types/2020-03-02/BankAccounts.d.ts
diff --git a/types/2019-12-03/BitcoinReceivers.d.ts b/types/2020-03-02/BitcoinReceivers.d.ts
similarity index 100%
rename from types/2019-12-03/BitcoinReceivers.d.ts
rename to types/2020-03-02/BitcoinReceivers.d.ts
diff --git a/types/2019-12-03/BitcoinTransactions.d.ts b/types/2020-03-02/BitcoinTransactions.d.ts
similarity index 100%
rename from types/2019-12-03/BitcoinTransactions.d.ts
rename to types/2020-03-02/BitcoinTransactions.d.ts
diff --git a/types/2019-12-03/Capabilities.d.ts b/types/2020-03-02/Capabilities.d.ts
similarity index 100%
rename from types/2019-12-03/Capabilities.d.ts
rename to types/2020-03-02/Capabilities.d.ts
diff --git a/types/2019-12-03/Cards.d.ts b/types/2020-03-02/Cards.d.ts
similarity index 100%
rename from types/2019-12-03/Cards.d.ts
rename to types/2020-03-02/Cards.d.ts
diff --git a/types/2019-12-03/Charges.d.ts b/types/2020-03-02/Charges.d.ts
similarity index 99%
rename from types/2019-12-03/Charges.d.ts
rename to types/2020-03-02/Charges.d.ts
index d269224d..8c904336 100644
--- a/types/2019-12-03/Charges.d.ts
+++ b/types/2020-03-02/Charges.d.ts
@@ -931,7 +931,7 @@ declare module 'stripe' {
           account_holder_type: Fpx.AccountHolderType | null;
 
           /**
-           * The customer's bank. Can be one of `affin_bank`, `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 `uob_regional`.
+           * The customer's bank. Can be one of `affin_bank`, `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 `pb_enterprise`.
            */
           bank: Fpx.Bank;
 
@@ -964,8 +964,7 @@ declare module 'stripe' {
             | 'public_bank'
             | 'rhb'
             | 'standard_chartered'
-            | 'uob'
-            | 'uob_regional';
+            | 'uob';
         }
 
         interface Giropay {
diff --git a/types/2019-12-03/Checkout/Sessions.d.ts b/types/2020-03-02/Checkout/Sessions.d.ts
similarity index 100%
rename from types/2019-12-03/Checkout/Sessions.d.ts
rename to types/2020-03-02/Checkout/Sessions.d.ts
diff --git a/types/2019-12-03/ConnectCollectionTransfers.d.ts b/types/2020-03-02/ConnectCollectionTransfers.d.ts
similarity index 100%
rename from types/2019-12-03/ConnectCollectionTransfers.d.ts
rename to types/2020-03-02/ConnectCollectionTransfers.d.ts
diff --git a/types/2019-12-03/CountrySpecs.d.ts b/types/2020-03-02/CountrySpecs.d.ts
similarity index 100%
rename from types/2019-12-03/CountrySpecs.d.ts
rename to types/2020-03-02/CountrySpecs.d.ts
diff --git a/types/2019-12-03/Coupons.d.ts b/types/2020-03-02/Coupons.d.ts
similarity index 100%
rename from types/2019-12-03/Coupons.d.ts
rename to types/2020-03-02/Coupons.d.ts
diff --git a/types/2019-12-03/CreditNoteLineItems.d.ts b/types/2020-03-02/CreditNoteLineItems.d.ts
similarity index 100%
rename from types/2019-12-03/CreditNoteLineItems.d.ts
rename to types/2020-03-02/CreditNoteLineItems.d.ts
diff --git a/types/2019-12-03/CreditNotes.d.ts b/types/2020-03-02/CreditNotes.d.ts
similarity index 100%
rename from types/2019-12-03/CreditNotes.d.ts
rename to types/2020-03-02/CreditNotes.d.ts
diff --git a/types/2019-12-03/CustomerBalanceTransactions.d.ts b/types/2020-03-02/CustomerBalanceTransactions.d.ts
similarity index 100%
rename from types/2019-12-03/CustomerBalanceTransactions.d.ts
rename to types/2020-03-02/CustomerBalanceTransactions.d.ts
diff --git a/types/2019-12-03/CustomerSources.d.ts b/types/2020-03-02/CustomerSources.d.ts
similarity index 100%
rename from types/2019-12-03/CustomerSources.d.ts
rename to types/2020-03-02/CustomerSources.d.ts
diff --git a/types/2019-12-03/Customers.d.ts b/types/2020-03-02/Customers.d.ts
similarity index 98%
rename from types/2019-12-03/Customers.d.ts
rename to types/2020-03-02/Customers.d.ts
index 21d53167..2289c95f 100644
--- a/types/2019-12-03/Customers.d.ts
+++ b/types/2020-03-02/Customers.d.ts
@@ -85,6 +85,11 @@ declare module 'stripe' {
        */
       name: string | null;
 
+      /**
+       * The suffix of the customer's next invoice number, e.g., 0001.
+       */
+      next_invoice_sequence?: number;
+
       /**
        * The customer's phone number.
        */
@@ -248,6 +253,11 @@ declare module 'stripe' {
        */
       name?: string;
 
+      /**
+       * The sequence to be used on the customer's next invoice. Defaults to 1.
+       */
+      next_invoice_sequence?: number;
+
       payment_method?: string;
 
       /**
@@ -432,6 +442,11 @@ declare module 'stripe' {
        */
       name?: string;
 
+      /**
+       * The sequence to be used on the customer's next invoice. Defaults to 1.
+       */
+      next_invoice_sequence?: number;
+
       /**
        * The customer's phone number.
        */
diff --git a/types/2019-12-03/Discounts.d.ts b/types/2020-03-02/Discounts.d.ts
similarity index 100%
rename from types/2019-12-03/Discounts.d.ts
rename to types/2020-03-02/Discounts.d.ts
diff --git a/types/2019-12-03/Disputes.d.ts b/types/2020-03-02/Disputes.d.ts
similarity index 100%
rename from types/2019-12-03/Disputes.d.ts
rename to types/2020-03-02/Disputes.d.ts
diff --git a/types/2019-12-03/EphemeralKeys.d.ts b/types/2020-03-02/EphemeralKeys.d.ts
similarity index 100%
rename from types/2019-12-03/EphemeralKeys.d.ts
rename to types/2020-03-02/EphemeralKeys.d.ts
diff --git a/types/2019-12-03/Events.d.ts b/types/2020-03-02/Events.d.ts
similarity index 100%
rename from types/2019-12-03/Events.d.ts
rename to types/2020-03-02/Events.d.ts
diff --git a/types/2019-12-03/ExchangeRates.d.ts b/types/2020-03-02/ExchangeRates.d.ts
similarity index 100%
rename from types/2019-12-03/ExchangeRates.d.ts
rename to types/2020-03-02/ExchangeRates.d.ts
diff --git a/types/2019-12-03/ExternalAccounts.d.ts b/types/2020-03-02/ExternalAccounts.d.ts
similarity index 100%
rename from types/2019-12-03/ExternalAccounts.d.ts
rename to types/2020-03-02/ExternalAccounts.d.ts
diff --git a/types/2019-12-03/FeeRefunds.d.ts b/types/2020-03-02/FeeRefunds.d.ts
similarity index 100%
rename from types/2019-12-03/FeeRefunds.d.ts
rename to types/2020-03-02/FeeRefunds.d.ts
diff --git a/types/2019-12-03/FileLinks.d.ts b/types/2020-03-02/FileLinks.d.ts
similarity index 100%
rename from types/2019-12-03/FileLinks.d.ts
rename to types/2020-03-02/FileLinks.d.ts
diff --git a/types/2019-12-03/Files.d.ts b/types/2020-03-02/Files.d.ts
similarity index 100%
rename from types/2019-12-03/Files.d.ts
rename to types/2020-03-02/Files.d.ts
diff --git a/types/2019-12-03/InvoiceItems.d.ts b/types/2020-03-02/InvoiceItems.d.ts
similarity index 100%
rename from types/2019-12-03/InvoiceItems.d.ts
rename to types/2020-03-02/InvoiceItems.d.ts
diff --git a/types/2019-12-03/InvoiceLineItems.d.ts b/types/2020-03-02/InvoiceLineItems.d.ts
similarity index 100%
rename from types/2019-12-03/InvoiceLineItems.d.ts
rename to types/2020-03-02/InvoiceLineItems.d.ts
diff --git a/types/2019-12-03/Invoices.d.ts b/types/2020-03-02/Invoices.d.ts
similarity index 100%
rename from types/2019-12-03/Invoices.d.ts
rename to types/2020-03-02/Invoices.d.ts
diff --git a/types/2019-12-03/IssuerFraudRecords.d.ts b/types/2020-03-02/IssuerFraudRecords.d.ts
similarity index 100%
rename from types/2019-12-03/IssuerFraudRecords.d.ts
rename to types/2020-03-02/IssuerFraudRecords.d.ts
diff --git a/types/2019-12-03/Issuing/Authorizations.d.ts b/types/2020-03-02/Issuing/Authorizations.d.ts
similarity index 100%
rename from types/2019-12-03/Issuing/Authorizations.d.ts
rename to types/2020-03-02/Issuing/Authorizations.d.ts
diff --git a/types/2019-12-03/Issuing/CardDetails.d.ts b/types/2020-03-02/Issuing/CardDetails.d.ts
similarity index 100%
rename from types/2019-12-03/Issuing/CardDetails.d.ts
rename to types/2020-03-02/Issuing/CardDetails.d.ts
diff --git a/types/2019-12-03/Issuing/Cardholders.d.ts b/types/2020-03-02/Issuing/Cardholders.d.ts
similarity index 100%
rename from types/2019-12-03/Issuing/Cardholders.d.ts
rename to types/2020-03-02/Issuing/Cardholders.d.ts
diff --git a/types/2019-12-03/Issuing/Cards.d.ts b/types/2020-03-02/Issuing/Cards.d.ts
similarity index 100%
rename from types/2019-12-03/Issuing/Cards.d.ts
rename to types/2020-03-02/Issuing/Cards.d.ts
diff --git a/types/2019-12-03/Issuing/Disputes.d.ts b/types/2020-03-02/Issuing/Disputes.d.ts
similarity index 100%
rename from types/2019-12-03/Issuing/Disputes.d.ts
rename to types/2020-03-02/Issuing/Disputes.d.ts
diff --git a/types/2019-12-03/Issuing/Transactions.d.ts b/types/2020-03-02/Issuing/Transactions.d.ts
similarity index 100%
rename from types/2019-12-03/Issuing/Transactions.d.ts
rename to types/2020-03-02/Issuing/Transactions.d.ts
diff --git a/types/2019-12-03/LoginLinks.d.ts b/types/2020-03-02/LoginLinks.d.ts
similarity index 100%
rename from types/2019-12-03/LoginLinks.d.ts
rename to types/2020-03-02/LoginLinks.d.ts
diff --git a/types/2019-12-03/Mandates.d.ts b/types/2020-03-02/Mandates.d.ts
similarity index 100%
rename from types/2019-12-03/Mandates.d.ts
rename to types/2020-03-02/Mandates.d.ts
diff --git a/types/2019-12-03/OrderItems.d.ts b/types/2020-03-02/OrderItems.d.ts
similarity index 100%
rename from types/2019-12-03/OrderItems.d.ts
rename to types/2020-03-02/OrderItems.d.ts
diff --git a/types/2019-12-03/OrderReturns.d.ts b/types/2020-03-02/OrderReturns.d.ts
similarity index 100%
rename from types/2019-12-03/OrderReturns.d.ts
rename to types/2020-03-02/OrderReturns.d.ts
diff --git a/types/2019-12-03/Orders.d.ts b/types/2020-03-02/Orders.d.ts
similarity index 100%
rename from types/2019-12-03/Orders.d.ts
rename to types/2020-03-02/Orders.d.ts
diff --git a/types/2019-12-03/PaymentIntents.d.ts b/types/2020-03-02/PaymentIntents.d.ts
similarity index 100%
rename from types/2019-12-03/PaymentIntents.d.ts
rename to types/2020-03-02/PaymentIntents.d.ts
diff --git a/types/2019-12-03/PaymentMethods.d.ts b/types/2020-03-02/PaymentMethods.d.ts
similarity index 99%
rename from types/2019-12-03/PaymentMethods.d.ts
rename to types/2020-03-02/PaymentMethods.d.ts
index 71f80330..697b6340 100644
--- a/types/2019-12-03/PaymentMethods.d.ts
+++ b/types/2020-03-02/PaymentMethods.d.ts
@@ -282,7 +282,7 @@ declare module 'stripe' {
         account_holder_type: Fpx.AccountHolderType | null;
 
         /**
-         * The customer's bank, if provided. Can be one of `affin_bank`, `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 `uob_regional`.
+         * The customer's bank, if provided. Can be one of `affin_bank`, `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 `pb_enterprise`.
          */
         bank: Fpx.Bank;
       }
@@ -310,8 +310,7 @@ declare module 'stripe' {
           | 'public_bank'
           | 'rhb'
           | 'standard_chartered'
-          | 'uob'
-          | 'uob_regional';
+          | 'uob';
       }
 
       interface Ideal {
@@ -573,8 +572,7 @@ declare module 'stripe' {
           | 'public_bank'
           | 'rhb'
           | 'standard_chartered'
-          | 'uob'
-          | 'uob_regional';
+          | 'uob';
       }
 
       interface Ideal {
diff --git a/types/2019-12-03/Payouts.d.ts b/types/2020-03-02/Payouts.d.ts
similarity index 100%
rename from types/2019-12-03/Payouts.d.ts
rename to types/2020-03-02/Payouts.d.ts
diff --git a/types/2019-12-03/Persons.d.ts b/types/2020-03-02/Persons.d.ts
similarity index 100%
rename from types/2019-12-03/Persons.d.ts
rename to types/2020-03-02/Persons.d.ts
diff --git a/types/2019-12-03/Plans.d.ts b/types/2020-03-02/Plans.d.ts
similarity index 100%
rename from types/2019-12-03/Plans.d.ts
rename to types/2020-03-02/Plans.d.ts
diff --git a/types/2019-12-03/PlatformTaxFees.d.ts b/types/2020-03-02/PlatformTaxFees.d.ts
similarity index 100%
rename from types/2019-12-03/PlatformTaxFees.d.ts
rename to types/2020-03-02/PlatformTaxFees.d.ts
diff --git a/types/2019-12-03/Products.d.ts b/types/2020-03-02/Products.d.ts
similarity index 100%
rename from types/2019-12-03/Products.d.ts
rename to types/2020-03-02/Products.d.ts
diff --git a/types/2019-12-03/Radar/EarlyFraudWarnings.d.ts b/types/2020-03-02/Radar/EarlyFraudWarnings.d.ts
similarity index 100%
rename from types/2019-12-03/Radar/EarlyFraudWarnings.d.ts
rename to types/2020-03-02/Radar/EarlyFraudWarnings.d.ts
diff --git a/types/2019-12-03/Radar/ValueListItems.d.ts b/types/2020-03-02/Radar/ValueListItems.d.ts
similarity index 100%
rename from types/2019-12-03/Radar/ValueListItems.d.ts
rename to types/2020-03-02/Radar/ValueListItems.d.ts
diff --git a/types/2019-12-03/Radar/ValueLists.d.ts b/types/2020-03-02/Radar/ValueLists.d.ts
similarity index 100%
rename from types/2019-12-03/Radar/ValueLists.d.ts
rename to types/2020-03-02/Radar/ValueLists.d.ts
diff --git a/types/2019-12-03/Recipients.d.ts b/types/2020-03-02/Recipients.d.ts
similarity index 100%
rename from types/2019-12-03/Recipients.d.ts
rename to types/2020-03-02/Recipients.d.ts
diff --git a/types/2019-12-03/Refunds.d.ts b/types/2020-03-02/Refunds.d.ts
similarity index 100%
rename from types/2019-12-03/Refunds.d.ts
rename to types/2020-03-02/Refunds.d.ts
diff --git a/types/2019-12-03/Reporting/ReportRuns.d.ts b/types/2020-03-02/Reporting/ReportRuns.d.ts
similarity index 100%
rename from types/2019-12-03/Reporting/ReportRuns.d.ts
rename to types/2020-03-02/Reporting/ReportRuns.d.ts
diff --git a/types/2019-12-03/Reporting/ReportTypes.d.ts b/types/2020-03-02/Reporting/ReportTypes.d.ts
similarity index 100%
rename from types/2019-12-03/Reporting/ReportTypes.d.ts
rename to types/2020-03-02/Reporting/ReportTypes.d.ts
diff --git a/types/2019-12-03/ReserveTransactions.d.ts b/types/2020-03-02/ReserveTransactions.d.ts
similarity index 100%
rename from types/2019-12-03/ReserveTransactions.d.ts
rename to types/2020-03-02/ReserveTransactions.d.ts
diff --git a/types/2019-12-03/Reviews.d.ts b/types/2020-03-02/Reviews.d.ts
similarity index 100%
rename from types/2019-12-03/Reviews.d.ts
rename to types/2020-03-02/Reviews.d.ts
diff --git a/types/2019-12-03/SKUs.d.ts b/types/2020-03-02/SKUs.d.ts
similarity index 100%
rename from types/2019-12-03/SKUs.d.ts
rename to types/2020-03-02/SKUs.d.ts
diff --git a/types/2019-12-03/SetupIntents.d.ts b/types/2020-03-02/SetupIntents.d.ts
similarity index 100%
rename from types/2019-12-03/SetupIntents.d.ts
rename to types/2020-03-02/SetupIntents.d.ts
diff --git a/types/2019-12-03/Sigma/ScheduledQueryRuns.d.ts b/types/2020-03-02/Sigma/ScheduledQueryRuns.d.ts
similarity index 100%
rename from types/2019-12-03/Sigma/ScheduledQueryRuns.d.ts
rename to types/2020-03-02/Sigma/ScheduledQueryRuns.d.ts
diff --git a/types/2019-12-03/SourceMandateNotifications.d.ts b/types/2020-03-02/SourceMandateNotifications.d.ts
similarity index 100%
rename from types/2019-12-03/SourceMandateNotifications.d.ts
rename to types/2020-03-02/SourceMandateNotifications.d.ts
diff --git a/types/2019-12-03/SourceTransactions.d.ts b/types/2020-03-02/SourceTransactions.d.ts
similarity index 100%
rename from types/2019-12-03/SourceTransactions.d.ts
rename to types/2020-03-02/SourceTransactions.d.ts
diff --git a/types/2019-12-03/Sources.d.ts b/types/2020-03-02/Sources.d.ts
similarity index 100%
rename from types/2019-12-03/Sources.d.ts
rename to types/2020-03-02/Sources.d.ts
diff --git a/types/2019-12-03/SubscriptionItems.d.ts b/types/2020-03-02/SubscriptionItems.d.ts
similarity index 91%
rename from types/2019-12-03/SubscriptionItems.d.ts
rename to types/2020-03-02/SubscriptionItems.d.ts
index 1b37fce7..b505f217 100644
--- a/types/2019-12-03/SubscriptionItems.d.ts
+++ b/types/2020-03-02/SubscriptionItems.d.ts
@@ -122,7 +122,7 @@ declare module 'stripe' {
       plan?: string;
 
       /**
-       * Flag indicating whether to [prorate](https://stripe.com/docs/billing/subscriptions/prorations) switching plans during a billing cycle. This field has been deprecated and will be removed in a future API version. Use `proration_behavior=create_prorations` as a replacement for `prorate=true` and `proration_behavior=none` for `prorate=false`.
+       * This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`.
        */
       prorate?: boolean;
 
@@ -210,7 +210,7 @@ declare module 'stripe' {
       plan?: string;
 
       /**
-       * Flag indicating whether to [prorate](https://stripe.com/docs/billing/subscriptions/prorations) switching plans during a billing cycle. This field has been deprecated and will be removed in a future API version. Use `proration_behavior=create_prorations` as a replacement for `prorate=true` and `proration_behavior=none` for `prorate=false`.
+       * This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`.
        */
       prorate?: boolean;
 
@@ -274,16 +274,29 @@ declare module 'stripe' {
       clear_usage?: boolean;
 
       /**
-       * Flag indicating whether to [prorate](https://stripe.com/docs/billing/subscriptions/prorations) switching plans during a billing cycle.
+       * This field has been renamed to `proration_behavior`. `prorate=true` can be replaced with `proration_behavior=create_prorations` and `prorate=false` can be replaced with `proration_behavior=none`.
        */
       prorate?: boolean;
 
+      /**
+       * Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. Valid values are `create_prorations`, `none`, or `always_invoice`.
+       *
+       * Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
+       *
+       * Prorations can be disabled by passing `none`.
+       */
+      proration_behavior?: SubscriptionItemDeleteParams.ProrationBehavior;
+
       /**
        * If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
        */
       proration_date?: number;
     }
 
+    namespace SubscriptionItemDeleteParams {
+      type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
+    }
+
     class SubscriptionItemsResource {
       /**
        * Adds a new item to an existing subscription. No existing items will be changed or replaced.
diff --git a/types/2019-12-03/SubscriptionSchedules.d.ts b/types/2020-03-02/SubscriptionSchedules.d.ts
similarity index 100%
rename from types/2019-12-03/SubscriptionSchedules.d.ts
rename to types/2020-03-02/SubscriptionSchedules.d.ts
diff --git a/types/2019-12-03/Subscriptions.d.ts b/types/2020-03-02/Subscriptions.d.ts
similarity index 100%
rename from types/2019-12-03/Subscriptions.d.ts
rename to types/2020-03-02/Subscriptions.d.ts
diff --git a/types/2019-12-03/TaxDeductedAtSources.d.ts b/types/2020-03-02/TaxDeductedAtSources.d.ts
similarity index 100%
rename from types/2019-12-03/TaxDeductedAtSources.d.ts
rename to types/2020-03-02/TaxDeductedAtSources.d.ts
diff --git a/types/2019-12-03/TaxIds.d.ts b/types/2020-03-02/TaxIds.d.ts
similarity index 100%
rename from types/2019-12-03/TaxIds.d.ts
rename to types/2020-03-02/TaxIds.d.ts
diff --git a/types/2019-12-03/TaxRates.d.ts b/types/2020-03-02/TaxRates.d.ts
similarity index 100%
rename from types/2019-12-03/TaxRates.d.ts
rename to types/2020-03-02/TaxRates.d.ts
diff --git a/types/2019-12-03/Terminal/ConnectionTokens.d.ts b/types/2020-03-02/Terminal/ConnectionTokens.d.ts
similarity index 100%
rename from types/2019-12-03/Terminal/ConnectionTokens.d.ts
rename to types/2020-03-02/Terminal/ConnectionTokens.d.ts
diff --git a/types/2019-12-03/Terminal/Locations.d.ts b/types/2020-03-02/Terminal/Locations.d.ts
similarity index 100%
rename from types/2019-12-03/Terminal/Locations.d.ts
rename to types/2020-03-02/Terminal/Locations.d.ts
diff --git a/types/2019-12-03/Terminal/Readers.d.ts b/types/2020-03-02/Terminal/Readers.d.ts
similarity index 100%
rename from types/2019-12-03/Terminal/Readers.d.ts
rename to types/2020-03-02/Terminal/Readers.d.ts
diff --git a/types/2019-12-03/Tokens.d.ts b/types/2020-03-02/Tokens.d.ts
similarity index 100%
rename from types/2019-12-03/Tokens.d.ts
rename to types/2020-03-02/Tokens.d.ts
diff --git a/types/2019-12-03/Topups.d.ts b/types/2020-03-02/Topups.d.ts
similarity index 100%
rename from types/2019-12-03/Topups.d.ts
rename to types/2020-03-02/Topups.d.ts
diff --git a/types/2019-12-03/TransferReversals.d.ts b/types/2020-03-02/TransferReversals.d.ts
similarity index 100%
rename from types/2019-12-03/TransferReversals.d.ts
rename to types/2020-03-02/TransferReversals.d.ts
diff --git a/types/2019-12-03/Transfers.d.ts b/types/2020-03-02/Transfers.d.ts
similarity index 100%
rename from types/2019-12-03/Transfers.d.ts
rename to types/2020-03-02/Transfers.d.ts
diff --git a/types/2019-12-03/UsageRecordSummaries.d.ts b/types/2020-03-02/UsageRecordSummaries.d.ts
similarity index 100%
rename from types/2019-12-03/UsageRecordSummaries.d.ts
rename to types/2020-03-02/UsageRecordSummaries.d.ts
diff --git a/types/2019-12-03/UsageRecords.d.ts b/types/2020-03-02/UsageRecords.d.ts
similarity index 100%
rename from types/2019-12-03/UsageRecords.d.ts
rename to types/2020-03-02/UsageRecords.d.ts
diff --git a/types/2019-12-03/WebhookEndpoints.d.ts b/types/2020-03-02/WebhookEndpoints.d.ts
similarity index 99%
rename from types/2019-12-03/WebhookEndpoints.d.ts
rename to types/2020-03-02/WebhookEndpoints.d.ts
index 25a80591..a839387e 100644
--- a/types/2019-12-03/WebhookEndpoints.d.ts
+++ b/types/2020-03-02/WebhookEndpoints.d.ts
@@ -199,7 +199,8 @@ declare module 'stripe' {
         | '2019-10-08'
         | '2019-10-17'
         | '2019-11-05'
-        | '2019-12-03';
+        | '2019-12-03'
+        | '2020-03-02';
 
       type EnabledEvent =
         | '*'
diff --git a/types/2019-12-03/index.d.ts b/types/2020-03-02/index.d.ts
similarity index 100%
rename from types/2019-12-03/index.d.ts
rename to types/2020-03-02/index.d.ts
diff --git a/types/lib.d.ts b/types/lib.d.ts
index c2608f33..f1e2e2d3 100644
--- a/types/lib.d.ts
+++ b/types/lib.d.ts
@@ -5,7 +5,7 @@ import {Agent} from 'http';
 
 declare module 'stripe' {
   namespace Stripe {
-    export type LatestApiVersion = '2019-12-03';
+    export type LatestApiVersion = '2020-03-02';
     export type HttpAgent = Agent;
 
     export interface StripeConfig {
@@ -92,7 +92,7 @@ declare module 'stripe' {
       stripe_account?: string;
 
       /**
-       * The [API Version](https://stripe.com/docs/upgrades) to use for a given request (e.g., '2019-12-03').
+       * The [API Version](https://stripe.com/docs/upgrades) to use for a given request (e.g., '2020-03-02').
        */
       apiVersion?: string;
       /** @deprecated Please use apiVersion instead. */


Test patch:
diff --git a/types/test/typescriptTest.ts b/types/test/typescriptTest.ts
index 0c6d79b0..43caa022 100644
--- a/types/test/typescriptTest.ts
+++ b/types/test/typescriptTest.ts
@@ -5,11 +5,11 @@
  * and to perform a basic sanity check that types are exported as intended.
  */
 
-///<reference types="../2019-12-03" />
+///<reference types="../2020-03-02" />
 import Stripe from 'stripe';
 
 let stripe = new Stripe('sk_test_123', {
-  apiVersion: '2019-12-03',
+  apiVersion: '2020-03-02',
 });
 
 // @ts-ignore lazily ignore apiVersion requirement.
@@ -27,7 +27,7 @@ stripe = new Stripe('sk_test_123', {
 
 // Check config object.
 stripe = new Stripe('sk_test_123', {
-  apiVersion: '2019-12-03',
+  apiVersion: '2020-03-02',
   typescript: true,
   maxNetworkRetries: 1,
   timeout: 1000,
@@ -48,7 +48,7 @@ stripe.setHost('host', 'port', 'protocol');
     description: 'test',
   };
   const opts: Stripe.RequestOptions = {
-    apiVersion: '2019-12-03',
+    apiVersion: '2020-03-02',
   };
   const customer: Stripe.Customer = await stripe.customers.create(params, opts);