Skip to content

Commit

Permalink
Codegen for openapi v153
Browse files Browse the repository at this point in the history
  • Loading branch information
pakrym-stripe committed Jun 8, 2022
1 parent e393e1e commit 7fe9ef1
Show file tree
Hide file tree
Showing 8 changed files with 485 additions and 47 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v152
v153
30 changes: 26 additions & 4 deletions types/2020-08-27/Customers.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -779,17 +779,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<BankTransfer.RequestedAddressType>;

/**
* 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';
}
}

Expand Down Expand Up @@ -958,7 +980,7 @@ declare module 'stripe' {
): ApiListPromise<Stripe.PaymentMethod>;

/**
* Retrieves a PaymentMethod object.
* Retrieves a PaymentMethod object for a given Customer.
*/
retrievePaymentMethod(
customerId: string,
Expand Down
75 changes: 73 additions & 2 deletions types/2020-08-27/FundingInstructions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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
*/
Expand All @@ -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 {
/**
Expand Down
49 changes: 46 additions & 3 deletions types/2020-08-27/Invoices.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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 {}
Expand Down Expand Up @@ -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 {}
Expand Down Expand Up @@ -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 {}
Expand Down
106 changes: 94 additions & 12 deletions types/2020-08-27/Orders.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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';
}
}

Expand Down Expand Up @@ -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';
}
}

Expand Down Expand Up @@ -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';
}
}

Expand Down
Loading

0 comments on commit 7fe9ef1

Please sign in to comment.