Skip to content

Commit

Permalink
Update generated code (#1884)
Browse files Browse the repository at this point in the history
* Update generated code for v485

* Update generated code for v486

* Update generated code for v488

* Update generated code for v489

* Update generated code for v490

* Update generated code for v491

* Update generated code for v492

* Update generated code for v493

* Update generated code for v495

* Update generated code for v497

* Update generated code for v499

---------

Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Co-authored-by: Richard Marmorstein <[email protected]>
  • Loading branch information
stripe-openapi[bot] and richardm-stripe authored Aug 31, 2023
1 parent 646e514 commit d5e905e
Show file tree
Hide file tree
Showing 18 changed files with 397 additions and 12 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v482
v499
1 change: 1 addition & 0 deletions src/resources.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ import {VerificationReports as IdentityVerificationReports} from './resources/Id
import {VerificationSessions as IdentityVerificationSessions} from './resources/Identity/VerificationSessions.js';
export {Accounts as Account} from './resources/Accounts.js';
export {AccountLinks} from './resources/AccountLinks.js';
export {AccountSessions} from './resources/AccountSessions.js';
export {Accounts} from './resources/Accounts.js';
export {ApplePayDomains} from './resources/ApplePayDomains.js';
export {ApplicationFees} from './resources/ApplicationFees.js';
Expand Down
7 changes: 7 additions & 0 deletions src/resources/AccountSessions.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// File generated from our OpenAPI spec

import {StripeResource} from '../StripeResource.js';
const stripeMethod = StripeResource.method;
export const AccountSessions = StripeResource.extend({
create: stripeMethod({method: 'POST', fullPath: '/v1/account_sessions'}),
});
62 changes: 62 additions & 0 deletions types/AccountSessions.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
// File generated from our OpenAPI spec

declare module 'stripe' {
namespace Stripe {
/**
* An AccountSession allows a Connect platform to grant access to a connected account in Connect embedded components.
*
* We recommend that you create an AccountSession each time you need to display an embedded component
* to your user. Do not save AccountSessions to your database as they expire relatively
* quickly, and cannot be used more than once.
*
* Related guide: [Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components)
*/
interface AccountSession {
/**
* String representing the object's type. Objects of the same type share the same value.
*/
object: 'account_session';

/**
* The ID of the account the AccountSession was created for
*/
account: string;

/**
* The client secret of this AccountSession. Used on the client to set up secure access to the given `account`.
*
* The client secret can be used to provide access to `account` from your frontend. It should not be stored, logged, or exposed to anyone other than the connected account. Make sure that you have TLS enabled on any page that includes the client secret.
*
* Refer to our docs to [setup Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components) and learn about how `client_secret` should be handled.
*/
client_secret: string;

components: AccountSession.Components;

/**
* The timestamp at which this AccountSession will expire.
*/
expires_at: number;

/**
* Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
*/
livemode: boolean;
}

namespace AccountSession {
interface Components {
account_onboarding: Components.AccountOnboarding;
}

namespace Components {
interface AccountOnboarding {
/**
* Whether the embedded component is enabled.
*/
enabled: boolean;
}
}
}
}
}
50 changes: 50 additions & 0 deletions types/AccountSessionsResource.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
// File generated from our OpenAPI spec

declare module 'stripe' {
namespace Stripe {
interface AccountSessionCreateParams {
/**
* The identifier of the account to create an Account Session for.
*/
account: string;

/**
* Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).
*/
components: AccountSessionCreateParams.Components;

/**
* Specifies which fields in the response should be expanded.
*/
expand?: Array<string>;
}

namespace AccountSessionCreateParams {
interface Components {
/**
* Configuration for the account onboarding embedded component.
*/
account_onboarding?: Components.AccountOnboarding;
}

namespace Components {
interface AccountOnboarding {
/**
* Whether the embedded component is enabled.
*/
enabled: boolean;
}
}
}

class AccountSessionsResource {
/**
* Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.
*/
create(
params: AccountSessionCreateParams,
options?: RequestOptions
): Promise<Stripe.Response<Stripe.AccountSession>>;
}
}
}
6 changes: 4 additions & 2 deletions types/AccountsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2936,7 +2936,9 @@ declare module 'stripe' {
expand?: Array<string>;

/**
* Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
* To request a new capability for an account, pass true. There can be a delay before the requested capability becomes active. If the capability has any activation requirements, the response includes them in the `requirements` arrays.
*
* If a capability isn't permanent, you can remove it from the account by passing false. Most capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
*/
requested?: boolean;
}
Expand Down Expand Up @@ -3565,7 +3567,7 @@ declare module 'stripe' {
): Promise<Stripe.Response<Stripe.Person>>;

/**
* Updates an existing Account Capability.
* Updates an existing Account Capability. Request or remove a capability by updating its requested parameter.
*/
updateCapability(
accountId: string,
Expand Down
8 changes: 7 additions & 1 deletion types/BalanceTransactions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ declare module 'stripe' {
status: string;

/**
* Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payment_reversal`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead.
* Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_inbound`, `obligation_outbound`, `obligation_reversal_inbound`, `obligation_reversal_outbound`, `obligation_payout`, `obligation_payout_failure`, `payment`, `payment_failure_refund`, `payment_refund`, `payment_reversal`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead.
*/
type: BalanceTransaction.Type;
}
Expand Down Expand Up @@ -145,6 +145,12 @@ declare module 'stripe' {
| 'issuing_authorization_release'
| 'issuing_dispute'
| 'issuing_transaction'
| 'obligation_inbound'
| 'obligation_outbound'
| 'obligation_payout'
| 'obligation_payout_failure'
| 'obligation_reversal_inbound'
| 'obligation_reversal_outbound'
| 'payment'
| 'payment_failure_refund'
| 'payment_refund'
Expand Down
2 changes: 1 addition & 1 deletion types/BalanceTransactionsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ declare module 'stripe' {
source?: string;

/**
* Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `payment`, `payment_failure_refund`, `payment_refund`, `payment_reversal`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
* Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_inbound`, `obligation_outbound`, `obligation_reversal_inbound`, `obligation_reversal_outbound`, `obligation_payout`, `obligation_payout_failure`, `payment`, `payment_failure_refund`, `payment_refund`, `payment_reversal`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
*/
type?: string;
}
Expand Down
2 changes: 1 addition & 1 deletion types/BankAccounts.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ declare module 'stripe' {
fingerprint: string | null;

/**
* Information about upcoming new requirements for the bank account, including what information needs to be collected.
* Information about the [upcoming new requirements for the bank account](https://stripe.com/docs/connect/custom-accounts/future-requirements), including what information needs to be collected, and by when.
*/
future_requirements?: BankAccount.FutureRequirements | null;

Expand Down
2 changes: 1 addition & 1 deletion types/Checkout/Sessions.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ declare module 'stripe' {

/**
* The ID of the customer for this Session.
* For Checkout Sessions in `payment` or `subscription` mode, Checkout
* For Checkout Sessions in `subscription` mode or Checkout Sessions with `customer_creation` set as `always` in `payment` mode, Checkout
* will create a new customer object based on information provided
* during the payment flow unless an existing customer was provided when
* the Session was created.
Expand Down
4 changes: 2 additions & 2 deletions types/Checkout/SessionsResource.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ declare module 'stripe' {
* If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
* If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
*
* If blank for Checkout Sessions in `payment` or `subscription` mode, Checkout will create a new Customer object based on information provided during the payment flow.
* If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
*
* You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
*/
Expand Down Expand Up @@ -1233,7 +1233,7 @@ declare module 'stripe' {
>;

/**
* The list of bank transfer types that this PaymentIntent is allowed to use for funding. Permitted values include: `us_bank_account`, `eu_bank_account`, `id_bank_account`, `gb_bank_account`, `jp_bank_account`, `mx_bank_account`, `eu_bank_transfer`, `gb_bank_transfer`, `id_bank_transfer`, `jp_bank_transfer`, `mx_bank_transfer`, or `us_bank_transfer`.
* The list of bank transfer types that this PaymentIntent is allowed to use for funding.
*/
type: BankTransfer.Type;
}
Expand Down
Loading

0 comments on commit d5e905e

Please sign in to comment.