diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 0b9a2a89f2..d377f60ad0 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v152 \ No newline at end of file +v154 \ No newline at end of file diff --git a/types/2020-08-27/Accounts.d.ts b/types/2020-08-27/Accounts.d.ts index 1ef99ed08b..a71d7c4bec 100644 --- a/types/2020-08-27/Accounts.d.ts +++ b/types/2020-08-27/Accounts.d.ts @@ -874,6 +874,8 @@ declare module 'stripe' { payouts?: Settings.Payouts; sepa_debit_payments?: Settings.SepaDebitPayments; + + treasury?: Settings.Treasury; } namespace Settings { @@ -1025,6 +1027,29 @@ declare module 'stripe' { */ creditor_id?: string; } + + interface Treasury { + tos_acceptance?: Treasury.TosAcceptance; + } + + namespace Treasury { + interface TosAcceptance { + /** + * The Unix timestamp marking when the account representative accepted the service agreement. + */ + date: number | null; + + /** + * The IP address from which the account representative accepted the service agreement. + */ + ip: string | null; + + /** + * The user agent of the browser from which the account representative accepted the service agreement. + */ + user_agent?: string; + } + } } interface TosAcceptance { @@ -2069,6 +2094,11 @@ declare module 'stripe' { * Settings specific to the account's payouts. */ payouts?: Settings.Payouts; + + /** + * Settings specific to the account's Treasury FinancialAccounts. + */ + treasury?: Settings.Treasury; } namespace Settings { @@ -2216,6 +2246,32 @@ declare module 'stripe' { | 'wednesday'; } } + + interface Treasury { + /** + * Details on the account's acceptance of the Stripe Treasury Services Agreement. + */ + tos_acceptance?: Treasury.TosAcceptance; + } + + namespace Treasury { + interface TosAcceptance { + /** + * The Unix timestamp marking when the account representative accepted the service agreement. + */ + date?: number; + + /** + * The IP address from which the account representative accepted the service agreement. + */ + ip?: string; + + /** + * The user agent of the browser from which the account representative accepted the service agreement. + */ + user_agent?: string; + } + } } interface TosAcceptance { @@ -3200,6 +3256,11 @@ declare module 'stripe' { * Settings specific to the account's payouts. */ payouts?: Settings.Payouts; + + /** + * Settings specific to the account's Treasury FinancialAccounts. + */ + treasury?: Settings.Treasury; } namespace Settings { @@ -3347,6 +3408,32 @@ declare module 'stripe' { | 'wednesday'; } } + + interface Treasury { + /** + * Details on the account's acceptance of the Stripe Treasury Services Agreement. + */ + tos_acceptance?: Treasury.TosAcceptance; + } + + namespace Treasury { + interface TosAcceptance { + /** + * The Unix timestamp marking when the account representative accepted the service agreement. + */ + date?: number; + + /** + * The IP address from which the account representative accepted the service agreement. + */ + ip?: string; + + /** + * The user agent of the browser from which the account representative accepted the service agreement. + */ + user_agent?: string; + } + } } interface TosAcceptance { diff --git a/types/2020-08-27/Customers.d.ts b/types/2020-08-27/Customers.d.ts index 6a2196bbb3..f3070ebd18 100644 --- a/types/2020-08-27/Customers.d.ts +++ b/types/2020-08-27/Customers.d.ts @@ -418,6 +418,11 @@ declare module 'stripe' { * Default footer to be displayed on invoices for this customer. */ footer?: string; + + /** + * Default options for invoice PDF rendering for this customer. + */ + rendering_options?: InvoiceSettings.RenderingOptions; } namespace InvoiceSettings { @@ -432,6 +437,19 @@ declare module 'stripe' { */ value: string; } + + interface RenderingOptions { + /** + * How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. + */ + amount_tax_display?: Stripe.Emptyable< + RenderingOptions.AmountTaxDisplay + >; + } + + namespace RenderingOptions { + type AmountTaxDisplay = 'exclude_tax' | 'include_inclusive_tax'; + } } interface Shipping { @@ -685,6 +703,11 @@ declare module 'stripe' { * Default footer to be displayed on invoices for this customer. */ footer?: string; + + /** + * Default options for invoice PDF rendering for this customer. + */ + rendering_options?: InvoiceSettings.RenderingOptions; } namespace InvoiceSettings { @@ -699,6 +722,19 @@ declare module 'stripe' { */ value: string; } + + interface RenderingOptions { + /** + * How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. + */ + amount_tax_display?: Stripe.Emptyable< + RenderingOptions.AmountTaxDisplay + >; + } + + namespace RenderingOptions { + type AmountTaxDisplay = 'exclude_tax' | 'include_inclusive_tax'; + } } interface Shipping { @@ -779,17 +815,39 @@ declare module 'stripe' { namespace CustomerCreateFundingInstructionsParams { interface BankTransfer { + /** + * Configuration for eu_bank_transfer funding type. + */ + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array; /** * The type of the `bank_transfer` */ - type: 'jp_bank_transfer'; + type: BankTransfer.Type; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + + type RequestedAddressType = 'iban' | 'sort_code' | 'spei' | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } @@ -958,7 +1016,7 @@ declare module 'stripe' { ): ApiListPromise; /** - * Retrieves a PaymentMethod object. + * Retrieves a PaymentMethod object for a given Customer. */ retrievePaymentMethod( customerId: string, diff --git a/types/2020-08-27/FundingInstructions.d.ts b/types/2020-08-27/FundingInstructions.d.ts index f028676cdb..232812c366 100644 --- a/types/2020-08-27/FundingInstructions.d.ts +++ b/types/2020-08-27/FundingInstructions.d.ts @@ -49,6 +49,21 @@ declare module 'stripe' { namespace BankTransfer { interface FinancialAddress { + /** + * Iban Records contain E.U. bank account details per the SEPA format. + */ + iban?: FinancialAddress.Iban; + + /** + * Sort Code Records contain U.K. bank account details per the sort code format. + */ + sort_code?: FinancialAddress.SortCode; + + /** + * SPEI Records contain Mexico bank account details per the SPEI format. + */ + spei?: FinancialAddress.Spei; + /** * The payment networks supported by this FinancialAddress */ @@ -66,9 +81,65 @@ declare module 'stripe' { } namespace FinancialAddress { - type SupportedNetwork = 'sepa' | 'zengin'; + interface Iban { + /** + * The name of the person or business that owns the bank account + */ + account_holder_name: string; + + /** + * The BIC/SWIFT code of the account. + */ + bic: string; + + /** + * Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + */ + country: string; + + /** + * The IBAN of the account. + */ + iban: string; + } + + interface SortCode { + /** + * The name of the person or business that owns the bank account + */ + account_holder_name: string; + + /** + * The account number + */ + account_number: string; + + /** + * The six-digit sort code + */ + sort_code: string; + } + + interface Spei { + /** + * The three-digit bank code + */ + bank_code: string; + + /** + * The short banking institution name + */ + bank_name: string; + + /** + * The CLABE number + */ + clabe: string; + } + + type SupportedNetwork = 'bacs' | 'fps' | 'sepa' | 'spei' | 'zengin'; - type Type = 'iban' | 'zengin'; + type Type = 'iban' | 'sort_code' | 'spei' | 'zengin'; interface Zengin { /** diff --git a/types/2020-08-27/Invoices.d.ts b/types/2020-08-27/Invoices.d.ts index 635b03104e..5db76d28e1 100644 --- a/types/2020-08-27/Invoices.d.ts +++ b/types/2020-08-27/Invoices.d.ts @@ -696,11 +696,26 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** - * The bank transfer type that can be used for funding. Permitted values include: `jp_bank_transfer`. + * The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ type: string | null; } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: EuBankTransfer.Country; + } + + namespace EuBankTransfer { + type Country = 'DE' | 'ES' | 'FR' | 'IE' | 'NL'; + } + } } interface Konbini {} @@ -1139,10 +1154,24 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { /** - * The bank transfer type that can be used for funding. Permitted values include: `jp_bank_transfer`. + * Configuration for eu_bank_transfer funding type. + */ + eu_bank_transfer?: BankTransfer.EuBankTransfer; + + /** + * The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ type?: string; } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + } } interface Konbini {} @@ -1480,10 +1509,24 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { /** - * The bank transfer type that can be used for funding. Permitted values include: `jp_bank_transfer`. + * Configuration for eu_bank_transfer funding type. + */ + eu_bank_transfer?: BankTransfer.EuBankTransfer; + + /** + * The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ type?: string; } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + } } interface Konbini {} diff --git a/types/2020-08-27/Orders.d.ts b/types/2020-08-27/Orders.d.ts index 70fc77d805..687a1ebf89 100644 --- a/types/2020-08-27/Orders.d.ts +++ b/types/2020-08-27/Orders.d.ts @@ -405,17 +405,47 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array< + BankTransfer.RequestedAddressType + >; /** - * The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer' | null; + type: BankTransfer.Type | null; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: EuBankTransfer.Country; + } + + namespace EuBankTransfer { + type Country = 'DE' | 'ES' | 'FR' | 'IE' | 'NL'; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } @@ -1363,17 +1393,43 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array< + BankTransfer.RequestedAddressType + >; /** - * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer'; + type: BankTransfer.Type; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } @@ -2385,17 +2441,43 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array< + BankTransfer.RequestedAddressType + >; /** - * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer'; + type: BankTransfer.Type; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } diff --git a/types/2020-08-27/PaymentIntents.d.ts b/types/2020-08-27/PaymentIntents.d.ts index 69aee0bf0f..e9e23e6482 100644 --- a/types/2020-08-27/PaymentIntents.d.ts +++ b/types/2020-08-27/PaymentIntents.d.ts @@ -475,11 +475,26 @@ declare module 'stripe' { /** * Type of bank transfer */ - type: 'jp_bank_transfer'; + type: DisplayBankTransferInstructions.Type; } namespace DisplayBankTransferInstructions { interface FinancialAddress { + /** + * Iban Records contain E.U. bank account details per the SEPA format. + */ + iban?: FinancialAddress.Iban; + + /** + * Sort Code Records contain U.K. bank account details per the sort code format. + */ + sort_code?: FinancialAddress.SortCode; + + /** + * SPEI Records contain Mexico bank account details per the SPEI format. + */ + spei?: FinancialAddress.Spei; + /** * The payment networks supported by this FinancialAddress */ @@ -497,9 +512,65 @@ declare module 'stripe' { } namespace FinancialAddress { - type SupportedNetwork = 'sepa' | 'zengin'; + interface Iban { + /** + * The name of the person or business that owns the bank account + */ + account_holder_name: string; + + /** + * The BIC/SWIFT code of the account. + */ + bic: string; + + /** + * Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + */ + country: string; + + /** + * The IBAN of the account. + */ + iban: string; + } + + interface SortCode { + /** + * The name of the person or business that owns the bank account + */ + account_holder_name: string; + + /** + * The account number + */ + account_number: string; + + /** + * The six-digit sort code + */ + sort_code: string; + } + + interface Spei { + /** + * The three-digit bank code + */ + bank_code: string; + + /** + * The short banking institution name + */ + bank_name: string; + + /** + * The CLABE number + */ + clabe: string; + } - type Type = 'iban' | 'zengin'; + type SupportedNetwork = 'bacs' | 'fps' | 'sepa' | 'spei' | 'zengin'; + + type Type = 'iban' | 'sort_code' | 'spei' | 'zengin'; interface Zengin { /** @@ -538,6 +609,12 @@ declare module 'stripe' { branch_name: string | null; } } + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } interface KonbiniDisplayDetails { @@ -1194,17 +1271,45 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array; /** - * The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The bank transfer type that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer' | null; + type: BankTransfer.Type | null; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: EuBankTransfer.Country; + } + + namespace EuBankTransfer { + type Country = 'DE' | 'ES' | 'FR' | 'IE' | 'NL'; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } @@ -2851,17 +2956,41 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array; /** - * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer'; + type: BankTransfer.Type; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } @@ -4486,17 +4615,41 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array; /** - * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer'; + type: BankTransfer.Type; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } @@ -6256,17 +6409,41 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** * List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned. * - * Permitted values include: `zengin`. + * Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`. */ - requested_address_types?: Array<'zengin'>; + requested_address_types?: Array; /** - * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `jp_bank_transfer`. + * The list of bank transfer types that this PaymentIntent is allowed to use for funding Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ - type: 'jp_bank_transfer'; + type: BankTransfer.Type; + } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + + type RequestedAddressType = + | 'iban' + | 'sepa' + | 'sort_code' + | 'spei' + | 'zengin'; + + type Type = + | 'eu_bank_transfer' + | 'gb_bank_transfer' + | 'jp_bank_transfer' + | 'mx_bank_transfer'; } } diff --git a/types/2020-08-27/PaymentMethods.d.ts b/types/2020-08-27/PaymentMethods.d.ts index c097a0ff0b..b192752d72 100644 --- a/types/2020-08-27/PaymentMethods.d.ts +++ b/types/2020-08-27/PaymentMethods.d.ts @@ -1448,7 +1448,7 @@ declare module 'stripe' { type: PaymentMethodListParams.Type; /** - * The ID of the customer whose PaymentMethods will be retrieved. If not provided, the response list will be empty. + * The ID of the customer whose PaymentMethods will be retrieved. */ customer?: string; @@ -1522,7 +1522,7 @@ declare module 'stripe' { ): Promise>; /** - * Retrieves a PaymentMethod object. + * Retrieves a PaymentMethod object attached to the StripeAccount. To retrieve a payment method attached to a Customer, you should use [Retrieve a Customer's PaymentMethods](https://stripe.com/docs/api/payment_methods/customer) */ retrieve( id: string, @@ -1544,7 +1544,7 @@ declare module 'stripe' { ): Promise>; /** - * Returns a list of PaymentMethods. For listing a customer's payment methods, you should use [List a Customer's PaymentMethods](https://stripe.com/docs/api/payment_methods/customer_list) + * Returns a list of PaymentMethods attached to the StripeAccount. For listing a customer's payment methods, you should use [List a Customer's PaymentMethods](https://stripe.com/docs/api/payment_methods/customer_list) */ list( params: PaymentMethodListParams, diff --git a/types/2020-08-27/Prices.d.ts b/types/2020-08-27/Prices.d.ts index 589ad5744e..27ad59a204 100644 --- a/types/2020-08-27/Prices.d.ts +++ b/types/2020-08-27/Prices.d.ts @@ -36,6 +36,11 @@ declare module 'stripe' { */ currency: string; + /** + * When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links. + */ + custom_unit_amount?: Price.CustomUnitAmount | null; + deleted?: void; /** @@ -107,6 +112,23 @@ declare module 'stripe' { namespace Price { type BillingScheme = 'per_unit' | 'tiered'; + interface CustomUnitAmount { + /** + * The maximum unit amount the customer can specify for this item. + */ + maximum: number | null; + + /** + * The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount. + */ + minimum: number | null; + + /** + * The starting unit amount which can be updated by the customer. + */ + preset: number | null; + } + interface Recurring { /** * Specifies a usage aggregation strategy for prices of `usage_type=metered`. Allowed values are `sum` for summing up all usage during a period, `last_during_period` for using the last usage record reported within a period, `last_ever` for using the last usage record ever (across period bounds) or `max` which uses the usage record with the maximum reported usage during a period. Defaults to `sum`. @@ -232,6 +254,11 @@ declare module 'stripe' { */ billing_scheme?: PriceCreateParams.BillingScheme; + /** + * When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links. + */ + custom_unit_amount?: PriceCreateParams.CustomUnitAmount; + /** * Specifies which fields in the response should be expanded. */ @@ -306,6 +333,28 @@ declare module 'stripe' { namespace PriceCreateParams { type BillingScheme = 'per_unit' | 'tiered'; + interface CustomUnitAmount { + /** + * Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`. + */ + enabled: boolean; + + /** + * The maximum unit amount the customer can specify for this item. + */ + maximum?: number; + + /** + * The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount. + */ + minimum?: number; + + /** + * The starting unit amount which can be updated by the customer. + */ + preset?: number; + } + interface ProductData { /** * Whether the product is currently available for purchase. Defaults to `true`. diff --git a/types/2020-08-27/Subscriptions.d.ts b/types/2020-08-27/Subscriptions.d.ts index 5ddd032b8b..0d0b94cd06 100644 --- a/types/2020-08-27/Subscriptions.d.ts +++ b/types/2020-08-27/Subscriptions.d.ts @@ -380,11 +380,26 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { + eu_bank_transfer?: BankTransfer.EuBankTransfer; + /** - * The bank transfer type that can be used for funding. Permitted values include: `jp_bank_transfer`. + * The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ type: string | null; } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: EuBankTransfer.Country; + } + + namespace EuBankTransfer { + type Country = 'DE' | 'ES' | 'FR' | 'IE' | 'NL'; + } + } } interface Konbini {} @@ -990,10 +1005,24 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { /** - * The bank transfer type that can be used for funding. Permitted values include: `jp_bank_transfer`. + * Configuration for eu_bank_transfer funding type. + */ + eu_bank_transfer?: BankTransfer.EuBankTransfer; + + /** + * The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ type?: string; } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + } } interface Konbini {} @@ -1609,10 +1638,24 @@ declare module 'stripe' { namespace CustomerBalance { interface BankTransfer { /** - * The bank transfer type that can be used for funding. Permitted values include: `jp_bank_transfer`. + * Configuration for eu_bank_transfer funding type. + */ + eu_bank_transfer?: BankTransfer.EuBankTransfer; + + /** + * The bank transfer type that can be used for funding. Permitted values include: `eu_bank_transfer`, `gb_bank_transfer`, `jp_bank_transfer`, or `mx_bank_transfer`. */ type?: string; } + + namespace BankTransfer { + interface EuBankTransfer { + /** + * The desired country code of the bank account information. Permitted values include: `DE`, `ES`, `FR`, `IE`, or `NL`. + */ + country: string; + } + } } interface Konbini {}