Skip to content

Commit

Permalink
Codegen for openapi v154
Browse files Browse the repository at this point in the history
  • Loading branch information
pakrym-stripe committed Jun 9, 2022
1 parent e393e1e commit c2213eb
Show file tree
Hide file tree
Showing 10 changed files with 657 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
v154
87 changes: 87 additions & 0 deletions types/2020-08-27/Accounts.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -874,6 +874,8 @@ declare module 'stripe' {
payouts?: Settings.Payouts;

sepa_debit_payments?: Settings.SepaDebitPayments;

treasury?: Settings.Treasury;
}

namespace Settings {
Expand Down Expand Up @@ -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 {
Expand Down Expand Up @@ -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 {
Expand Down Expand Up @@ -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 {
Expand Down Expand Up @@ -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 {
Expand Down Expand Up @@ -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 {
Expand Down
66 changes: 62 additions & 4 deletions types/2020-08-27/Customers.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand All @@ -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 {
Expand Down Expand Up @@ -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 {
Expand All @@ -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 {
Expand Down Expand Up @@ -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<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 +1016,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
Loading

0 comments on commit c2213eb

Please sign in to comment.