stripe 22.2.0 → 22.3.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1753 -76
- package/README.md +57 -65
- package/VERSION +1 -1
- package/cjs/Error.d.ts +50 -0
- package/cjs/Error.js +125 -1
- package/cjs/Error.js.map +1 -1
- package/cjs/RequestSender.d.ts +0 -1
- package/cjs/RequestSender.js +0 -8
- package/cjs/RequestSender.js.map +1 -1
- package/cjs/StripeEventNotificationHandler.d.ts +19 -0
- package/cjs/StripeEventNotificationHandler.js +148 -0
- package/cjs/StripeEventNotificationHandler.js.map +1 -0
- package/cjs/Types.d.ts +4 -2
- package/cjs/Types.js.map +1 -1
- package/cjs/apiVersion.d.ts +1 -2
- package/cjs/apiVersion.js +2 -3
- package/cjs/apiVersion.js.map +1 -1
- package/cjs/resources/AccountLinks.d.ts +1 -1
- package/cjs/resources/AccountNotices.d.ts +140 -0
- package/cjs/resources/AccountNotices.js +29 -0
- package/cjs/resources/AccountNotices.js.map +1 -0
- package/cjs/resources/AccountSessions.d.ts +262 -0
- package/cjs/resources/AccountSessions.js.map +1 -1
- package/cjs/resources/Accounts.d.ts +827 -3
- package/cjs/resources/Accounts.js +14 -0
- package/cjs/resources/Accounts.js.map +1 -1
- package/cjs/resources/Balance.d.ts +67 -0
- package/cjs/resources/BankAccounts.d.ts +2 -2
- package/cjs/resources/Billing/AlertTriggereds.d.ts +2 -1
- package/cjs/resources/Billing/Analytics/MeterUsage.d.ts +84 -0
- package/cjs/resources/Billing/Analytics/MeterUsage.js +15 -0
- package/cjs/resources/Billing/Analytics/MeterUsage.js.map +1 -0
- package/cjs/resources/Billing/Analytics/MeterUsageRows.d.ts +32 -0
- package/cjs/resources/Billing/Analytics/MeterUsageRows.js +4 -0
- package/cjs/resources/Billing/Analytics/MeterUsageRows.js.map +1 -0
- package/cjs/resources/Billing/Analytics/index.d.ts +15 -0
- package/cjs/resources/Billing/Analytics/index.js +13 -0
- package/cjs/resources/Billing/Analytics/index.js.map +1 -0
- package/cjs/resources/Billing/index.d.ts +3 -0
- package/cjs/resources/Billing/index.js +2 -0
- package/cjs/resources/Billing/index.js.map +1 -1
- package/cjs/resources/Capabilities.d.ts +2 -2
- package/cjs/resources/Capital/FinancingOffers.d.ts +191 -0
- package/cjs/resources/Capital/FinancingOffers.js +30 -0
- package/cjs/resources/Capital/FinancingOffers.js.map +1 -0
- package/cjs/resources/Capital/FinancingSummary.d.ts +98 -0
- package/cjs/resources/Capital/FinancingSummary.js +15 -0
- package/cjs/resources/Capital/FinancingSummary.js.map +1 -0
- package/cjs/resources/Capital/FinancingTransactions.d.ts +143 -0
- package/cjs/resources/Capital/FinancingTransactions.js +24 -0
- package/cjs/resources/Capital/FinancingTransactions.js.map +1 -0
- package/cjs/resources/Capital/index.d.ts +25 -0
- package/cjs/resources/Capital/index.js +17 -0
- package/cjs/resources/Capital/index.js.map +1 -0
- package/cjs/resources/Cards.d.ts +4 -0
- package/cjs/resources/Charges.d.ts +3064 -70
- package/cjs/resources/Checkout/Sessions.d.ts +390 -4
- package/cjs/resources/ConfirmationTokens.d.ts +67 -1
- package/cjs/resources/Coupons.d.ts +53 -0
- package/cjs/resources/Coupons.js +13 -0
- package/cjs/resources/Coupons.js.map +1 -1
- package/cjs/resources/CreditNoteLineItems.d.ts +15 -1
- package/cjs/resources/CreditNotes.d.ts +1 -1
- package/cjs/resources/CustomerSessions.d.ts +68 -0
- package/cjs/resources/Customers.d.ts +7 -1
- package/cjs/resources/Customers.js +14 -0
- package/cjs/resources/Customers.js.map +1 -1
- package/cjs/resources/Disputes.d.ts +29 -0
- package/cjs/resources/Events.d.ts +547 -2
- package/cjs/resources/ExternalAccounts.d.ts +212 -1
- package/cjs/resources/ExternalAccounts.js +44 -0
- package/cjs/resources/ExternalAccounts.js.map +1 -1
- package/cjs/resources/FinancialConnections/AccountInferredBalances.d.ts +24 -0
- package/cjs/resources/FinancialConnections/AccountInferredBalances.js +4 -0
- package/cjs/resources/FinancialConnections/AccountInferredBalances.js.map +1 -0
- package/cjs/resources/FinancialConnections/Accounts.d.ts +74 -4
- package/cjs/resources/FinancialConnections/Accounts.js +8 -0
- package/cjs/resources/FinancialConnections/Accounts.js.map +1 -1
- package/cjs/resources/FinancialConnections/Authorizations.d.ts +87 -0
- package/cjs/resources/FinancialConnections/Authorizations.js +15 -0
- package/cjs/resources/FinancialConnections/Authorizations.js.map +1 -0
- package/cjs/resources/FinancialConnections/Institutions.d.ts +101 -0
- package/cjs/resources/FinancialConnections/Institutions.js +23 -0
- package/cjs/resources/FinancialConnections/Institutions.js.map +1 -0
- package/cjs/resources/FinancialConnections/Sessions.d.ts +155 -7
- package/cjs/resources/FinancialConnections/index.d.ts +21 -6
- package/cjs/resources/FinancialConnections/index.js +4 -0
- package/cjs/resources/FinancialConnections/index.js.map +1 -1
- package/cjs/resources/FxQuotes.d.ts +212 -0
- package/cjs/resources/FxQuotes.js +29 -0
- package/cjs/resources/FxQuotes.js.map +1 -0
- package/cjs/resources/InvoiceItems.d.ts +85 -0
- package/cjs/resources/InvoiceItems.js.map +1 -1
- package/cjs/resources/InvoiceLineItems.d.ts +40 -2
- package/cjs/resources/Invoices.d.ts +1337 -19
- package/cjs/resources/Invoices.js +41 -0
- package/cjs/resources/Invoices.js.map +1 -1
- package/cjs/resources/Issuing/Cardholders.d.ts +2 -1
- package/cjs/resources/Issuing/CreditUnderwritingRecords.d.ts +640 -0
- package/cjs/resources/Issuing/CreditUnderwritingRecords.js +47 -0
- package/cjs/resources/Issuing/CreditUnderwritingRecords.js.map +1 -0
- package/cjs/resources/Issuing/DisputeSettlementDetails.d.ts +95 -0
- package/cjs/resources/Issuing/DisputeSettlementDetails.js +23 -0
- package/cjs/resources/Issuing/DisputeSettlementDetails.js.map +1 -0
- package/cjs/resources/Issuing/FraudLiabilityDebits.d.ts +68 -0
- package/cjs/resources/Issuing/FraudLiabilityDebits.js +23 -0
- package/cjs/resources/Issuing/FraudLiabilityDebits.js.map +1 -0
- package/cjs/resources/Issuing/Settlements.d.ts +85 -0
- package/cjs/resources/Issuing/Settlements.js +4 -0
- package/cjs/resources/Issuing/Settlements.js.map +1 -0
- package/cjs/resources/Issuing/Transactions.d.ts +9 -0
- package/cjs/resources/Issuing/Transactions.js.map +1 -1
- package/cjs/resources/Issuing/index.d.ts +47 -22
- package/cjs/resources/Issuing/index.js +6 -0
- package/cjs/resources/Issuing/index.js.map +1 -1
- package/cjs/resources/LineItems.d.ts +29 -2
- package/cjs/resources/Mandates.d.ts +33 -1
- package/cjs/resources/Mandates.js +8 -0
- package/cjs/resources/Mandates.js.map +1 -1
- package/cjs/resources/Margins.d.ts +115 -0
- package/cjs/resources/Margins.js +35 -0
- package/cjs/resources/Margins.js.map +1 -0
- package/cjs/resources/Orders.d.ts +4693 -0
- package/cjs/resources/Orders.js +457 -0
- package/cjs/resources/Orders.js.map +1 -0
- package/cjs/resources/PaymentAttemptRecords.d.ts +82 -0
- package/cjs/resources/PaymentIntents.d.ts +13239 -2321
- package/cjs/resources/PaymentIntents.js +27 -0
- package/cjs/resources/PaymentIntents.js.map +1 -1
- package/cjs/resources/PaymentLinks.d.ts +19 -3
- package/cjs/resources/PaymentMethodConfigurations.d.ts +350 -0
- package/cjs/resources/PaymentMethods.d.ts +151 -3
- package/cjs/resources/PaymentMethods.js.map +1 -1
- package/cjs/resources/PaymentRecords.d.ts +82 -0
- package/cjs/resources/Persons.d.ts +2 -2
- package/cjs/resources/Plans.d.ts +16 -0
- package/cjs/resources/Prices.d.ts +52 -0
- package/cjs/resources/Privacy/RedactionJobValidationErrors.d.ts +37 -0
- package/cjs/resources/Privacy/RedactionJobValidationErrors.js +4 -0
- package/cjs/resources/Privacy/RedactionJobValidationErrors.js.map +1 -0
- package/cjs/resources/Privacy/RedactionJobs.d.ts +229 -0
- package/cjs/resources/Privacy/RedactionJobs.js +73 -0
- package/cjs/resources/Privacy/RedactionJobs.js.map +1 -0
- package/cjs/resources/Privacy/index.d.ts +22 -0
- package/cjs/resources/Privacy/index.js +13 -0
- package/cjs/resources/Privacy/index.js.map +1 -0
- package/cjs/resources/ProductCatalog/TrialOffers.d.ts +127 -0
- package/cjs/resources/ProductCatalog/TrialOffers.js +15 -0
- package/cjs/resources/ProductCatalog/TrialOffers.js.map +1 -0
- package/cjs/resources/ProductCatalog/index.d.ts +12 -0
- package/cjs/resources/ProductCatalog/index.js +13 -0
- package/cjs/resources/ProductCatalog/index.js.map +1 -0
- package/cjs/resources/Products.d.ts +42 -0
- package/cjs/resources/PromotionCodes.d.ts +12 -0
- package/cjs/resources/PromotionCodes.js +27 -0
- package/cjs/resources/PromotionCodes.js.map +1 -1
- package/cjs/resources/QuoteLines.d.ts +507 -0
- package/cjs/resources/QuoteLines.js +4 -0
- package/cjs/resources/QuoteLines.js.map +1 -0
- package/cjs/resources/QuotePreviewInvoices.d.ts +1120 -0
- package/cjs/resources/QuotePreviewInvoices.js +4 -0
- package/cjs/resources/QuotePreviewInvoices.js.map +1 -0
- package/cjs/resources/QuotePreviewSubscriptionSchedules.d.ts +737 -0
- package/cjs/resources/QuotePreviewSubscriptionSchedules.js +4 -0
- package/cjs/resources/QuotePreviewSubscriptionSchedules.js.map +1 -0
- package/cjs/resources/Quotes.d.ts +2266 -57
- package/cjs/resources/Quotes.js +1184 -16
- package/cjs/resources/Quotes.js.map +1 -1
- package/cjs/resources/Radar/PaymentEvaluations.d.ts +1 -1
- package/cjs/resources/Refunds.d.ts +11 -0
- package/cjs/resources/Reserve/Holds.d.ts +53 -1
- package/cjs/resources/Reserve/Holds.js +19 -0
- package/cjs/resources/Reserve/Holds.js.map +1 -1
- package/cjs/resources/Reserve/Plans.d.ts +16 -0
- package/cjs/resources/Reserve/Plans.js +11 -0
- package/cjs/resources/Reserve/Plans.js.map +1 -1
- package/cjs/resources/Reserve/Releases.d.ts +41 -1
- package/cjs/resources/Reserve/Releases.js +19 -0
- package/cjs/resources/Reserve/Releases.js.map +1 -1
- package/cjs/resources/Reserve/index.d.ts +14 -3
- package/cjs/resources/Reserve/index.js +10 -2
- package/cjs/resources/Reserve/index.js.map +1 -1
- package/cjs/resources/SetupAttempts.d.ts +26 -1
- package/cjs/resources/SetupIntents.d.ts +330 -11
- package/cjs/resources/SharedPayment/GrantedTokens.d.ts +1095 -0
- package/cjs/resources/SharedPayment/GrantedTokens.js +15 -0
- package/cjs/resources/SharedPayment/GrantedTokens.js.map +1 -0
- package/cjs/resources/SharedPayment/IssuedTokens.d.ts +308 -0
- package/cjs/resources/SharedPayment/IssuedTokens.js +27 -0
- package/cjs/resources/SharedPayment/IssuedTokens.js.map +1 -0
- package/cjs/resources/SharedPayment/index.d.ts +19 -0
- package/cjs/resources/SharedPayment/index.js +15 -0
- package/cjs/resources/SharedPayment/index.js.map +1 -0
- package/cjs/resources/Sources.d.ts +16 -1
- package/cjs/resources/SubscriptionItems.d.ts +143 -0
- package/cjs/resources/SubscriptionSchedules.d.ts +1152 -0
- package/cjs/resources/SubscriptionSchedules.js +6 -0
- package/cjs/resources/SubscriptionSchedules.js.map +1 -1
- package/cjs/resources/Subscriptions.d.ts +571 -6
- package/cjs/resources/Subscriptions.js +145 -0
- package/cjs/resources/Subscriptions.js.map +1 -1
- package/cjs/resources/Tax/CalculationLineItems.d.ts +6 -2
- package/cjs/resources/Tax/Calculations.d.ts +7 -3
- package/cjs/resources/Tax/Forms.d.ts +230 -0
- package/cjs/resources/Tax/Forms.js +32 -0
- package/cjs/resources/Tax/Forms.js.map +1 -0
- package/cjs/resources/Tax/Locations.d.ts +108 -0
- package/cjs/resources/Tax/Locations.js +33 -0
- package/cjs/resources/Tax/Locations.js.map +1 -0
- package/cjs/resources/Tax/Registrations.d.ts +138 -2
- package/cjs/resources/Tax/Transactions.d.ts +2 -2
- package/cjs/resources/Tax/index.d.ts +27 -13
- package/cjs/resources/Tax/index.js +4 -0
- package/cjs/resources/Tax/index.js.map +1 -1
- package/cjs/resources/TaxCodes.d.ts +15 -0
- package/cjs/resources/Terminal/Configurations.d.ts +27 -0
- package/cjs/resources/Terminal/ReaderCollectedData.d.ts +52 -0
- package/cjs/resources/Terminal/ReaderCollectedData.js +15 -0
- package/cjs/resources/Terminal/ReaderCollectedData.js.map +1 -0
- package/cjs/resources/Terminal/Readers.d.ts +17 -1
- package/cjs/resources/Terminal/index.d.ts +5 -0
- package/cjs/resources/Terminal/index.js +2 -0
- package/cjs/resources/Terminal/index.js.map +1 -1
- package/cjs/resources/TestHelpers/ConfirmationTokens.d.ts +78 -1
- package/cjs/resources/TestHelpers/SharedPayment/GrantedTokens.d.ts +68 -0
- package/cjs/resources/TestHelpers/SharedPayment/GrantedTokens.js +21 -0
- package/cjs/resources/TestHelpers/SharedPayment/GrantedTokens.js.map +1 -0
- package/cjs/resources/TestHelpers/SharedPayment/index.d.ts +8 -0
- package/cjs/resources/TestHelpers/SharedPayment/index.js +13 -0
- package/cjs/resources/TestHelpers/SharedPayment/index.js.map +1 -0
- package/cjs/resources/TestHelpers/Treasury/ReceivedCredits.d.ts +22 -0
- package/cjs/resources/TestHelpers/Treasury/ReceivedDebits.d.ts +22 -0
- package/cjs/resources/TestHelpers/index.d.ts +3 -0
- package/cjs/resources/TestHelpers/index.js +6 -4
- package/cjs/resources/TestHelpers/index.js.map +1 -1
- package/cjs/resources/Transfers.d.ts +8 -0
- package/cjs/resources/Treasury/FinancialAccountFeatures.d.ts +5 -0
- package/cjs/resources/Treasury/FinancialAccounts.d.ts +34 -1
- package/cjs/resources/Treasury/OutboundPayments.d.ts +8 -0
- package/cjs/resources/Treasury/OutboundTransfers.d.ts +44 -0
- package/cjs/resources/Treasury/ReceivedCredits.d.ts +22 -0
- package/cjs/resources/Treasury/ReceivedDebits.d.ts +26 -0
- package/cjs/resources/V2/Billing/BillSettingVersions.d.ts +75 -0
- package/cjs/resources/V2/Billing/BillSettingVersions.js +4 -0
- package/cjs/resources/V2/Billing/BillSettingVersions.js.map +1 -0
- package/cjs/resources/V2/Billing/BillSettings/Versions.d.ts +33 -0
- package/cjs/resources/V2/Billing/BillSettings/Versions.js +23 -0
- package/cjs/resources/V2/Billing/BillSettings/Versions.js.map +1 -0
- package/cjs/resources/V2/Billing/BillSettings.d.ts +284 -0
- package/cjs/resources/V2/Billing/BillSettings.js +41 -0
- package/cjs/resources/V2/Billing/BillSettings.js.map +1 -0
- package/cjs/resources/V2/Billing/Cadences.d.ts +951 -0
- package/cjs/resources/V2/Billing/Cadences.js +198 -0
- package/cjs/resources/V2/Billing/Cadences.js.map +1 -0
- package/cjs/resources/V2/Billing/CollectionSettingVersions.d.ts +240 -0
- package/cjs/resources/V2/Billing/CollectionSettingVersions.js +4 -0
- package/cjs/resources/V2/Billing/CollectionSettingVersions.js.map +1 -0
- package/cjs/resources/V2/Billing/CollectionSettings/Versions.d.ts +33 -0
- package/cjs/resources/V2/Billing/CollectionSettings/Versions.js +70 -0
- package/cjs/resources/V2/Billing/CollectionSettings/Versions.js.map +1 -0
- package/cjs/resources/V2/Billing/CollectionSettings.d.ts +779 -0
- package/cjs/resources/V2/Billing/CollectionSettings.js +166 -0
- package/cjs/resources/V2/Billing/CollectionSettings.js.map +1 -0
- package/cjs/resources/V2/Billing/Profiles.d.ts +166 -0
- package/cjs/resources/V2/Billing/Profiles.js +35 -0
- package/cjs/resources/V2/Billing/Profiles.js.map +1 -0
- package/cjs/resources/V2/Billing/index.d.ts +45 -6
- package/cjs/resources/V2/Billing/index.js +8 -0
- package/cjs/resources/V2/Billing/index.js.map +1 -1
- package/cjs/resources/V2/Core/AccountLinks.d.ts +4 -4
- package/cjs/resources/V2/Core/AccountTokens.d.ts +10 -0
- package/cjs/resources/V2/Core/Accounts.d.ts +1177 -167
- package/cjs/resources/V2/Core/BatchJobs.d.ts +373 -0
- package/cjs/resources/V2/Core/BatchJobs.js +225 -0
- package/cjs/resources/V2/Core/BatchJobs.js.map +1 -0
- package/cjs/resources/V2/Core/Events.d.ts +1123 -4
- package/cjs/resources/V2/Core/Vault/GbBankAccounts.d.ts +285 -0
- package/cjs/resources/V2/Core/Vault/GbBankAccounts.js +54 -0
- package/cjs/resources/V2/Core/Vault/GbBankAccounts.js.map +1 -0
- package/cjs/resources/V2/Core/Vault/UsBankAccounts.d.ts +254 -0
- package/cjs/resources/V2/Core/Vault/UsBankAccounts.js +62 -0
- package/cjs/resources/V2/Core/Vault/UsBankAccounts.js.map +1 -0
- package/cjs/resources/V2/Core/Vault/index.d.ts +28 -0
- package/cjs/resources/V2/Core/Vault/index.js +15 -0
- package/cjs/resources/V2/Core/Vault/index.js.map +1 -0
- package/cjs/resources/V2/Core/index.d.ts +19 -9
- package/cjs/resources/V2/Core/index.js +4 -0
- package/cjs/resources/V2/Core/index.js.map +1 -1
- package/cjs/resources/V2/Data/Reporting/QueryRuns.d.ts +156 -0
- package/cjs/resources/V2/Data/Reporting/QueryRuns.js +46 -0
- package/cjs/resources/V2/Data/Reporting/QueryRuns.js.map +1 -0
- package/cjs/resources/V2/Data/Reporting/index.d.ts +13 -0
- package/cjs/resources/V2/Data/Reporting/index.js +13 -0
- package/cjs/resources/V2/Data/Reporting/index.js.map +1 -0
- package/cjs/resources/V2/Data/index.d.ts +10 -0
- package/cjs/resources/V2/Data/index.js +13 -0
- package/cjs/resources/V2/Data/index.js.map +1 -0
- package/cjs/resources/V2/EventMisc.d.ts +0 -0
- package/cjs/resources/V2/EventMisc.js +2 -0
- package/cjs/resources/V2/EventMisc.js.map +1 -0
- package/cjs/resources/V2/Extend/WorkflowRuns.d.ts +166 -0
- package/cjs/resources/V2/Extend/WorkflowRuns.js +23 -0
- package/cjs/resources/V2/Extend/WorkflowRuns.js.map +1 -0
- package/cjs/resources/V2/Extend/Workflows.d.ts +123 -0
- package/cjs/resources/V2/Extend/Workflows.js +30 -0
- package/cjs/resources/V2/Extend/Workflows.js.map +1 -0
- package/cjs/resources/V2/Extend/index.d.ts +20 -0
- package/cjs/resources/V2/Extend/index.js +15 -0
- package/cjs/resources/V2/Extend/index.js.map +1 -0
- package/cjs/resources/V2/FinancialAddressCreditSimulations.d.ts +14 -0
- package/cjs/resources/V2/FinancialAddressCreditSimulations.js +4 -0
- package/cjs/resources/V2/FinancialAddressCreditSimulations.js.map +1 -0
- package/cjs/resources/V2/FinancialAddressGeneratedMicrodeposits.d.ts +19 -0
- package/cjs/resources/V2/FinancialAddressGeneratedMicrodeposits.js +4 -0
- package/cjs/resources/V2/FinancialAddressGeneratedMicrodeposits.js.map +1 -0
- package/cjs/resources/V2/Iam/ActivityLogs.d.ts +214 -0
- package/cjs/resources/V2/Iam/ActivityLogs.js +23 -0
- package/cjs/resources/V2/Iam/ActivityLogs.js.map +1 -0
- package/cjs/resources/V2/Iam/index.d.ts +13 -0
- package/cjs/resources/V2/Iam/index.js +13 -0
- package/cjs/resources/V2/Iam/index.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/Adjustments.d.ts +135 -0
- package/cjs/resources/V2/MoneyManagement/Adjustments.js +23 -0
- package/cjs/resources/V2/MoneyManagement/Adjustments.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/FinancialAccounts.d.ts +244 -0
- package/cjs/resources/V2/MoneyManagement/FinancialAccounts.js +44 -0
- package/cjs/resources/V2/MoneyManagement/FinancialAccounts.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/FinancialAddresses.d.ts +215 -0
- package/cjs/resources/V2/MoneyManagement/FinancialAddresses.js +31 -0
- package/cjs/resources/V2/MoneyManagement/FinancialAddresses.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/InboundTransfers.d.ts +254 -0
- package/cjs/resources/V2/MoneyManagement/InboundTransfers.js +30 -0
- package/cjs/resources/V2/MoneyManagement/InboundTransfers.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/OutboundPaymentQuotes.d.ts +212 -0
- package/cjs/resources/V2/MoneyManagement/OutboundPaymentQuotes.js +22 -0
- package/cjs/resources/V2/MoneyManagement/OutboundPaymentQuotes.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/OutboundPayments.d.ts +388 -0
- package/cjs/resources/V2/MoneyManagement/OutboundPayments.js +41 -0
- package/cjs/resources/V2/MoneyManagement/OutboundPayments.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/OutboundSetupIntents.d.ts +300 -0
- package/cjs/resources/V2/MoneyManagement/OutboundSetupIntents.js +49 -0
- package/cjs/resources/V2/MoneyManagement/OutboundSetupIntents.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/OutboundTransfers.d.ts +330 -0
- package/cjs/resources/V2/MoneyManagement/OutboundTransfers.js +39 -0
- package/cjs/resources/V2/MoneyManagement/OutboundTransfers.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/PayoutMethods.d.ts +243 -0
- package/cjs/resources/V2/MoneyManagement/PayoutMethods.js +44 -0
- package/cjs/resources/V2/MoneyManagement/PayoutMethods.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/PayoutMethodsBankAccountSpec.d.ts +96 -0
- package/cjs/resources/V2/MoneyManagement/PayoutMethodsBankAccountSpec.js +17 -0
- package/cjs/resources/V2/MoneyManagement/PayoutMethodsBankAccountSpec.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/ReceivedCredits.d.ts +295 -0
- package/cjs/resources/V2/MoneyManagement/ReceivedCredits.js +23 -0
- package/cjs/resources/V2/MoneyManagement/ReceivedCredits.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/ReceivedDebits.d.ts +161 -0
- package/cjs/resources/V2/MoneyManagement/ReceivedDebits.js +23 -0
- package/cjs/resources/V2/MoneyManagement/ReceivedDebits.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/TransactionEntries.d.ts +165 -0
- package/cjs/resources/V2/MoneyManagement/TransactionEntries.js +23 -0
- package/cjs/resources/V2/MoneyManagement/TransactionEntries.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/Transactions.d.ts +196 -0
- package/cjs/resources/V2/MoneyManagement/Transactions.js +23 -0
- package/cjs/resources/V2/MoneyManagement/Transactions.js.map +1 -0
- package/cjs/resources/V2/MoneyManagement/index.d.ts +104 -0
- package/cjs/resources/V2/MoneyManagement/index.js +39 -0
- package/cjs/resources/V2/MoneyManagement/index.js.map +1 -0
- package/cjs/resources/V2/Network/BusinessProfiles.d.ts +96 -0
- package/cjs/resources/V2/Network/BusinessProfiles.js +21 -0
- package/cjs/resources/V2/Network/BusinessProfiles.js.map +1 -0
- package/cjs/resources/V2/Network/index.d.ts +13 -0
- package/cjs/resources/V2/Network/index.js +13 -0
- package/cjs/resources/V2/Network/index.js.map +1 -0
- package/cjs/resources/V2/OrchestratedCommerce/Agreements.d.ts +147 -0
- package/cjs/resources/V2/OrchestratedCommerce/Agreements.js +41 -0
- package/cjs/resources/V2/OrchestratedCommerce/Agreements.js.map +1 -0
- package/cjs/resources/V2/OrchestratedCommerce/index.d.ts +16 -0
- package/cjs/resources/V2/OrchestratedCommerce/index.js +13 -0
- package/cjs/resources/V2/OrchestratedCommerce/index.js.map +1 -0
- package/cjs/resources/V2/TestHelpers/FinancialAddresses.d.ts +44 -0
- package/cjs/resources/V2/TestHelpers/FinancialAddresses.js +23 -0
- package/cjs/resources/V2/TestHelpers/FinancialAddresses.js.map +1 -0
- package/cjs/resources/V2/TestHelpers/index.d.ts +8 -0
- package/cjs/resources/V2/TestHelpers/index.js +13 -0
- package/cjs/resources/V2/TestHelpers/index.js.map +1 -0
- package/cjs/resources/V2/index.d.ts +27 -0
- package/cjs/resources/V2/index.js +14 -0
- package/cjs/resources/V2/index.js.map +1 -1
- package/cjs/resources/WebhookEndpoints.d.ts +2 -2
- package/cjs/resources.d.ts +10 -0
- package/cjs/resources.js +146 -10
- package/cjs/resources.js.map +1 -1
- package/cjs/stripe.core.d.ts +61 -24
- package/cjs/stripe.core.js +55 -31
- package/cjs/stripe.core.js.map +1 -1
- package/esm/Error.d.ts +50 -0
- package/esm/Error.js +109 -0
- package/esm/Error.js.map +1 -1
- package/esm/RequestSender.d.ts +0 -1
- package/esm/RequestSender.js +0 -8
- package/esm/RequestSender.js.map +1 -1
- package/esm/StripeEventNotificationHandler.d.ts +19 -0
- package/esm/StripeEventNotificationHandler.js +144 -0
- package/esm/StripeEventNotificationHandler.js.map +1 -0
- package/esm/Types.d.ts +4 -2
- package/esm/Types.js.map +1 -1
- package/esm/apiVersion.d.ts +1 -2
- package/esm/apiVersion.js +1 -2
- package/esm/apiVersion.js.map +1 -1
- package/esm/resources/AccountLinks.d.ts +1 -1
- package/esm/resources/AccountNotices.d.ts +140 -0
- package/esm/resources/AccountNotices.js +25 -0
- package/esm/resources/AccountNotices.js.map +1 -0
- package/esm/resources/AccountSessions.d.ts +262 -0
- package/esm/resources/AccountSessions.js.map +1 -1
- package/esm/resources/Accounts.d.ts +827 -3
- package/esm/resources/Accounts.js +14 -0
- package/esm/resources/Accounts.js.map +1 -1
- package/esm/resources/Balance.d.ts +67 -0
- package/esm/resources/BankAccounts.d.ts +2 -2
- package/esm/resources/Billing/AlertTriggereds.d.ts +2 -1
- package/esm/resources/Billing/Analytics/MeterUsage.d.ts +84 -0
- package/esm/resources/Billing/Analytics/MeterUsage.js +11 -0
- package/esm/resources/Billing/Analytics/MeterUsage.js.map +1 -0
- package/esm/resources/Billing/Analytics/MeterUsageRows.d.ts +32 -0
- package/esm/resources/Billing/Analytics/MeterUsageRows.js +3 -0
- package/esm/resources/Billing/Analytics/MeterUsageRows.js.map +1 -0
- package/esm/resources/Billing/Analytics/index.d.ts +15 -0
- package/esm/resources/Billing/Analytics/index.js +9 -0
- package/esm/resources/Billing/Analytics/index.js.map +1 -0
- package/esm/resources/Billing/index.d.ts +3 -0
- package/esm/resources/Billing/index.js +2 -0
- package/esm/resources/Billing/index.js.map +1 -1
- package/esm/resources/Capabilities.d.ts +2 -2
- package/esm/resources/Capital/FinancingOffers.d.ts +191 -0
- package/esm/resources/Capital/FinancingOffers.js +26 -0
- package/esm/resources/Capital/FinancingOffers.js.map +1 -0
- package/esm/resources/Capital/FinancingSummary.d.ts +98 -0
- package/esm/resources/Capital/FinancingSummary.js +11 -0
- package/esm/resources/Capital/FinancingSummary.js.map +1 -0
- package/esm/resources/Capital/FinancingTransactions.d.ts +143 -0
- package/esm/resources/Capital/FinancingTransactions.js +20 -0
- package/esm/resources/Capital/FinancingTransactions.js.map +1 -0
- package/esm/resources/Capital/index.d.ts +25 -0
- package/esm/resources/Capital/index.js +13 -0
- package/esm/resources/Capital/index.js.map +1 -0
- package/esm/resources/Cards.d.ts +4 -0
- package/esm/resources/Charges.d.ts +3064 -70
- package/esm/resources/Checkout/Sessions.d.ts +390 -4
- package/esm/resources/ConfirmationTokens.d.ts +67 -1
- package/esm/resources/Coupons.d.ts +53 -0
- package/esm/resources/Coupons.js +13 -0
- package/esm/resources/Coupons.js.map +1 -1
- package/esm/resources/CreditNoteLineItems.d.ts +15 -1
- package/esm/resources/CreditNotes.d.ts +1 -1
- package/esm/resources/CustomerSessions.d.ts +68 -0
- package/esm/resources/Customers.d.ts +7 -1
- package/esm/resources/Customers.js +14 -0
- package/esm/resources/Customers.js.map +1 -1
- package/esm/resources/Disputes.d.ts +29 -0
- package/esm/resources/Events.d.ts +547 -2
- package/esm/resources/ExternalAccounts.d.ts +212 -1
- package/esm/resources/ExternalAccounts.js +42 -1
- package/esm/resources/ExternalAccounts.js.map +1 -1
- package/esm/resources/FinancialConnections/AccountInferredBalances.d.ts +24 -0
- package/esm/resources/FinancialConnections/AccountInferredBalances.js +3 -0
- package/esm/resources/FinancialConnections/AccountInferredBalances.js.map +1 -0
- package/esm/resources/FinancialConnections/Accounts.d.ts +74 -4
- package/esm/resources/FinancialConnections/Accounts.js +8 -0
- package/esm/resources/FinancialConnections/Accounts.js.map +1 -1
- package/esm/resources/FinancialConnections/Authorizations.d.ts +87 -0
- package/esm/resources/FinancialConnections/Authorizations.js +11 -0
- package/esm/resources/FinancialConnections/Authorizations.js.map +1 -0
- package/esm/resources/FinancialConnections/Institutions.d.ts +101 -0
- package/esm/resources/FinancialConnections/Institutions.js +19 -0
- package/esm/resources/FinancialConnections/Institutions.js.map +1 -0
- package/esm/resources/FinancialConnections/Sessions.d.ts +155 -7
- package/esm/resources/FinancialConnections/index.d.ts +21 -6
- package/esm/resources/FinancialConnections/index.js +4 -0
- package/esm/resources/FinancialConnections/index.js.map +1 -1
- package/esm/resources/FxQuotes.d.ts +212 -0
- package/esm/resources/FxQuotes.js +25 -0
- package/esm/resources/FxQuotes.js.map +1 -0
- package/esm/resources/InvoiceItems.d.ts +85 -0
- package/esm/resources/InvoiceItems.js.map +1 -1
- package/esm/resources/InvoiceLineItems.d.ts +40 -2
- package/esm/resources/Invoices.d.ts +1337 -19
- package/esm/resources/Invoices.js +41 -0
- package/esm/resources/Invoices.js.map +1 -1
- package/esm/resources/Issuing/Cardholders.d.ts +2 -1
- package/esm/resources/Issuing/CreditUnderwritingRecords.d.ts +640 -0
- package/esm/resources/Issuing/CreditUnderwritingRecords.js +43 -0
- package/esm/resources/Issuing/CreditUnderwritingRecords.js.map +1 -0
- package/esm/resources/Issuing/DisputeSettlementDetails.d.ts +95 -0
- package/esm/resources/Issuing/DisputeSettlementDetails.js +19 -0
- package/esm/resources/Issuing/DisputeSettlementDetails.js.map +1 -0
- package/esm/resources/Issuing/FraudLiabilityDebits.d.ts +68 -0
- package/esm/resources/Issuing/FraudLiabilityDebits.js +19 -0
- package/esm/resources/Issuing/FraudLiabilityDebits.js.map +1 -0
- package/esm/resources/Issuing/Settlements.d.ts +85 -0
- package/esm/resources/Issuing/Settlements.js +3 -0
- package/esm/resources/Issuing/Settlements.js.map +1 -0
- package/esm/resources/Issuing/Transactions.d.ts +9 -0
- package/esm/resources/Issuing/Transactions.js.map +1 -1
- package/esm/resources/Issuing/index.d.ts +47 -22
- package/esm/resources/Issuing/index.js +6 -0
- package/esm/resources/Issuing/index.js.map +1 -1
- package/esm/resources/LineItems.d.ts +29 -2
- package/esm/resources/Mandates.d.ts +33 -1
- package/esm/resources/Mandates.js +8 -0
- package/esm/resources/Mandates.js.map +1 -1
- package/esm/resources/Margins.d.ts +115 -0
- package/esm/resources/Margins.js +31 -0
- package/esm/resources/Margins.js.map +1 -0
- package/esm/resources/Orders.d.ts +4693 -0
- package/esm/resources/Orders.js +453 -0
- package/esm/resources/Orders.js.map +1 -0
- package/esm/resources/PaymentAttemptRecords.d.ts +82 -0
- package/esm/resources/PaymentIntents.d.ts +13239 -2321
- package/esm/resources/PaymentIntents.js +27 -0
- package/esm/resources/PaymentIntents.js.map +1 -1
- package/esm/resources/PaymentLinks.d.ts +19 -3
- package/esm/resources/PaymentMethodConfigurations.d.ts +350 -0
- package/esm/resources/PaymentMethods.d.ts +151 -3
- package/esm/resources/PaymentMethods.js.map +1 -1
- package/esm/resources/PaymentRecords.d.ts +82 -0
- package/esm/resources/Persons.d.ts +2 -2
- package/esm/resources/Plans.d.ts +16 -0
- package/esm/resources/Prices.d.ts +52 -0
- package/esm/resources/Privacy/RedactionJobValidationErrors.d.ts +37 -0
- package/esm/resources/Privacy/RedactionJobValidationErrors.js +3 -0
- package/esm/resources/Privacy/RedactionJobValidationErrors.js.map +1 -0
- package/esm/resources/Privacy/RedactionJobs.d.ts +229 -0
- package/esm/resources/Privacy/RedactionJobs.js +69 -0
- package/esm/resources/Privacy/RedactionJobs.js.map +1 -0
- package/esm/resources/Privacy/index.d.ts +22 -0
- package/esm/resources/Privacy/index.js +9 -0
- package/esm/resources/Privacy/index.js.map +1 -0
- package/esm/resources/ProductCatalog/TrialOffers.d.ts +127 -0
- package/esm/resources/ProductCatalog/TrialOffers.js +11 -0
- package/esm/resources/ProductCatalog/TrialOffers.js.map +1 -0
- package/esm/resources/ProductCatalog/index.d.ts +12 -0
- package/esm/resources/ProductCatalog/index.js +9 -0
- package/esm/resources/ProductCatalog/index.js.map +1 -0
- package/esm/resources/Products.d.ts +42 -0
- package/esm/resources/PromotionCodes.d.ts +12 -0
- package/esm/resources/PromotionCodes.js +27 -0
- package/esm/resources/PromotionCodes.js.map +1 -1
- package/esm/resources/QuoteLines.d.ts +507 -0
- package/esm/resources/QuoteLines.js +3 -0
- package/esm/resources/QuoteLines.js.map +1 -0
- package/esm/resources/QuotePreviewInvoices.d.ts +1120 -0
- package/esm/resources/QuotePreviewInvoices.js +3 -0
- package/esm/resources/QuotePreviewInvoices.js.map +1 -0
- package/esm/resources/QuotePreviewSubscriptionSchedules.d.ts +737 -0
- package/esm/resources/QuotePreviewSubscriptionSchedules.js +3 -0
- package/esm/resources/QuotePreviewSubscriptionSchedules.js.map +1 -0
- package/esm/resources/Quotes.d.ts +2266 -57
- package/esm/resources/Quotes.js +1184 -16
- package/esm/resources/Quotes.js.map +1 -1
- package/esm/resources/Radar/PaymentEvaluations.d.ts +1 -1
- package/esm/resources/Refunds.d.ts +11 -0
- package/esm/resources/Reserve/Holds.d.ts +53 -1
- package/esm/resources/Reserve/Holds.js +17 -1
- package/esm/resources/Reserve/Holds.js.map +1 -1
- package/esm/resources/Reserve/Plans.d.ts +16 -0
- package/esm/resources/Reserve/Plans.js +9 -1
- package/esm/resources/Reserve/Plans.js.map +1 -1
- package/esm/resources/Reserve/Releases.d.ts +41 -1
- package/esm/resources/Reserve/Releases.js +17 -1
- package/esm/resources/Reserve/Releases.js.map +1 -1
- package/esm/resources/Reserve/index.d.ts +14 -3
- package/esm/resources/Reserve/index.js +10 -2
- package/esm/resources/Reserve/index.js.map +1 -1
- package/esm/resources/SetupAttempts.d.ts +26 -1
- package/esm/resources/SetupIntents.d.ts +330 -11
- package/esm/resources/SharedPayment/GrantedTokens.d.ts +1095 -0
- package/esm/resources/SharedPayment/GrantedTokens.js +11 -0
- package/esm/resources/SharedPayment/GrantedTokens.js.map +1 -0
- package/esm/resources/SharedPayment/IssuedTokens.d.ts +308 -0
- package/esm/resources/SharedPayment/IssuedTokens.js +23 -0
- package/esm/resources/SharedPayment/IssuedTokens.js.map +1 -0
- package/esm/resources/SharedPayment/index.d.ts +19 -0
- package/esm/resources/SharedPayment/index.js +11 -0
- package/esm/resources/SharedPayment/index.js.map +1 -0
- package/esm/resources/Sources.d.ts +16 -1
- package/esm/resources/SubscriptionItems.d.ts +143 -0
- package/esm/resources/SubscriptionSchedules.d.ts +1152 -0
- package/esm/resources/SubscriptionSchedules.js +6 -0
- package/esm/resources/SubscriptionSchedules.js.map +1 -1
- package/esm/resources/Subscriptions.d.ts +571 -6
- package/esm/resources/Subscriptions.js +145 -0
- package/esm/resources/Subscriptions.js.map +1 -1
- package/esm/resources/Tax/CalculationLineItems.d.ts +6 -2
- package/esm/resources/Tax/Calculations.d.ts +7 -3
- package/esm/resources/Tax/Forms.d.ts +230 -0
- package/esm/resources/Tax/Forms.js +28 -0
- package/esm/resources/Tax/Forms.js.map +1 -0
- package/esm/resources/Tax/Locations.d.ts +108 -0
- package/esm/resources/Tax/Locations.js +29 -0
- package/esm/resources/Tax/Locations.js.map +1 -0
- package/esm/resources/Tax/Registrations.d.ts +138 -2
- package/esm/resources/Tax/Transactions.d.ts +2 -2
- package/esm/resources/Tax/index.d.ts +27 -13
- package/esm/resources/Tax/index.js +4 -0
- package/esm/resources/Tax/index.js.map +1 -1
- package/esm/resources/TaxCodes.d.ts +15 -0
- package/esm/resources/Terminal/Configurations.d.ts +27 -0
- package/esm/resources/Terminal/ReaderCollectedData.d.ts +52 -0
- package/esm/resources/Terminal/ReaderCollectedData.js +11 -0
- package/esm/resources/Terminal/ReaderCollectedData.js.map +1 -0
- package/esm/resources/Terminal/Readers.d.ts +17 -1
- package/esm/resources/Terminal/index.d.ts +5 -0
- package/esm/resources/Terminal/index.js +2 -0
- package/esm/resources/Terminal/index.js.map +1 -1
- package/esm/resources/TestHelpers/ConfirmationTokens.d.ts +78 -1
- package/esm/resources/TestHelpers/SharedPayment/GrantedTokens.d.ts +68 -0
- package/esm/resources/TestHelpers/SharedPayment/GrantedTokens.js +17 -0
- package/esm/resources/TestHelpers/SharedPayment/GrantedTokens.js.map +1 -0
- package/esm/resources/TestHelpers/SharedPayment/index.d.ts +8 -0
- package/esm/resources/TestHelpers/SharedPayment/index.js +9 -0
- package/esm/resources/TestHelpers/SharedPayment/index.js.map +1 -0
- package/esm/resources/TestHelpers/Treasury/ReceivedCredits.d.ts +22 -0
- package/esm/resources/TestHelpers/Treasury/ReceivedDebits.d.ts +22 -0
- package/esm/resources/TestHelpers/index.d.ts +3 -0
- package/esm/resources/TestHelpers/index.js +2 -0
- package/esm/resources/TestHelpers/index.js.map +1 -1
- package/esm/resources/Transfers.d.ts +8 -0
- package/esm/resources/Treasury/FinancialAccountFeatures.d.ts +5 -0
- package/esm/resources/Treasury/FinancialAccounts.d.ts +34 -1
- package/esm/resources/Treasury/OutboundPayments.d.ts +8 -0
- package/esm/resources/Treasury/OutboundTransfers.d.ts +44 -0
- package/esm/resources/Treasury/ReceivedCredits.d.ts +22 -0
- package/esm/resources/Treasury/ReceivedDebits.d.ts +26 -0
- package/esm/resources/V2/Billing/BillSettingVersions.d.ts +75 -0
- package/esm/resources/V2/Billing/BillSettingVersions.js +3 -0
- package/esm/resources/V2/Billing/BillSettingVersions.js.map +1 -0
- package/esm/resources/V2/Billing/BillSettings/Versions.d.ts +33 -0
- package/esm/resources/V2/Billing/BillSettings/Versions.js +19 -0
- package/esm/resources/V2/Billing/BillSettings/Versions.js.map +1 -0
- package/esm/resources/V2/Billing/BillSettings.d.ts +284 -0
- package/esm/resources/V2/Billing/BillSettings.js +37 -0
- package/esm/resources/V2/Billing/BillSettings.js.map +1 -0
- package/esm/resources/V2/Billing/Cadences.d.ts +951 -0
- package/esm/resources/V2/Billing/Cadences.js +194 -0
- package/esm/resources/V2/Billing/Cadences.js.map +1 -0
- package/esm/resources/V2/Billing/CollectionSettingVersions.d.ts +240 -0
- package/esm/resources/V2/Billing/CollectionSettingVersions.js +3 -0
- package/esm/resources/V2/Billing/CollectionSettingVersions.js.map +1 -0
- package/esm/resources/V2/Billing/CollectionSettings/Versions.d.ts +33 -0
- package/esm/resources/V2/Billing/CollectionSettings/Versions.js +66 -0
- package/esm/resources/V2/Billing/CollectionSettings/Versions.js.map +1 -0
- package/esm/resources/V2/Billing/CollectionSettings.d.ts +779 -0
- package/esm/resources/V2/Billing/CollectionSettings.js +162 -0
- package/esm/resources/V2/Billing/CollectionSettings.js.map +1 -0
- package/esm/resources/V2/Billing/Profiles.d.ts +166 -0
- package/esm/resources/V2/Billing/Profiles.js +31 -0
- package/esm/resources/V2/Billing/Profiles.js.map +1 -0
- package/esm/resources/V2/Billing/index.d.ts +45 -6
- package/esm/resources/V2/Billing/index.js +8 -0
- package/esm/resources/V2/Billing/index.js.map +1 -1
- package/esm/resources/V2/Core/AccountLinks.d.ts +4 -4
- package/esm/resources/V2/Core/AccountTokens.d.ts +10 -0
- package/esm/resources/V2/Core/Accounts.d.ts +1177 -167
- package/esm/resources/V2/Core/BatchJobs.d.ts +373 -0
- package/esm/resources/V2/Core/BatchJobs.js +221 -0
- package/esm/resources/V2/Core/BatchJobs.js.map +1 -0
- package/esm/resources/V2/Core/Events.d.ts +1123 -4
- package/esm/resources/V2/Core/Vault/GbBankAccounts.d.ts +285 -0
- package/esm/resources/V2/Core/Vault/GbBankAccounts.js +50 -0
- package/esm/resources/V2/Core/Vault/GbBankAccounts.js.map +1 -0
- package/esm/resources/V2/Core/Vault/UsBankAccounts.d.ts +254 -0
- package/esm/resources/V2/Core/Vault/UsBankAccounts.js +58 -0
- package/esm/resources/V2/Core/Vault/UsBankAccounts.js.map +1 -0
- package/esm/resources/V2/Core/Vault/index.d.ts +28 -0
- package/esm/resources/V2/Core/Vault/index.js +11 -0
- package/esm/resources/V2/Core/Vault/index.js.map +1 -0
- package/esm/resources/V2/Core/index.d.ts +19 -9
- package/esm/resources/V2/Core/index.js +4 -0
- package/esm/resources/V2/Core/index.js.map +1 -1
- package/esm/resources/V2/Data/Reporting/QueryRuns.d.ts +156 -0
- package/esm/resources/V2/Data/Reporting/QueryRuns.js +42 -0
- package/esm/resources/V2/Data/Reporting/QueryRuns.js.map +1 -0
- package/esm/resources/V2/Data/Reporting/index.d.ts +13 -0
- package/esm/resources/V2/Data/Reporting/index.js +9 -0
- package/esm/resources/V2/Data/Reporting/index.js.map +1 -0
- package/esm/resources/V2/Data/index.d.ts +10 -0
- package/esm/resources/V2/Data/index.js +9 -0
- package/esm/resources/V2/Data/index.js.map +1 -0
- package/esm/resources/V2/EventMisc.d.ts +0 -0
- package/esm/resources/V2/EventMisc.js +2 -0
- package/esm/resources/V2/EventMisc.js.map +1 -0
- package/esm/resources/V2/Extend/WorkflowRuns.d.ts +166 -0
- package/esm/resources/V2/Extend/WorkflowRuns.js +19 -0
- package/esm/resources/V2/Extend/WorkflowRuns.js.map +1 -0
- package/esm/resources/V2/Extend/Workflows.d.ts +123 -0
- package/esm/resources/V2/Extend/Workflows.js +26 -0
- package/esm/resources/V2/Extend/Workflows.js.map +1 -0
- package/esm/resources/V2/Extend/index.d.ts +20 -0
- package/esm/resources/V2/Extend/index.js +11 -0
- package/esm/resources/V2/Extend/index.js.map +1 -0
- package/esm/resources/V2/FinancialAddressCreditSimulations.d.ts +14 -0
- package/esm/resources/V2/FinancialAddressCreditSimulations.js +3 -0
- package/esm/resources/V2/FinancialAddressCreditSimulations.js.map +1 -0
- package/esm/resources/V2/FinancialAddressGeneratedMicrodeposits.d.ts +19 -0
- package/esm/resources/V2/FinancialAddressGeneratedMicrodeposits.js +3 -0
- package/esm/resources/V2/FinancialAddressGeneratedMicrodeposits.js.map +1 -0
- package/esm/resources/V2/Iam/ActivityLogs.d.ts +214 -0
- package/esm/resources/V2/Iam/ActivityLogs.js +19 -0
- package/esm/resources/V2/Iam/ActivityLogs.js.map +1 -0
- package/esm/resources/V2/Iam/index.d.ts +13 -0
- package/esm/resources/V2/Iam/index.js +9 -0
- package/esm/resources/V2/Iam/index.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/Adjustments.d.ts +135 -0
- package/esm/resources/V2/MoneyManagement/Adjustments.js +19 -0
- package/esm/resources/V2/MoneyManagement/Adjustments.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/FinancialAccounts.d.ts +244 -0
- package/esm/resources/V2/MoneyManagement/FinancialAccounts.js +40 -0
- package/esm/resources/V2/MoneyManagement/FinancialAccounts.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/FinancialAddresses.d.ts +215 -0
- package/esm/resources/V2/MoneyManagement/FinancialAddresses.js +27 -0
- package/esm/resources/V2/MoneyManagement/FinancialAddresses.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/InboundTransfers.d.ts +254 -0
- package/esm/resources/V2/MoneyManagement/InboundTransfers.js +26 -0
- package/esm/resources/V2/MoneyManagement/InboundTransfers.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/OutboundPaymentQuotes.d.ts +212 -0
- package/esm/resources/V2/MoneyManagement/OutboundPaymentQuotes.js +18 -0
- package/esm/resources/V2/MoneyManagement/OutboundPaymentQuotes.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/OutboundPayments.d.ts +388 -0
- package/esm/resources/V2/MoneyManagement/OutboundPayments.js +37 -0
- package/esm/resources/V2/MoneyManagement/OutboundPayments.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/OutboundSetupIntents.d.ts +300 -0
- package/esm/resources/V2/MoneyManagement/OutboundSetupIntents.js +45 -0
- package/esm/resources/V2/MoneyManagement/OutboundSetupIntents.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/OutboundTransfers.d.ts +330 -0
- package/esm/resources/V2/MoneyManagement/OutboundTransfers.js +35 -0
- package/esm/resources/V2/MoneyManagement/OutboundTransfers.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/PayoutMethods.d.ts +243 -0
- package/esm/resources/V2/MoneyManagement/PayoutMethods.js +40 -0
- package/esm/resources/V2/MoneyManagement/PayoutMethods.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/PayoutMethodsBankAccountSpec.d.ts +96 -0
- package/esm/resources/V2/MoneyManagement/PayoutMethodsBankAccountSpec.js +13 -0
- package/esm/resources/V2/MoneyManagement/PayoutMethodsBankAccountSpec.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/ReceivedCredits.d.ts +295 -0
- package/esm/resources/V2/MoneyManagement/ReceivedCredits.js +19 -0
- package/esm/resources/V2/MoneyManagement/ReceivedCredits.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/ReceivedDebits.d.ts +161 -0
- package/esm/resources/V2/MoneyManagement/ReceivedDebits.js +19 -0
- package/esm/resources/V2/MoneyManagement/ReceivedDebits.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/TransactionEntries.d.ts +165 -0
- package/esm/resources/V2/MoneyManagement/TransactionEntries.js +19 -0
- package/esm/resources/V2/MoneyManagement/TransactionEntries.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/Transactions.d.ts +196 -0
- package/esm/resources/V2/MoneyManagement/Transactions.js +19 -0
- package/esm/resources/V2/MoneyManagement/Transactions.js.map +1 -0
- package/esm/resources/V2/MoneyManagement/index.d.ts +104 -0
- package/esm/resources/V2/MoneyManagement/index.js +35 -0
- package/esm/resources/V2/MoneyManagement/index.js.map +1 -0
- package/esm/resources/V2/Network/BusinessProfiles.d.ts +96 -0
- package/esm/resources/V2/Network/BusinessProfiles.js +17 -0
- package/esm/resources/V2/Network/BusinessProfiles.js.map +1 -0
- package/esm/resources/V2/Network/index.d.ts +13 -0
- package/esm/resources/V2/Network/index.js +9 -0
- package/esm/resources/V2/Network/index.js.map +1 -0
- package/esm/resources/V2/OrchestratedCommerce/Agreements.d.ts +147 -0
- package/esm/resources/V2/OrchestratedCommerce/Agreements.js +37 -0
- package/esm/resources/V2/OrchestratedCommerce/Agreements.js.map +1 -0
- package/esm/resources/V2/OrchestratedCommerce/index.d.ts +16 -0
- package/esm/resources/V2/OrchestratedCommerce/index.js +9 -0
- package/esm/resources/V2/OrchestratedCommerce/index.js.map +1 -0
- package/esm/resources/V2/TestHelpers/FinancialAddresses.d.ts +44 -0
- package/esm/resources/V2/TestHelpers/FinancialAddresses.js +19 -0
- package/esm/resources/V2/TestHelpers/FinancialAddresses.js.map +1 -0
- package/esm/resources/V2/TestHelpers/index.d.ts +8 -0
- package/esm/resources/V2/TestHelpers/index.js +9 -0
- package/esm/resources/V2/TestHelpers/index.js.map +1 -0
- package/esm/resources/V2/index.d.ts +27 -0
- package/esm/resources/V2/index.js +14 -0
- package/esm/resources/V2/index.js.map +1 -1
- package/esm/resources/WebhookEndpoints.d.ts +2 -2
- package/esm/resources.d.ts +10 -0
- package/esm/resources.js +131 -0
- package/esm/resources.js.map +1 -1
- package/esm/stripe.core.d.ts +61 -24
- package/esm/stripe.core.js +25 -1
- package/esm/stripe.core.js.map +1 -1
- package/esm/stripe.esm.node.d.ts +62 -24
- package/esm/stripe.esm.node.js +25 -1
- package/esm/stripe.esm.node.js.map +1 -1
- package/package.json +1 -1
|
@@ -10,6 +10,7 @@ import { Price, DeletedPrice } from './Prices.js';
|
|
|
10
10
|
import { Coupon } from './Coupons.js';
|
|
11
11
|
import { PromotionCode } from './PromotionCodes.js';
|
|
12
12
|
import { Plan, DeletedPlan } from './Plans.js';
|
|
13
|
+
import { Invoice } from './Invoices.js';
|
|
13
14
|
import * as TestHelpers from './TestHelpers/index.js';
|
|
14
15
|
import { Emptyable, MetadataParam, Decimal, PaginationParams, RangeQueryParam, Metadata } from '../shared.js';
|
|
15
16
|
import { RequestOptions, ApiListPromise, Response } from '../lib.js';
|
|
@@ -30,6 +31,10 @@ export declare class SubscriptionScheduleResource extends StripeResource {
|
|
|
30
31
|
* Updates an existing subscription schedule.
|
|
31
32
|
*/
|
|
32
33
|
update(id: string, params?: SubscriptionScheduleUpdateParams, options?: RequestOptions): Promise<Response<SubscriptionSchedule>>;
|
|
34
|
+
/**
|
|
35
|
+
* Amends an existing subscription schedule.
|
|
36
|
+
*/
|
|
37
|
+
amend(id: string, params?: SubscriptionScheduleAmendParams, options?: RequestOptions): Promise<Response<SubscriptionSchedule>>;
|
|
33
38
|
/**
|
|
34
39
|
* Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active.
|
|
35
40
|
*/
|
|
@@ -52,6 +57,10 @@ export interface SubscriptionSchedule {
|
|
|
52
57
|
* ID of the Connect Application that created the schedule.
|
|
53
58
|
*/
|
|
54
59
|
application: string | Application | DeletedApplication | null;
|
|
60
|
+
/**
|
|
61
|
+
* Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
|
62
|
+
*/
|
|
63
|
+
billing_behavior?: SubscriptionSchedule.BillingBehavior;
|
|
55
64
|
/**
|
|
56
65
|
* The billing mode of the subscription.
|
|
57
66
|
*/
|
|
@@ -85,6 +94,10 @@ export interface SubscriptionSchedule {
|
|
|
85
94
|
* Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
|
|
86
95
|
*/
|
|
87
96
|
end_behavior: SubscriptionSchedule.EndBehavior;
|
|
97
|
+
/**
|
|
98
|
+
* Details of the most recent price migration that failed for the subscription schedule.
|
|
99
|
+
*/
|
|
100
|
+
last_price_migration_error?: SubscriptionSchedule.LastPriceMigrationError | null;
|
|
88
101
|
/**
|
|
89
102
|
* If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`.
|
|
90
103
|
*/
|
|
@@ -97,6 +110,10 @@ export interface SubscriptionSchedule {
|
|
|
97
110
|
* Configuration for the subscription schedule's phases.
|
|
98
111
|
*/
|
|
99
112
|
phases: Array<SubscriptionSchedule.Phase>;
|
|
113
|
+
/**
|
|
114
|
+
* Time period and invoice for a Subscription billed in advance.
|
|
115
|
+
*/
|
|
116
|
+
prebilling?: SubscriptionSchedule.Prebilling | null;
|
|
100
117
|
/**
|
|
101
118
|
* Time at which the subscription schedule was released. Measured in seconds since the Unix epoch.
|
|
102
119
|
*/
|
|
@@ -119,6 +136,7 @@ export interface SubscriptionSchedule {
|
|
|
119
136
|
test_clock: string | TestHelpers.TestClock | null;
|
|
120
137
|
}
|
|
121
138
|
export declare namespace SubscriptionSchedule {
|
|
139
|
+
type BillingBehavior = 'prorate_on_next_phase' | 'prorate_up_front';
|
|
122
140
|
interface BillingMode {
|
|
123
141
|
/**
|
|
124
142
|
* Configure behavior for flexible billing mode
|
|
@@ -180,6 +198,20 @@ export declare namespace SubscriptionSchedule {
|
|
|
180
198
|
transfer_data: DefaultSettings.TransferData | null;
|
|
181
199
|
}
|
|
182
200
|
type EndBehavior = 'cancel' | 'none' | 'release' | 'renew';
|
|
201
|
+
interface LastPriceMigrationError {
|
|
202
|
+
/**
|
|
203
|
+
* The time at which the price migration encountered an error.
|
|
204
|
+
*/
|
|
205
|
+
errored_at: number;
|
|
206
|
+
/**
|
|
207
|
+
* The involved price pairs in each failed transition.
|
|
208
|
+
*/
|
|
209
|
+
failed_transitions: Array<LastPriceMigrationError.FailedTransition>;
|
|
210
|
+
/**
|
|
211
|
+
* The type of error encountered by the price migration.
|
|
212
|
+
*/
|
|
213
|
+
type: 'price_uniqueness_violation';
|
|
214
|
+
}
|
|
183
215
|
interface Phase {
|
|
184
216
|
/**
|
|
185
217
|
* A list of prices and quantities that will generate invoice items appended to the next invoice for this phase.
|
|
@@ -242,6 +274,10 @@ export declare namespace SubscriptionSchedule {
|
|
|
242
274
|
* The account (if any) the charge was made on behalf of for charges associated with the schedule's subscription. See the Connect documentation for details.
|
|
243
275
|
*/
|
|
244
276
|
on_behalf_of: string | Account | null;
|
|
277
|
+
/**
|
|
278
|
+
* If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://docs.stripe.com/billing/subscriptions/pause-payment).
|
|
279
|
+
*/
|
|
280
|
+
pause_collection?: Phase.PauseCollection | null;
|
|
245
281
|
/**
|
|
246
282
|
* When transitioning phases, controls how prorations are handled (if any). Possible values are `create_prorations`, `none`, and `always_invoice`.
|
|
247
283
|
*/
|
|
@@ -254,10 +290,36 @@ export declare namespace SubscriptionSchedule {
|
|
|
254
290
|
* The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.
|
|
255
291
|
*/
|
|
256
292
|
transfer_data: Phase.TransferData | null;
|
|
293
|
+
/**
|
|
294
|
+
* Specify behavior of the trial when crossing schedule phase boundaries
|
|
295
|
+
*/
|
|
296
|
+
trial_continuation?: Phase.TrialContinuation | null;
|
|
257
297
|
/**
|
|
258
298
|
* When the trial ends within the phase.
|
|
259
299
|
*/
|
|
260
300
|
trial_end: number | null;
|
|
301
|
+
/**
|
|
302
|
+
* Settings related to any trials on the subscription during this phase.
|
|
303
|
+
*/
|
|
304
|
+
trial_settings?: Phase.TrialSettings | null;
|
|
305
|
+
}
|
|
306
|
+
interface Prebilling {
|
|
307
|
+
/**
|
|
308
|
+
* ID of the prebilling invoice.
|
|
309
|
+
*/
|
|
310
|
+
invoice: string | Invoice;
|
|
311
|
+
/**
|
|
312
|
+
* The end of the last period for which the invoice pre-bills.
|
|
313
|
+
*/
|
|
314
|
+
period_end: number;
|
|
315
|
+
/**
|
|
316
|
+
* The start of the first period for which the invoice pre-bills.
|
|
317
|
+
*/
|
|
318
|
+
period_start: number;
|
|
319
|
+
/**
|
|
320
|
+
* Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period.
|
|
321
|
+
*/
|
|
322
|
+
update_behavior?: Prebilling.UpdateBehavior;
|
|
261
323
|
}
|
|
262
324
|
type Status = 'active' | 'canceled' | 'completed' | 'not_started' | 'released';
|
|
263
325
|
namespace BillingMode {
|
|
@@ -351,6 +413,18 @@ export declare namespace SubscriptionSchedule {
|
|
|
351
413
|
}
|
|
352
414
|
}
|
|
353
415
|
}
|
|
416
|
+
namespace LastPriceMigrationError {
|
|
417
|
+
interface FailedTransition {
|
|
418
|
+
/**
|
|
419
|
+
* The original price to be migrated.
|
|
420
|
+
*/
|
|
421
|
+
source_price: string;
|
|
422
|
+
/**
|
|
423
|
+
* The intended resulting price of the migration.
|
|
424
|
+
*/
|
|
425
|
+
target_price: string;
|
|
426
|
+
}
|
|
427
|
+
}
|
|
354
428
|
namespace Phase {
|
|
355
429
|
interface AddInvoiceItem {
|
|
356
430
|
/**
|
|
@@ -414,6 +488,10 @@ export declare namespace SubscriptionSchedule {
|
|
|
414
488
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
415
489
|
*/
|
|
416
490
|
discount: string | Discount | null;
|
|
491
|
+
/**
|
|
492
|
+
* Details to determine how long the discount should be applied for.
|
|
493
|
+
*/
|
|
494
|
+
discount_end?: Discount.DiscountEnd | null;
|
|
417
495
|
/**
|
|
418
496
|
* ID of the promotion code to create a new discount for.
|
|
419
497
|
*/
|
|
@@ -462,6 +540,20 @@ export declare namespace SubscriptionSchedule {
|
|
|
462
540
|
* The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.
|
|
463
541
|
*/
|
|
464
542
|
tax_rates?: Array<TaxRate> | null;
|
|
543
|
+
/**
|
|
544
|
+
* Options that configure the trial on the subscription item.
|
|
545
|
+
*/
|
|
546
|
+
trial?: Item.Trial | null;
|
|
547
|
+
/**
|
|
548
|
+
* The ID of the trial offer to apply to the configuration item.
|
|
549
|
+
*/
|
|
550
|
+
trial_offer?: string | null;
|
|
551
|
+
}
|
|
552
|
+
interface PauseCollection {
|
|
553
|
+
/**
|
|
554
|
+
* The payment collection behavior for this subscription while paused.
|
|
555
|
+
*/
|
|
556
|
+
behavior: PauseCollection.Behavior;
|
|
465
557
|
}
|
|
466
558
|
type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
|
|
467
559
|
interface TransferData {
|
|
@@ -474,6 +566,13 @@ export declare namespace SubscriptionSchedule {
|
|
|
474
566
|
*/
|
|
475
567
|
destination: string | Account;
|
|
476
568
|
}
|
|
569
|
+
type TrialContinuation = 'continue' | 'none';
|
|
570
|
+
interface TrialSettings {
|
|
571
|
+
/**
|
|
572
|
+
* Defines how the subscription should behave when a trial ends.
|
|
573
|
+
*/
|
|
574
|
+
end_behavior: TrialSettings.EndBehavior | null;
|
|
575
|
+
}
|
|
477
576
|
namespace AddInvoiceItem {
|
|
478
577
|
interface Discount {
|
|
479
578
|
/**
|
|
@@ -484,6 +583,10 @@ export declare namespace SubscriptionSchedule {
|
|
|
484
583
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
485
584
|
*/
|
|
486
585
|
discount: string | Discount | null;
|
|
586
|
+
/**
|
|
587
|
+
* Details to determine how long the discount should be applied for.
|
|
588
|
+
*/
|
|
589
|
+
discount_end?: Discount.DiscountEnd | null;
|
|
487
590
|
/**
|
|
488
591
|
* ID of the promotion code to create a new discount for.
|
|
489
592
|
*/
|
|
@@ -493,6 +596,18 @@ export declare namespace SubscriptionSchedule {
|
|
|
493
596
|
end: Period.End;
|
|
494
597
|
start: Period.Start;
|
|
495
598
|
}
|
|
599
|
+
namespace Discount {
|
|
600
|
+
interface DiscountEnd {
|
|
601
|
+
/**
|
|
602
|
+
* The discount end timestamp.
|
|
603
|
+
*/
|
|
604
|
+
timestamp: number | null;
|
|
605
|
+
/**
|
|
606
|
+
* The discount end type.
|
|
607
|
+
*/
|
|
608
|
+
type: 'timestamp';
|
|
609
|
+
}
|
|
610
|
+
}
|
|
496
611
|
namespace Period {
|
|
497
612
|
interface End {
|
|
498
613
|
/**
|
|
@@ -537,6 +652,18 @@ export declare namespace SubscriptionSchedule {
|
|
|
537
652
|
type Type = 'account' | 'self';
|
|
538
653
|
}
|
|
539
654
|
}
|
|
655
|
+
namespace Discount {
|
|
656
|
+
interface DiscountEnd {
|
|
657
|
+
/**
|
|
658
|
+
* The discount end timestamp.
|
|
659
|
+
*/
|
|
660
|
+
timestamp: number | null;
|
|
661
|
+
/**
|
|
662
|
+
* The discount end type.
|
|
663
|
+
*/
|
|
664
|
+
type: 'timestamp';
|
|
665
|
+
}
|
|
666
|
+
}
|
|
540
667
|
namespace InvoiceSettings {
|
|
541
668
|
interface Issuer {
|
|
542
669
|
/**
|
|
@@ -568,15 +695,65 @@ export declare namespace SubscriptionSchedule {
|
|
|
568
695
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
569
696
|
*/
|
|
570
697
|
discount: string | Discount | null;
|
|
698
|
+
/**
|
|
699
|
+
* Details to determine how long the discount should be applied for.
|
|
700
|
+
*/
|
|
701
|
+
discount_end?: Discount.DiscountEnd | null;
|
|
571
702
|
/**
|
|
572
703
|
* ID of the promotion code to create a new discount for.
|
|
573
704
|
*/
|
|
574
705
|
promotion_code: string | PromotionCode | null;
|
|
575
706
|
}
|
|
707
|
+
interface Trial {
|
|
708
|
+
/**
|
|
709
|
+
* List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial.
|
|
710
|
+
*/
|
|
711
|
+
converts_to?: Array<string> | null;
|
|
712
|
+
/**
|
|
713
|
+
* Determines the type of trial for this item.
|
|
714
|
+
*/
|
|
715
|
+
type: Trial.Type;
|
|
716
|
+
}
|
|
717
|
+
namespace Discount {
|
|
718
|
+
interface DiscountEnd {
|
|
719
|
+
/**
|
|
720
|
+
* The discount end timestamp.
|
|
721
|
+
*/
|
|
722
|
+
timestamp: number | null;
|
|
723
|
+
/**
|
|
724
|
+
* The discount end type.
|
|
725
|
+
*/
|
|
726
|
+
type: 'timestamp';
|
|
727
|
+
}
|
|
728
|
+
}
|
|
729
|
+
namespace Trial {
|
|
730
|
+
type Type = 'free' | 'paid';
|
|
731
|
+
}
|
|
732
|
+
}
|
|
733
|
+
namespace PauseCollection {
|
|
734
|
+
type Behavior = 'keep_as_draft' | 'mark_uncollectible' | 'void';
|
|
735
|
+
}
|
|
736
|
+
namespace TrialSettings {
|
|
737
|
+
interface EndBehavior {
|
|
738
|
+
/**
|
|
739
|
+
* Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
|
|
740
|
+
*/
|
|
741
|
+
prorate_up_front: EndBehavior.ProrateUpFront | null;
|
|
742
|
+
}
|
|
743
|
+
namespace EndBehavior {
|
|
744
|
+
type ProrateUpFront = 'defer' | 'include';
|
|
745
|
+
}
|
|
576
746
|
}
|
|
577
747
|
}
|
|
748
|
+
namespace Prebilling {
|
|
749
|
+
type UpdateBehavior = 'prebill' | 'reset';
|
|
750
|
+
}
|
|
578
751
|
}
|
|
579
752
|
export interface SubscriptionScheduleCreateParams {
|
|
753
|
+
/**
|
|
754
|
+
* Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
|
755
|
+
*/
|
|
756
|
+
billing_behavior?: SubscriptionScheduleCreateParams.BillingBehavior;
|
|
580
757
|
/**
|
|
581
758
|
* Controls how prorations and invoices for subscriptions are calculated and orchestrated.
|
|
582
759
|
*/
|
|
@@ -613,12 +790,17 @@ export interface SubscriptionScheduleCreateParams {
|
|
|
613
790
|
* List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
|
|
614
791
|
*/
|
|
615
792
|
phases?: Array<SubscriptionScheduleCreateParams.Phase>;
|
|
793
|
+
/**
|
|
794
|
+
* If specified, the invoicing for the given billing cycle iterations will be processed now.
|
|
795
|
+
*/
|
|
796
|
+
prebilling?: SubscriptionScheduleCreateParams.Prebilling;
|
|
616
797
|
/**
|
|
617
798
|
* When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on.
|
|
618
799
|
*/
|
|
619
800
|
start_date?: number | 'now';
|
|
620
801
|
}
|
|
621
802
|
export declare namespace SubscriptionScheduleCreateParams {
|
|
803
|
+
type BillingBehavior = 'prorate_on_next_phase' | 'prorate_up_front';
|
|
622
804
|
interface BillingMode {
|
|
623
805
|
/**
|
|
624
806
|
* Configure behavior for flexible billing mode.
|
|
@@ -741,6 +923,10 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
741
923
|
* The account on behalf of which to charge, for each of the associated subscription's invoices.
|
|
742
924
|
*/
|
|
743
925
|
on_behalf_of?: string;
|
|
926
|
+
/**
|
|
927
|
+
* If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://docs.stripe.com/billing/subscriptions/pause-payment).
|
|
928
|
+
*/
|
|
929
|
+
pause_collection?: Phase.PauseCollection;
|
|
744
930
|
/**
|
|
745
931
|
* Controls whether the subscription schedule should create [prorations](https://docs.stripe.com/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://docs.stripe.com/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
|
|
746
932
|
*/
|
|
@@ -753,10 +939,28 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
753
939
|
* If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
|
|
754
940
|
*/
|
|
755
941
|
trial?: boolean;
|
|
942
|
+
/**
|
|
943
|
+
* Specify trial behavior when crossing phase boundaries
|
|
944
|
+
*/
|
|
945
|
+
trial_continuation?: Phase.TrialContinuation;
|
|
756
946
|
/**
|
|
757
947
|
* Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
|
|
758
948
|
*/
|
|
759
949
|
trial_end?: number;
|
|
950
|
+
/**
|
|
951
|
+
* Settings related to subscription trials.
|
|
952
|
+
*/
|
|
953
|
+
trial_settings?: Phase.TrialSettings;
|
|
954
|
+
}
|
|
955
|
+
interface Prebilling {
|
|
956
|
+
/**
|
|
957
|
+
* This is used to determine the number of billing cycles to prebill.
|
|
958
|
+
*/
|
|
959
|
+
iterations: number;
|
|
960
|
+
/**
|
|
961
|
+
* Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
|
|
962
|
+
*/
|
|
963
|
+
update_behavior?: Prebilling.UpdateBehavior;
|
|
760
964
|
}
|
|
761
965
|
namespace BillingMode {
|
|
762
966
|
interface Flexible {
|
|
@@ -914,6 +1118,10 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
914
1118
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
915
1119
|
*/
|
|
916
1120
|
discount?: string;
|
|
1121
|
+
/**
|
|
1122
|
+
* Details to determine how long the discount should be applied for.
|
|
1123
|
+
*/
|
|
1124
|
+
discount_end?: Discount.DiscountEnd;
|
|
917
1125
|
/**
|
|
918
1126
|
* ID of the promotion code to create a new discount for.
|
|
919
1127
|
*/
|
|
@@ -976,6 +1184,20 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
976
1184
|
* A list of [Tax Rate](https://docs.stripe.com/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://docs.stripe.com/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
|
|
977
1185
|
*/
|
|
978
1186
|
tax_rates?: Emptyable<Array<string>>;
|
|
1187
|
+
/**
|
|
1188
|
+
* Options that configure the trial on the subscription item.
|
|
1189
|
+
*/
|
|
1190
|
+
trial?: Item.Trial;
|
|
1191
|
+
/**
|
|
1192
|
+
* The ID of the trial offer to apply to the configuration item.
|
|
1193
|
+
*/
|
|
1194
|
+
trial_offer?: string;
|
|
1195
|
+
}
|
|
1196
|
+
interface PauseCollection {
|
|
1197
|
+
/**
|
|
1198
|
+
* The payment collection behavior for this subscription while paused.
|
|
1199
|
+
*/
|
|
1200
|
+
behavior: PauseCollection.Behavior;
|
|
979
1201
|
}
|
|
980
1202
|
type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
|
|
981
1203
|
interface TransferData {
|
|
@@ -988,6 +1210,13 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
988
1210
|
*/
|
|
989
1211
|
destination: string;
|
|
990
1212
|
}
|
|
1213
|
+
type TrialContinuation = 'continue' | 'none';
|
|
1214
|
+
interface TrialSettings {
|
|
1215
|
+
/**
|
|
1216
|
+
* Defines how the subscription should behave when a trial ends.
|
|
1217
|
+
*/
|
|
1218
|
+
end_behavior?: TrialSettings.EndBehavior;
|
|
1219
|
+
}
|
|
991
1220
|
namespace AddInvoiceItem {
|
|
992
1221
|
interface Discount {
|
|
993
1222
|
/**
|
|
@@ -998,6 +1227,10 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
998
1227
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
999
1228
|
*/
|
|
1000
1229
|
discount?: string;
|
|
1230
|
+
/**
|
|
1231
|
+
* Details to determine how long the discount should be applied for.
|
|
1232
|
+
*/
|
|
1233
|
+
discount_end?: Discount.DiscountEnd;
|
|
1001
1234
|
/**
|
|
1002
1235
|
* ID of the promotion code to create a new discount for.
|
|
1003
1236
|
*/
|
|
@@ -1035,6 +1268,38 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
1035
1268
|
*/
|
|
1036
1269
|
unit_amount_decimal?: Decimal;
|
|
1037
1270
|
}
|
|
1271
|
+
namespace Discount {
|
|
1272
|
+
interface DiscountEnd {
|
|
1273
|
+
/**
|
|
1274
|
+
* Time span for the redeemed discount.
|
|
1275
|
+
*/
|
|
1276
|
+
duration?: DiscountEnd.Duration;
|
|
1277
|
+
/**
|
|
1278
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
1279
|
+
*/
|
|
1280
|
+
timestamp?: number;
|
|
1281
|
+
/**
|
|
1282
|
+
* The type of calculation made to determine when the discount ends.
|
|
1283
|
+
*/
|
|
1284
|
+
type: DiscountEnd.Type;
|
|
1285
|
+
}
|
|
1286
|
+
namespace DiscountEnd {
|
|
1287
|
+
interface Duration {
|
|
1288
|
+
/**
|
|
1289
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
1290
|
+
*/
|
|
1291
|
+
interval: Duration.Interval;
|
|
1292
|
+
/**
|
|
1293
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
1294
|
+
*/
|
|
1295
|
+
interval_count: number;
|
|
1296
|
+
}
|
|
1297
|
+
type Type = 'duration' | 'timestamp';
|
|
1298
|
+
namespace Duration {
|
|
1299
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1300
|
+
}
|
|
1301
|
+
}
|
|
1302
|
+
}
|
|
1038
1303
|
namespace Period {
|
|
1039
1304
|
interface End {
|
|
1040
1305
|
/**
|
|
@@ -1082,6 +1347,38 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
1082
1347
|
type Type = 'account' | 'self';
|
|
1083
1348
|
}
|
|
1084
1349
|
}
|
|
1350
|
+
namespace Discount {
|
|
1351
|
+
interface DiscountEnd {
|
|
1352
|
+
/**
|
|
1353
|
+
* Time span for the redeemed discount.
|
|
1354
|
+
*/
|
|
1355
|
+
duration?: DiscountEnd.Duration;
|
|
1356
|
+
/**
|
|
1357
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
1358
|
+
*/
|
|
1359
|
+
timestamp?: number;
|
|
1360
|
+
/**
|
|
1361
|
+
* The type of calculation made to determine when the discount ends.
|
|
1362
|
+
*/
|
|
1363
|
+
type: DiscountEnd.Type;
|
|
1364
|
+
}
|
|
1365
|
+
namespace DiscountEnd {
|
|
1366
|
+
interface Duration {
|
|
1367
|
+
/**
|
|
1368
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
1369
|
+
*/
|
|
1370
|
+
interval: Duration.Interval;
|
|
1371
|
+
/**
|
|
1372
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
1373
|
+
*/
|
|
1374
|
+
interval_count: number;
|
|
1375
|
+
}
|
|
1376
|
+
type Type = 'duration' | 'timestamp';
|
|
1377
|
+
namespace Duration {
|
|
1378
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1379
|
+
}
|
|
1380
|
+
}
|
|
1381
|
+
}
|
|
1085
1382
|
namespace Duration {
|
|
1086
1383
|
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1087
1384
|
}
|
|
@@ -1116,6 +1413,10 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
1116
1413
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
1117
1414
|
*/
|
|
1118
1415
|
discount?: string;
|
|
1416
|
+
/**
|
|
1417
|
+
* Details to determine how long the discount should be applied for.
|
|
1418
|
+
*/
|
|
1419
|
+
discount_end?: Discount.DiscountEnd;
|
|
1119
1420
|
/**
|
|
1120
1421
|
* ID of the promotion code to create a new discount for.
|
|
1121
1422
|
*/
|
|
@@ -1147,6 +1448,48 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
1147
1448
|
*/
|
|
1148
1449
|
unit_amount_decimal?: Decimal;
|
|
1149
1450
|
}
|
|
1451
|
+
interface Trial {
|
|
1452
|
+
/**
|
|
1453
|
+
* List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
|
1454
|
+
*/
|
|
1455
|
+
converts_to?: Array<string>;
|
|
1456
|
+
/**
|
|
1457
|
+
* Determines the type of trial for this item.
|
|
1458
|
+
*/
|
|
1459
|
+
type: Trial.Type;
|
|
1460
|
+
}
|
|
1461
|
+
namespace Discount {
|
|
1462
|
+
interface DiscountEnd {
|
|
1463
|
+
/**
|
|
1464
|
+
* Time span for the redeemed discount.
|
|
1465
|
+
*/
|
|
1466
|
+
duration?: DiscountEnd.Duration;
|
|
1467
|
+
/**
|
|
1468
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
1469
|
+
*/
|
|
1470
|
+
timestamp?: number;
|
|
1471
|
+
/**
|
|
1472
|
+
* The type of calculation made to determine when the discount ends.
|
|
1473
|
+
*/
|
|
1474
|
+
type: DiscountEnd.Type;
|
|
1475
|
+
}
|
|
1476
|
+
namespace DiscountEnd {
|
|
1477
|
+
interface Duration {
|
|
1478
|
+
/**
|
|
1479
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
1480
|
+
*/
|
|
1481
|
+
interval: Duration.Interval;
|
|
1482
|
+
/**
|
|
1483
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
1484
|
+
*/
|
|
1485
|
+
interval_count: number;
|
|
1486
|
+
}
|
|
1487
|
+
type Type = 'duration' | 'timestamp';
|
|
1488
|
+
namespace Duration {
|
|
1489
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1490
|
+
}
|
|
1491
|
+
}
|
|
1492
|
+
}
|
|
1150
1493
|
namespace PriceData {
|
|
1151
1494
|
interface Recurring {
|
|
1152
1495
|
/**
|
|
@@ -1163,8 +1506,28 @@ export declare namespace SubscriptionScheduleCreateParams {
|
|
|
1163
1506
|
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1164
1507
|
}
|
|
1165
1508
|
}
|
|
1509
|
+
namespace Trial {
|
|
1510
|
+
type Type = 'free' | 'paid';
|
|
1511
|
+
}
|
|
1512
|
+
}
|
|
1513
|
+
namespace PauseCollection {
|
|
1514
|
+
type Behavior = 'keep_as_draft' | 'mark_uncollectible' | 'void';
|
|
1515
|
+
}
|
|
1516
|
+
namespace TrialSettings {
|
|
1517
|
+
interface EndBehavior {
|
|
1518
|
+
/**
|
|
1519
|
+
* Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
|
|
1520
|
+
*/
|
|
1521
|
+
prorate_up_front?: EndBehavior.ProrateUpFront;
|
|
1522
|
+
}
|
|
1523
|
+
namespace EndBehavior {
|
|
1524
|
+
type ProrateUpFront = 'defer' | 'include';
|
|
1525
|
+
}
|
|
1166
1526
|
}
|
|
1167
1527
|
}
|
|
1528
|
+
namespace Prebilling {
|
|
1529
|
+
type UpdateBehavior = 'prebill' | 'reset';
|
|
1530
|
+
}
|
|
1168
1531
|
}
|
|
1169
1532
|
export interface SubscriptionScheduleRetrieveParams {
|
|
1170
1533
|
/**
|
|
@@ -1173,6 +1536,10 @@ export interface SubscriptionScheduleRetrieveParams {
|
|
|
1173
1536
|
expand?: Array<string>;
|
|
1174
1537
|
}
|
|
1175
1538
|
export interface SubscriptionScheduleUpdateParams {
|
|
1539
|
+
/**
|
|
1540
|
+
* Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
|
1541
|
+
*/
|
|
1542
|
+
billing_behavior?: SubscriptionScheduleUpdateParams.BillingBehavior;
|
|
1176
1543
|
/**
|
|
1177
1544
|
* Object representing the subscription schedule's default settings.
|
|
1178
1545
|
*/
|
|
@@ -1193,12 +1560,17 @@ export interface SubscriptionScheduleUpdateParams {
|
|
|
1193
1560
|
* List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
|
|
1194
1561
|
*/
|
|
1195
1562
|
phases?: Array<SubscriptionScheduleUpdateParams.Phase>;
|
|
1563
|
+
/**
|
|
1564
|
+
* If specified, the invoicing for the given billing cycle iterations will be processed now.
|
|
1565
|
+
*/
|
|
1566
|
+
prebilling?: SubscriptionScheduleUpdateParams.Prebilling;
|
|
1196
1567
|
/**
|
|
1197
1568
|
* If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
|
|
1198
1569
|
*/
|
|
1199
1570
|
proration_behavior?: SubscriptionScheduleUpdateParams.ProrationBehavior;
|
|
1200
1571
|
}
|
|
1201
1572
|
export declare namespace SubscriptionScheduleUpdateParams {
|
|
1573
|
+
type BillingBehavior = 'prorate_on_next_phase' | 'prorate_up_front';
|
|
1202
1574
|
interface DefaultSettings {
|
|
1203
1575
|
/**
|
|
1204
1576
|
* A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
|
|
@@ -1311,6 +1683,10 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1311
1683
|
* The account on behalf of which to charge, for each of the associated subscription's invoices.
|
|
1312
1684
|
*/
|
|
1313
1685
|
on_behalf_of?: string;
|
|
1686
|
+
/**
|
|
1687
|
+
* If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://docs.stripe.com/billing/subscriptions/pause-payment).
|
|
1688
|
+
*/
|
|
1689
|
+
pause_collection?: Phase.PauseCollection;
|
|
1314
1690
|
/**
|
|
1315
1691
|
* Controls whether the subscription schedule should create [prorations](https://docs.stripe.com/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. It's different from the request-level [proration_behavior](https://docs.stripe.com/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration (item price, quantity, etc.) of the current phase.
|
|
1316
1692
|
*/
|
|
@@ -1327,10 +1703,28 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1327
1703
|
* If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
|
|
1328
1704
|
*/
|
|
1329
1705
|
trial?: boolean;
|
|
1706
|
+
/**
|
|
1707
|
+
* Specify trial behavior when crossing phase boundaries
|
|
1708
|
+
*/
|
|
1709
|
+
trial_continuation?: Phase.TrialContinuation;
|
|
1330
1710
|
/**
|
|
1331
1711
|
* Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
|
|
1332
1712
|
*/
|
|
1333
1713
|
trial_end?: number | 'now';
|
|
1714
|
+
/**
|
|
1715
|
+
* Settings related to subscription trials.
|
|
1716
|
+
*/
|
|
1717
|
+
trial_settings?: Phase.TrialSettings;
|
|
1718
|
+
}
|
|
1719
|
+
interface Prebilling {
|
|
1720
|
+
/**
|
|
1721
|
+
* This is used to determine the number of billing cycles to prebill.
|
|
1722
|
+
*/
|
|
1723
|
+
iterations: number;
|
|
1724
|
+
/**
|
|
1725
|
+
* Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
|
|
1726
|
+
*/
|
|
1727
|
+
update_behavior?: Prebilling.UpdateBehavior;
|
|
1334
1728
|
}
|
|
1335
1729
|
type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
|
|
1336
1730
|
namespace DefaultSettings {
|
|
@@ -1477,6 +1871,10 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1477
1871
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
1478
1872
|
*/
|
|
1479
1873
|
discount?: string;
|
|
1874
|
+
/**
|
|
1875
|
+
* Details to determine how long the discount should be applied for.
|
|
1876
|
+
*/
|
|
1877
|
+
discount_end?: Discount.DiscountEnd;
|
|
1480
1878
|
/**
|
|
1481
1879
|
* ID of the promotion code to create a new discount for.
|
|
1482
1880
|
*/
|
|
@@ -1539,6 +1937,20 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1539
1937
|
* A list of [Tax Rate](https://docs.stripe.com/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://docs.stripe.com/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
|
|
1540
1938
|
*/
|
|
1541
1939
|
tax_rates?: Emptyable<Array<string>>;
|
|
1940
|
+
/**
|
|
1941
|
+
* Options that configure the trial on the subscription item.
|
|
1942
|
+
*/
|
|
1943
|
+
trial?: Item.Trial;
|
|
1944
|
+
/**
|
|
1945
|
+
* The ID of the trial offer to apply to the configuration item.
|
|
1946
|
+
*/
|
|
1947
|
+
trial_offer?: string;
|
|
1948
|
+
}
|
|
1949
|
+
interface PauseCollection {
|
|
1950
|
+
/**
|
|
1951
|
+
* The payment collection behavior for this subscription while paused.
|
|
1952
|
+
*/
|
|
1953
|
+
behavior: PauseCollection.Behavior;
|
|
1542
1954
|
}
|
|
1543
1955
|
type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
|
|
1544
1956
|
interface TransferData {
|
|
@@ -1551,6 +1963,13 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1551
1963
|
*/
|
|
1552
1964
|
destination: string;
|
|
1553
1965
|
}
|
|
1966
|
+
type TrialContinuation = 'continue' | 'none';
|
|
1967
|
+
interface TrialSettings {
|
|
1968
|
+
/**
|
|
1969
|
+
* Defines how the subscription should behave when a trial ends.
|
|
1970
|
+
*/
|
|
1971
|
+
end_behavior?: TrialSettings.EndBehavior;
|
|
1972
|
+
}
|
|
1554
1973
|
namespace AddInvoiceItem {
|
|
1555
1974
|
interface Discount {
|
|
1556
1975
|
/**
|
|
@@ -1561,6 +1980,10 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1561
1980
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
1562
1981
|
*/
|
|
1563
1982
|
discount?: string;
|
|
1983
|
+
/**
|
|
1984
|
+
* Details to determine how long the discount should be applied for.
|
|
1985
|
+
*/
|
|
1986
|
+
discount_end?: Discount.DiscountEnd;
|
|
1564
1987
|
/**
|
|
1565
1988
|
* ID of the promotion code to create a new discount for.
|
|
1566
1989
|
*/
|
|
@@ -1598,6 +2021,38 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1598
2021
|
*/
|
|
1599
2022
|
unit_amount_decimal?: Decimal;
|
|
1600
2023
|
}
|
|
2024
|
+
namespace Discount {
|
|
2025
|
+
interface DiscountEnd {
|
|
2026
|
+
/**
|
|
2027
|
+
* Time span for the redeemed discount.
|
|
2028
|
+
*/
|
|
2029
|
+
duration?: DiscountEnd.Duration;
|
|
2030
|
+
/**
|
|
2031
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
2032
|
+
*/
|
|
2033
|
+
timestamp?: number;
|
|
2034
|
+
/**
|
|
2035
|
+
* The type of calculation made to determine when the discount ends.
|
|
2036
|
+
*/
|
|
2037
|
+
type: DiscountEnd.Type;
|
|
2038
|
+
}
|
|
2039
|
+
namespace DiscountEnd {
|
|
2040
|
+
interface Duration {
|
|
2041
|
+
/**
|
|
2042
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2043
|
+
*/
|
|
2044
|
+
interval: Duration.Interval;
|
|
2045
|
+
/**
|
|
2046
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2047
|
+
*/
|
|
2048
|
+
interval_count: number;
|
|
2049
|
+
}
|
|
2050
|
+
type Type = 'duration' | 'timestamp';
|
|
2051
|
+
namespace Duration {
|
|
2052
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2053
|
+
}
|
|
2054
|
+
}
|
|
2055
|
+
}
|
|
1601
2056
|
namespace Period {
|
|
1602
2057
|
interface End {
|
|
1603
2058
|
/**
|
|
@@ -1645,6 +2100,38 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1645
2100
|
type Type = 'account' | 'self';
|
|
1646
2101
|
}
|
|
1647
2102
|
}
|
|
2103
|
+
namespace Discount {
|
|
2104
|
+
interface DiscountEnd {
|
|
2105
|
+
/**
|
|
2106
|
+
* Time span for the redeemed discount.
|
|
2107
|
+
*/
|
|
2108
|
+
duration?: DiscountEnd.Duration;
|
|
2109
|
+
/**
|
|
2110
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
2111
|
+
*/
|
|
2112
|
+
timestamp?: number;
|
|
2113
|
+
/**
|
|
2114
|
+
* The type of calculation made to determine when the discount ends.
|
|
2115
|
+
*/
|
|
2116
|
+
type: DiscountEnd.Type;
|
|
2117
|
+
}
|
|
2118
|
+
namespace DiscountEnd {
|
|
2119
|
+
interface Duration {
|
|
2120
|
+
/**
|
|
2121
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2122
|
+
*/
|
|
2123
|
+
interval: Duration.Interval;
|
|
2124
|
+
/**
|
|
2125
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2126
|
+
*/
|
|
2127
|
+
interval_count: number;
|
|
2128
|
+
}
|
|
2129
|
+
type Type = 'duration' | 'timestamp';
|
|
2130
|
+
namespace Duration {
|
|
2131
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2132
|
+
}
|
|
2133
|
+
}
|
|
2134
|
+
}
|
|
1648
2135
|
namespace Duration {
|
|
1649
2136
|
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1650
2137
|
}
|
|
@@ -1679,6 +2166,10 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1679
2166
|
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
1680
2167
|
*/
|
|
1681
2168
|
discount?: string;
|
|
2169
|
+
/**
|
|
2170
|
+
* Details to determine how long the discount should be applied for.
|
|
2171
|
+
*/
|
|
2172
|
+
discount_end?: Discount.DiscountEnd;
|
|
1682
2173
|
/**
|
|
1683
2174
|
* ID of the promotion code to create a new discount for.
|
|
1684
2175
|
*/
|
|
@@ -1710,6 +2201,48 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1710
2201
|
*/
|
|
1711
2202
|
unit_amount_decimal?: Decimal;
|
|
1712
2203
|
}
|
|
2204
|
+
interface Trial {
|
|
2205
|
+
/**
|
|
2206
|
+
* List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
|
2207
|
+
*/
|
|
2208
|
+
converts_to?: Array<string>;
|
|
2209
|
+
/**
|
|
2210
|
+
* Determines the type of trial for this item.
|
|
2211
|
+
*/
|
|
2212
|
+
type: Trial.Type;
|
|
2213
|
+
}
|
|
2214
|
+
namespace Discount {
|
|
2215
|
+
interface DiscountEnd {
|
|
2216
|
+
/**
|
|
2217
|
+
* Time span for the redeemed discount.
|
|
2218
|
+
*/
|
|
2219
|
+
duration?: DiscountEnd.Duration;
|
|
2220
|
+
/**
|
|
2221
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
2222
|
+
*/
|
|
2223
|
+
timestamp?: number;
|
|
2224
|
+
/**
|
|
2225
|
+
* The type of calculation made to determine when the discount ends.
|
|
2226
|
+
*/
|
|
2227
|
+
type: DiscountEnd.Type;
|
|
2228
|
+
}
|
|
2229
|
+
namespace DiscountEnd {
|
|
2230
|
+
interface Duration {
|
|
2231
|
+
/**
|
|
2232
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2233
|
+
*/
|
|
2234
|
+
interval: Duration.Interval;
|
|
2235
|
+
/**
|
|
2236
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2237
|
+
*/
|
|
2238
|
+
interval_count: number;
|
|
2239
|
+
}
|
|
2240
|
+
type Type = 'duration' | 'timestamp';
|
|
2241
|
+
namespace Duration {
|
|
2242
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2243
|
+
}
|
|
2244
|
+
}
|
|
2245
|
+
}
|
|
1713
2246
|
namespace PriceData {
|
|
1714
2247
|
interface Recurring {
|
|
1715
2248
|
/**
|
|
@@ -1726,8 +2259,28 @@ export declare namespace SubscriptionScheduleUpdateParams {
|
|
|
1726
2259
|
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
1727
2260
|
}
|
|
1728
2261
|
}
|
|
2262
|
+
namespace Trial {
|
|
2263
|
+
type Type = 'free' | 'paid';
|
|
2264
|
+
}
|
|
2265
|
+
}
|
|
2266
|
+
namespace PauseCollection {
|
|
2267
|
+
type Behavior = 'keep_as_draft' | 'mark_uncollectible' | 'void';
|
|
2268
|
+
}
|
|
2269
|
+
namespace TrialSettings {
|
|
2270
|
+
interface EndBehavior {
|
|
2271
|
+
/**
|
|
2272
|
+
* Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
|
|
2273
|
+
*/
|
|
2274
|
+
prorate_up_front?: EndBehavior.ProrateUpFront;
|
|
2275
|
+
}
|
|
2276
|
+
namespace EndBehavior {
|
|
2277
|
+
type ProrateUpFront = 'defer' | 'include';
|
|
2278
|
+
}
|
|
1729
2279
|
}
|
|
1730
2280
|
}
|
|
2281
|
+
namespace Prebilling {
|
|
2282
|
+
type UpdateBehavior = 'prebill' | 'reset';
|
|
2283
|
+
}
|
|
1731
2284
|
}
|
|
1732
2285
|
export interface SubscriptionScheduleListParams extends PaginationParams {
|
|
1733
2286
|
/**
|
|
@@ -1763,6 +2316,605 @@ export interface SubscriptionScheduleListParams extends PaginationParams {
|
|
|
1763
2316
|
*/
|
|
1764
2317
|
scheduled?: boolean;
|
|
1765
2318
|
}
|
|
2319
|
+
export interface SubscriptionScheduleAmendParams {
|
|
2320
|
+
/**
|
|
2321
|
+
* Changes to apply to the phases of the subscription schedule, in the order provided.
|
|
2322
|
+
*/
|
|
2323
|
+
amendments?: Array<SubscriptionScheduleAmendParams.Amendment>;
|
|
2324
|
+
/**
|
|
2325
|
+
* Specifies which fields in the response should be expanded.
|
|
2326
|
+
*/
|
|
2327
|
+
expand?: Array<string>;
|
|
2328
|
+
/**
|
|
2329
|
+
* Provide any time periods to bill in advance.
|
|
2330
|
+
*/
|
|
2331
|
+
prebilling?: Emptyable<Array<SubscriptionScheduleAmendParams.Prebilling>>;
|
|
2332
|
+
/**
|
|
2333
|
+
* In cases where the amendment changes the currently active phase,
|
|
2334
|
+
* specifies if and how to prorate at the time of the request.
|
|
2335
|
+
*/
|
|
2336
|
+
proration_behavior?: SubscriptionScheduleAmendParams.ProrationBehavior;
|
|
2337
|
+
/**
|
|
2338
|
+
* Changes to apply to the subscription schedule.
|
|
2339
|
+
*/
|
|
2340
|
+
schedule_settings?: SubscriptionScheduleAmendParams.ScheduleSettings;
|
|
2341
|
+
}
|
|
2342
|
+
export declare namespace SubscriptionScheduleAmendParams {
|
|
2343
|
+
interface Amendment {
|
|
2344
|
+
/**
|
|
2345
|
+
* Details to identify the end of the time range modified by the proposed change. If not supplied, the amendment is considered a point-in-time operation that only affects the exact timestamp at `amendment_start`, and a restricted set of attributes is supported on the amendment.
|
|
2346
|
+
*/
|
|
2347
|
+
amendment_end?: Amendment.AmendmentEnd;
|
|
2348
|
+
/**
|
|
2349
|
+
* Details to identify the earliest timestamp where the proposed change should take effect.
|
|
2350
|
+
*/
|
|
2351
|
+
amendment_start: Amendment.AmendmentStart;
|
|
2352
|
+
/**
|
|
2353
|
+
* For point-in-time amendments (having no `amendment_end`), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the `amendment_start` timestamp.For time-span based amendments (having both `amendment_start` and `amendment_end`), the only value valid is `automatic`, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment.
|
|
2354
|
+
*/
|
|
2355
|
+
billing_cycle_anchor?: Amendment.BillingCycleAnchor;
|
|
2356
|
+
/**
|
|
2357
|
+
* Changes to the coupons being redeemed or discounts being applied during the amendment time span.
|
|
2358
|
+
*/
|
|
2359
|
+
discount_actions?: Array<Amendment.DiscountAction>;
|
|
2360
|
+
/**
|
|
2361
|
+
* Changes to the subscription items during the amendment time span.
|
|
2362
|
+
*/
|
|
2363
|
+
item_actions?: Array<Amendment.ItemAction>;
|
|
2364
|
+
/**
|
|
2365
|
+
* Instructions for how to modify phase metadata
|
|
2366
|
+
*/
|
|
2367
|
+
metadata_actions?: Array<Amendment.MetadataAction>;
|
|
2368
|
+
/**
|
|
2369
|
+
* Changes to how Stripe handles prorations during the amendment time span. Affects if and how prorations are created when a future phase starts. In cases where the amendment changes the currently active phase, it is used to determine whether or how to prorate now, at the time of the request. Also supported as a point-in-time operation when `amendment_end` is `null`.
|
|
2370
|
+
*/
|
|
2371
|
+
proration_behavior?: Amendment.ProrationBehavior;
|
|
2372
|
+
/**
|
|
2373
|
+
* Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
|
|
2374
|
+
*/
|
|
2375
|
+
set_pause_collection?: Amendment.SetPauseCollection;
|
|
2376
|
+
/**
|
|
2377
|
+
* Ends the subscription schedule early as dictated by either the accompanying amendment's start or end.
|
|
2378
|
+
*/
|
|
2379
|
+
set_schedule_end?: Amendment.SetScheduleEnd;
|
|
2380
|
+
/**
|
|
2381
|
+
* Settings related to subscription trials.
|
|
2382
|
+
*/
|
|
2383
|
+
trial_settings?: Amendment.TrialSettings;
|
|
2384
|
+
}
|
|
2385
|
+
interface Prebilling {
|
|
2386
|
+
/**
|
|
2387
|
+
* The beginning of the prebilled time period. The default value is `now`.
|
|
2388
|
+
*/
|
|
2389
|
+
bill_from?: Prebilling.BillFrom;
|
|
2390
|
+
/**
|
|
2391
|
+
* The end of the prebilled time period.
|
|
2392
|
+
*/
|
|
2393
|
+
bill_until?: Prebilling.BillUntil;
|
|
2394
|
+
/**
|
|
2395
|
+
* When the prebilling invoice should be created. The default value is `now`.
|
|
2396
|
+
*/
|
|
2397
|
+
invoice_at?: 'now';
|
|
2398
|
+
/**
|
|
2399
|
+
* Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
|
|
2400
|
+
*/
|
|
2401
|
+
update_behavior?: Prebilling.UpdateBehavior;
|
|
2402
|
+
}
|
|
2403
|
+
type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
|
|
2404
|
+
interface ScheduleSettings {
|
|
2405
|
+
/**
|
|
2406
|
+
* Behavior of the subscription schedule and underlying subscription when it ends.
|
|
2407
|
+
*/
|
|
2408
|
+
end_behavior?: ScheduleSettings.EndBehavior;
|
|
2409
|
+
}
|
|
2410
|
+
namespace Amendment {
|
|
2411
|
+
interface AmendmentEnd {
|
|
2412
|
+
/**
|
|
2413
|
+
* Use the `end` time of a given discount.
|
|
2414
|
+
*/
|
|
2415
|
+
discount_end?: AmendmentEnd.DiscountEnd;
|
|
2416
|
+
/**
|
|
2417
|
+
* Time span for the amendment starting from the `amendment_start`.
|
|
2418
|
+
*/
|
|
2419
|
+
duration?: AmendmentEnd.Duration;
|
|
2420
|
+
/**
|
|
2421
|
+
* A precise Unix timestamp for the amendment to end. Must be after the `amendment_start`.
|
|
2422
|
+
*/
|
|
2423
|
+
timestamp?: number;
|
|
2424
|
+
/**
|
|
2425
|
+
* Select one of three ways to pass the `amendment_end`.
|
|
2426
|
+
*/
|
|
2427
|
+
type: AmendmentEnd.Type;
|
|
2428
|
+
}
|
|
2429
|
+
interface AmendmentStart {
|
|
2430
|
+
/**
|
|
2431
|
+
* Details of another amendment in the same array, immediately after which this amendment should begin.
|
|
2432
|
+
*/
|
|
2433
|
+
amendment_end?: AmendmentStart.AmendmentEnd;
|
|
2434
|
+
/**
|
|
2435
|
+
* Use the `end` time of a given discount.
|
|
2436
|
+
*/
|
|
2437
|
+
discount_end?: AmendmentStart.DiscountEnd;
|
|
2438
|
+
/**
|
|
2439
|
+
* A precise Unix timestamp for the amendment to start.
|
|
2440
|
+
*/
|
|
2441
|
+
timestamp?: number;
|
|
2442
|
+
/**
|
|
2443
|
+
* Select one of three ways to pass the `amendment_start`.
|
|
2444
|
+
*/
|
|
2445
|
+
type: AmendmentStart.Type;
|
|
2446
|
+
}
|
|
2447
|
+
type BillingCycleAnchor = 'amendment_start' | 'automatic';
|
|
2448
|
+
interface DiscountAction {
|
|
2449
|
+
/**
|
|
2450
|
+
* Details of the discount to add.
|
|
2451
|
+
*/
|
|
2452
|
+
add?: DiscountAction.Add;
|
|
2453
|
+
/**
|
|
2454
|
+
* Details of the discount to remove.
|
|
2455
|
+
*/
|
|
2456
|
+
remove?: DiscountAction.Remove;
|
|
2457
|
+
/**
|
|
2458
|
+
* Details of the discount to replace the existing discounts with.
|
|
2459
|
+
*/
|
|
2460
|
+
set?: DiscountAction.Set;
|
|
2461
|
+
/**
|
|
2462
|
+
* Determines the type of discount action.
|
|
2463
|
+
*/
|
|
2464
|
+
type: DiscountAction.Type;
|
|
2465
|
+
}
|
|
2466
|
+
interface ItemAction {
|
|
2467
|
+
/**
|
|
2468
|
+
* Details of the subscription item to add. If an item with the same `price` exists, it will be replaced by this new item. Otherwise, it adds the new item.
|
|
2469
|
+
*/
|
|
2470
|
+
add?: ItemAction.Add;
|
|
2471
|
+
/**
|
|
2472
|
+
* Details of the subscription item to remove.
|
|
2473
|
+
*/
|
|
2474
|
+
remove?: ItemAction.Remove;
|
|
2475
|
+
/**
|
|
2476
|
+
* Details of the subscription item to replace the existing items with. If an item with the `set[price]` already exists, the `items` array is not cleared. Instead, all of the other `set` properties that are passed in this request will replace the existing values for the configuration item.
|
|
2477
|
+
*/
|
|
2478
|
+
set?: ItemAction.Set;
|
|
2479
|
+
/**
|
|
2480
|
+
* Determines the type of item action.
|
|
2481
|
+
*/
|
|
2482
|
+
type: ItemAction.Type;
|
|
2483
|
+
}
|
|
2484
|
+
interface MetadataAction {
|
|
2485
|
+
/**
|
|
2486
|
+
* Key-value pairs to add to schedule phase metadata. These values will merge with existing schedule phase metadata.
|
|
2487
|
+
*/
|
|
2488
|
+
add?: {
|
|
2489
|
+
[key: string]: string;
|
|
2490
|
+
};
|
|
2491
|
+
/**
|
|
2492
|
+
* Keys to remove from schedule phase metadata.
|
|
2493
|
+
*/
|
|
2494
|
+
remove?: Array<string>;
|
|
2495
|
+
/**
|
|
2496
|
+
* Key-value pairs to set as schedule phase metadata. Existing schedule phase metadata will be overwritten.
|
|
2497
|
+
*/
|
|
2498
|
+
set?: Emptyable<{
|
|
2499
|
+
[key: string]: string;
|
|
2500
|
+
}>;
|
|
2501
|
+
/**
|
|
2502
|
+
* Select one of three ways to update phase-level `metadata` on subscription schedules.
|
|
2503
|
+
*/
|
|
2504
|
+
type: MetadataAction.Type;
|
|
2505
|
+
}
|
|
2506
|
+
type ProrationBehavior = 'always_invoice' | 'create_prorations' | 'none';
|
|
2507
|
+
interface SetPauseCollection {
|
|
2508
|
+
/**
|
|
2509
|
+
* Details of the pause_collection behavior to apply to the amendment.
|
|
2510
|
+
*/
|
|
2511
|
+
set?: SetPauseCollection.Set;
|
|
2512
|
+
/**
|
|
2513
|
+
* Determines the type of the pause_collection amendment.
|
|
2514
|
+
*/
|
|
2515
|
+
type: SetPauseCollection.Type;
|
|
2516
|
+
}
|
|
2517
|
+
type SetScheduleEnd = 'amendment_end' | 'amendment_start';
|
|
2518
|
+
interface TrialSettings {
|
|
2519
|
+
/**
|
|
2520
|
+
* Defines how the subscription should behave when a trial ends.
|
|
2521
|
+
*/
|
|
2522
|
+
end_behavior?: TrialSettings.EndBehavior;
|
|
2523
|
+
}
|
|
2524
|
+
namespace AmendmentEnd {
|
|
2525
|
+
interface DiscountEnd {
|
|
2526
|
+
/**
|
|
2527
|
+
* The ID of a specific discount.
|
|
2528
|
+
*/
|
|
2529
|
+
discount: string;
|
|
2530
|
+
}
|
|
2531
|
+
interface Duration {
|
|
2532
|
+
/**
|
|
2533
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2534
|
+
*/
|
|
2535
|
+
interval: Duration.Interval;
|
|
2536
|
+
/**
|
|
2537
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2538
|
+
*/
|
|
2539
|
+
interval_count: number;
|
|
2540
|
+
}
|
|
2541
|
+
type Type = 'discount_end' | 'duration' | 'schedule_end' | 'timestamp' | 'trial_end' | 'trial_start' | 'upcoming_invoice';
|
|
2542
|
+
namespace Duration {
|
|
2543
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2544
|
+
}
|
|
2545
|
+
}
|
|
2546
|
+
namespace AmendmentStart {
|
|
2547
|
+
interface AmendmentEnd {
|
|
2548
|
+
/**
|
|
2549
|
+
* The position of the previous amendment in the `amendments` array after which this amendment should begin. Indexes start from 0 and must be less than the index of the current amendment in the array.
|
|
2550
|
+
*/
|
|
2551
|
+
index: number;
|
|
2552
|
+
}
|
|
2553
|
+
interface DiscountEnd {
|
|
2554
|
+
/**
|
|
2555
|
+
* The ID of a specific discount.
|
|
2556
|
+
*/
|
|
2557
|
+
discount: string;
|
|
2558
|
+
}
|
|
2559
|
+
type Type = 'amendment_end' | 'discount_end' | 'now' | 'schedule_end' | 'timestamp' | 'trial_end' | 'trial_start' | 'upcoming_invoice';
|
|
2560
|
+
}
|
|
2561
|
+
namespace DiscountAction {
|
|
2562
|
+
interface Add {
|
|
2563
|
+
/**
|
|
2564
|
+
* The coupon code to redeem.
|
|
2565
|
+
*/
|
|
2566
|
+
coupon?: string;
|
|
2567
|
+
/**
|
|
2568
|
+
* An ID of an existing discount for a coupon that was already redeemed.
|
|
2569
|
+
*/
|
|
2570
|
+
discount?: string;
|
|
2571
|
+
/**
|
|
2572
|
+
* Details to determine how long the discount should be applied for.
|
|
2573
|
+
*/
|
|
2574
|
+
discount_end?: Add.DiscountEnd;
|
|
2575
|
+
/**
|
|
2576
|
+
* The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
|
|
2577
|
+
*/
|
|
2578
|
+
index?: number;
|
|
2579
|
+
/**
|
|
2580
|
+
* The promotion code to redeem.
|
|
2581
|
+
*/
|
|
2582
|
+
promotion_code?: string;
|
|
2583
|
+
}
|
|
2584
|
+
interface Remove {
|
|
2585
|
+
/**
|
|
2586
|
+
* The coupon code to remove from the `discounts` array.
|
|
2587
|
+
*/
|
|
2588
|
+
coupon?: string;
|
|
2589
|
+
/**
|
|
2590
|
+
* The ID of a discount to remove from the `discounts` array.
|
|
2591
|
+
*/
|
|
2592
|
+
discount?: string;
|
|
2593
|
+
/**
|
|
2594
|
+
* The ID of a promotion code to remove from the `discounts` array.
|
|
2595
|
+
*/
|
|
2596
|
+
promotion_code?: string;
|
|
2597
|
+
}
|
|
2598
|
+
interface Set {
|
|
2599
|
+
/**
|
|
2600
|
+
* The coupon code to replace the `discounts` array with.
|
|
2601
|
+
*/
|
|
2602
|
+
coupon?: string;
|
|
2603
|
+
/**
|
|
2604
|
+
* An ID of an existing discount to replace the `discounts` array with.
|
|
2605
|
+
*/
|
|
2606
|
+
discount?: string;
|
|
2607
|
+
/**
|
|
2608
|
+
* An ID of an existing promotion code to replace the `discounts` array with.
|
|
2609
|
+
*/
|
|
2610
|
+
promotion_code?: string;
|
|
2611
|
+
}
|
|
2612
|
+
type Type = 'add' | 'remove' | 'set';
|
|
2613
|
+
namespace Add {
|
|
2614
|
+
interface DiscountEnd {
|
|
2615
|
+
/**
|
|
2616
|
+
* The type of calculation made to determine when the discount ends.
|
|
2617
|
+
*/
|
|
2618
|
+
type: 'amendment_end';
|
|
2619
|
+
}
|
|
2620
|
+
}
|
|
2621
|
+
}
|
|
2622
|
+
namespace ItemAction {
|
|
2623
|
+
interface Add {
|
|
2624
|
+
/**
|
|
2625
|
+
* The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
|
|
2626
|
+
*/
|
|
2627
|
+
discounts?: Array<Add.Discount>;
|
|
2628
|
+
/**
|
|
2629
|
+
* Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
|
|
2630
|
+
*/
|
|
2631
|
+
metadata?: MetadataParam;
|
|
2632
|
+
/**
|
|
2633
|
+
* The ID of the price object.
|
|
2634
|
+
*/
|
|
2635
|
+
price: string;
|
|
2636
|
+
/**
|
|
2637
|
+
* Quantity for this item.
|
|
2638
|
+
*/
|
|
2639
|
+
quantity?: number;
|
|
2640
|
+
/**
|
|
2641
|
+
* The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
|
|
2642
|
+
*/
|
|
2643
|
+
tax_rates?: Array<string>;
|
|
2644
|
+
/**
|
|
2645
|
+
* Options that configure the trial on the subscription item.
|
|
2646
|
+
*/
|
|
2647
|
+
trial?: Add.Trial;
|
|
2648
|
+
/**
|
|
2649
|
+
* The ID of the trial offer to apply to the configuration item.
|
|
2650
|
+
*/
|
|
2651
|
+
trial_offer?: string;
|
|
2652
|
+
}
|
|
2653
|
+
interface Remove {
|
|
2654
|
+
/**
|
|
2655
|
+
* ID of a price to remove.
|
|
2656
|
+
*/
|
|
2657
|
+
price: string;
|
|
2658
|
+
}
|
|
2659
|
+
interface Set {
|
|
2660
|
+
/**
|
|
2661
|
+
* If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
|
|
2662
|
+
*/
|
|
2663
|
+
discounts?: Array<Set.Discount>;
|
|
2664
|
+
/**
|
|
2665
|
+
* If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
|
|
2666
|
+
*/
|
|
2667
|
+
metadata?: MetadataParam;
|
|
2668
|
+
/**
|
|
2669
|
+
* The ID of the price object.
|
|
2670
|
+
*/
|
|
2671
|
+
price: string;
|
|
2672
|
+
/**
|
|
2673
|
+
* If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
|
|
2674
|
+
*/
|
|
2675
|
+
quantity?: number;
|
|
2676
|
+
/**
|
|
2677
|
+
* If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
|
|
2678
|
+
*/
|
|
2679
|
+
tax_rates?: Array<string>;
|
|
2680
|
+
/**
|
|
2681
|
+
* If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
|
|
2682
|
+
*/
|
|
2683
|
+
trial?: Set.Trial;
|
|
2684
|
+
/**
|
|
2685
|
+
* The ID of the trial offer to apply to the configuration item.
|
|
2686
|
+
*/
|
|
2687
|
+
trial_offer?: string;
|
|
2688
|
+
}
|
|
2689
|
+
type Type = 'add' | 'remove' | 'set';
|
|
2690
|
+
namespace Add {
|
|
2691
|
+
interface Discount {
|
|
2692
|
+
/**
|
|
2693
|
+
* ID of the coupon to create a new discount for.
|
|
2694
|
+
*/
|
|
2695
|
+
coupon?: string;
|
|
2696
|
+
/**
|
|
2697
|
+
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
2698
|
+
*/
|
|
2699
|
+
discount?: string;
|
|
2700
|
+
/**
|
|
2701
|
+
* Details to determine how long the discount should be applied for.
|
|
2702
|
+
*/
|
|
2703
|
+
discount_end?: Discount.DiscountEnd;
|
|
2704
|
+
/**
|
|
2705
|
+
* ID of the promotion code to create a new discount for.
|
|
2706
|
+
*/
|
|
2707
|
+
promotion_code?: string;
|
|
2708
|
+
}
|
|
2709
|
+
interface Trial {
|
|
2710
|
+
/**
|
|
2711
|
+
* List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
|
2712
|
+
*/
|
|
2713
|
+
converts_to?: Array<string>;
|
|
2714
|
+
/**
|
|
2715
|
+
* Determines the type of trial for this item.
|
|
2716
|
+
*/
|
|
2717
|
+
type: Trial.Type;
|
|
2718
|
+
}
|
|
2719
|
+
namespace Discount {
|
|
2720
|
+
interface DiscountEnd {
|
|
2721
|
+
/**
|
|
2722
|
+
* Time span for the redeemed discount.
|
|
2723
|
+
*/
|
|
2724
|
+
duration?: DiscountEnd.Duration;
|
|
2725
|
+
/**
|
|
2726
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
2727
|
+
*/
|
|
2728
|
+
timestamp?: number;
|
|
2729
|
+
/**
|
|
2730
|
+
* The type of calculation made to determine when the discount ends.
|
|
2731
|
+
*/
|
|
2732
|
+
type: DiscountEnd.Type;
|
|
2733
|
+
}
|
|
2734
|
+
namespace DiscountEnd {
|
|
2735
|
+
interface Duration {
|
|
2736
|
+
/**
|
|
2737
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2738
|
+
*/
|
|
2739
|
+
interval: Duration.Interval;
|
|
2740
|
+
/**
|
|
2741
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2742
|
+
*/
|
|
2743
|
+
interval_count: number;
|
|
2744
|
+
}
|
|
2745
|
+
type Type = 'duration' | 'timestamp';
|
|
2746
|
+
namespace Duration {
|
|
2747
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2748
|
+
}
|
|
2749
|
+
}
|
|
2750
|
+
}
|
|
2751
|
+
namespace Trial {
|
|
2752
|
+
type Type = 'free' | 'paid';
|
|
2753
|
+
}
|
|
2754
|
+
}
|
|
2755
|
+
namespace Set {
|
|
2756
|
+
interface Discount {
|
|
2757
|
+
/**
|
|
2758
|
+
* ID of the coupon to create a new discount for.
|
|
2759
|
+
*/
|
|
2760
|
+
coupon?: string;
|
|
2761
|
+
/**
|
|
2762
|
+
* ID of an existing discount on the object (or one of its ancestors) to reuse.
|
|
2763
|
+
*/
|
|
2764
|
+
discount?: string;
|
|
2765
|
+
/**
|
|
2766
|
+
* Details to determine how long the discount should be applied for.
|
|
2767
|
+
*/
|
|
2768
|
+
discount_end?: Discount.DiscountEnd;
|
|
2769
|
+
/**
|
|
2770
|
+
* ID of the promotion code to create a new discount for.
|
|
2771
|
+
*/
|
|
2772
|
+
promotion_code?: string;
|
|
2773
|
+
}
|
|
2774
|
+
interface Trial {
|
|
2775
|
+
/**
|
|
2776
|
+
* List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
|
2777
|
+
*/
|
|
2778
|
+
converts_to?: Array<string>;
|
|
2779
|
+
/**
|
|
2780
|
+
* Determines the type of trial for this item.
|
|
2781
|
+
*/
|
|
2782
|
+
type: Trial.Type;
|
|
2783
|
+
}
|
|
2784
|
+
namespace Discount {
|
|
2785
|
+
interface DiscountEnd {
|
|
2786
|
+
/**
|
|
2787
|
+
* Time span for the redeemed discount.
|
|
2788
|
+
*/
|
|
2789
|
+
duration?: DiscountEnd.Duration;
|
|
2790
|
+
/**
|
|
2791
|
+
* A precise Unix timestamp for the discount to end. Must be in the future.
|
|
2792
|
+
*/
|
|
2793
|
+
timestamp?: number;
|
|
2794
|
+
/**
|
|
2795
|
+
* The type of calculation made to determine when the discount ends.
|
|
2796
|
+
*/
|
|
2797
|
+
type: DiscountEnd.Type;
|
|
2798
|
+
}
|
|
2799
|
+
namespace DiscountEnd {
|
|
2800
|
+
interface Duration {
|
|
2801
|
+
/**
|
|
2802
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2803
|
+
*/
|
|
2804
|
+
interval: Duration.Interval;
|
|
2805
|
+
/**
|
|
2806
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2807
|
+
*/
|
|
2808
|
+
interval_count: number;
|
|
2809
|
+
}
|
|
2810
|
+
type Type = 'duration' | 'timestamp';
|
|
2811
|
+
namespace Duration {
|
|
2812
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2813
|
+
}
|
|
2814
|
+
}
|
|
2815
|
+
}
|
|
2816
|
+
namespace Trial {
|
|
2817
|
+
type Type = 'free' | 'paid';
|
|
2818
|
+
}
|
|
2819
|
+
}
|
|
2820
|
+
}
|
|
2821
|
+
namespace MetadataAction {
|
|
2822
|
+
type Type = 'add' | 'remove' | 'set';
|
|
2823
|
+
}
|
|
2824
|
+
namespace SetPauseCollection {
|
|
2825
|
+
interface Set {
|
|
2826
|
+
/**
|
|
2827
|
+
* The payment collection behavior for this subscription while paused.
|
|
2828
|
+
*/
|
|
2829
|
+
behavior: Set.Behavior;
|
|
2830
|
+
}
|
|
2831
|
+
type Type = 'remove' | 'set';
|
|
2832
|
+
namespace Set {
|
|
2833
|
+
type Behavior = 'keep_as_draft' | 'mark_uncollectible' | 'void';
|
|
2834
|
+
}
|
|
2835
|
+
}
|
|
2836
|
+
namespace TrialSettings {
|
|
2837
|
+
interface EndBehavior {
|
|
2838
|
+
/**
|
|
2839
|
+
* Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
|
|
2840
|
+
*/
|
|
2841
|
+
prorate_up_front?: EndBehavior.ProrateUpFront;
|
|
2842
|
+
}
|
|
2843
|
+
namespace EndBehavior {
|
|
2844
|
+
type ProrateUpFront = 'defer' | 'include';
|
|
2845
|
+
}
|
|
2846
|
+
}
|
|
2847
|
+
}
|
|
2848
|
+
namespace Prebilling {
|
|
2849
|
+
interface BillFrom {
|
|
2850
|
+
/**
|
|
2851
|
+
* Start the prebilled period when a specified amendment begins.
|
|
2852
|
+
*/
|
|
2853
|
+
amendment_start?: BillFrom.AmendmentStart;
|
|
2854
|
+
/**
|
|
2855
|
+
* Start the prebilled period at a precise integer timestamp, starting from the Unix epoch.
|
|
2856
|
+
*/
|
|
2857
|
+
timestamp?: number;
|
|
2858
|
+
/**
|
|
2859
|
+
* Select one of several ways to pass the `bill_from` value.
|
|
2860
|
+
*/
|
|
2861
|
+
type: BillFrom.Type;
|
|
2862
|
+
}
|
|
2863
|
+
interface BillUntil {
|
|
2864
|
+
/**
|
|
2865
|
+
* End the prebilled period when a specified amendment ends.
|
|
2866
|
+
*/
|
|
2867
|
+
amendment_end?: BillUntil.AmendmentEnd;
|
|
2868
|
+
/**
|
|
2869
|
+
* Time span for prebilling, starting from `bill_from`.
|
|
2870
|
+
*/
|
|
2871
|
+
duration?: BillUntil.Duration;
|
|
2872
|
+
/**
|
|
2873
|
+
* End the prebilled period at a precise integer timestamp, starting from the Unix epoch.
|
|
2874
|
+
*/
|
|
2875
|
+
timestamp?: number;
|
|
2876
|
+
/**
|
|
2877
|
+
* Select one of several ways to pass the `bill_until` value.
|
|
2878
|
+
*/
|
|
2879
|
+
type: BillUntil.Type;
|
|
2880
|
+
}
|
|
2881
|
+
type UpdateBehavior = 'prebill' | 'reset';
|
|
2882
|
+
namespace BillFrom {
|
|
2883
|
+
interface AmendmentStart {
|
|
2884
|
+
/**
|
|
2885
|
+
* The position of the amendment in the `amendments` array with which prebilling should begin. Indexes start from 0 and must be less than the total number of supplied amendments.
|
|
2886
|
+
*/
|
|
2887
|
+
index: number;
|
|
2888
|
+
}
|
|
2889
|
+
type Type = 'amendment_start' | 'now' | 'timestamp';
|
|
2890
|
+
}
|
|
2891
|
+
namespace BillUntil {
|
|
2892
|
+
interface AmendmentEnd {
|
|
2893
|
+
/**
|
|
2894
|
+
* The position of the amendment in the `amendments` array at which prebilling should end. Indexes start from 0 and must be less than the total number of supplied amendments.
|
|
2895
|
+
*/
|
|
2896
|
+
index: number;
|
|
2897
|
+
}
|
|
2898
|
+
interface Duration {
|
|
2899
|
+
/**
|
|
2900
|
+
* Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
|
2901
|
+
*/
|
|
2902
|
+
interval: Duration.Interval;
|
|
2903
|
+
/**
|
|
2904
|
+
* The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
|
2905
|
+
*/
|
|
2906
|
+
interval_count: number;
|
|
2907
|
+
}
|
|
2908
|
+
type Type = 'amendment_end' | 'duration' | 'schedule_end' | 'timestamp';
|
|
2909
|
+
namespace Duration {
|
|
2910
|
+
type Interval = 'day' | 'month' | 'week' | 'year';
|
|
2911
|
+
}
|
|
2912
|
+
}
|
|
2913
|
+
}
|
|
2914
|
+
namespace ScheduleSettings {
|
|
2915
|
+
type EndBehavior = 'cancel' | 'release';
|
|
2916
|
+
}
|
|
2917
|
+
}
|
|
1766
2918
|
export interface SubscriptionScheduleCancelParams {
|
|
1767
2919
|
/**
|
|
1768
2920
|
* Specifies which fields in the response should be expanded.
|