Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update generated code #1846

Merged
merged 10 commits into from
Apr 11, 2024
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v940
v950
4 changes: 2 additions & 2 deletions account.go
Original file line number Diff line number Diff line change
Expand Up @@ -1296,7 +1296,7 @@ type AccountFutureRequirements struct {
EventuallyDue []string `json:"eventually_due"`
// Fields that weren't collected by `requirements.current_deadline`. These fields need to be collected to enable the capability on the account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.
PastDue []string `json:"past_due"`
// Fields that may become required depending on the results of verification or review. Will be an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`.
// Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.
PendingVerification []string `json:"pending_verification"`
}

Expand Down Expand Up @@ -1332,7 +1332,7 @@ type AccountRequirements struct {
EventuallyDue []string `json:"eventually_due"`
// Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the account.
PastDue []string `json:"past_due"`
// Fields that may become required depending on the results of verification or review. Will be an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`.
// Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
PendingVerification []string `json:"pending_verification"`
}
type AccountSettingsBACSDebitPayments struct {
Expand Down
72 changes: 65 additions & 7 deletions accountsession.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,24 @@
package stripe

// The list of features enabled in the embedded component.
type AccountSessionComponentsAccountOnboardingFeaturesParams struct{}
type AccountSessionComponentsAccountManagementFeaturesParams struct {
// Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.
ExternalAccountCollection *bool `form:"external_account_collection"`
}

// Configuration for the account management embedded component.
type AccountSessionComponentsAccountManagementParams struct {
// Whether the embedded component is enabled.
Enabled *bool `form:"enabled"`
// The list of features enabled in the embedded component.
Features *AccountSessionComponentsAccountManagementFeaturesParams `form:"features"`
}

// The list of features enabled in the embedded component.
type AccountSessionComponentsAccountOnboardingFeaturesParams struct {
// Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.
ExternalAccountCollection *bool `form:"external_account_collection"`
}

// Configuration for the account onboarding embedded component.
type AccountSessionComponentsAccountOnboardingParams struct {
Expand All @@ -28,6 +45,20 @@ type AccountSessionComponentsDocumentsParams struct {
Features *AccountSessionComponentsDocumentsFeaturesParams `form:"features"`
}

// The list of features enabled in the embedded component.
type AccountSessionComponentsNotificationBannerFeaturesParams struct {
// Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.
ExternalAccountCollection *bool `form:"external_account_collection"`
}

// Configuration for the notification banner embedded component.
type AccountSessionComponentsNotificationBannerParams struct {
// Whether the embedded component is enabled.
Enabled *bool `form:"enabled"`
// The list of features enabled in the embedded component.
Features *AccountSessionComponentsNotificationBannerFeaturesParams `form:"features"`
}

// The list of features enabled in the embedded component.
type AccountSessionComponentsPaymentDetailsFeaturesParams struct {
// Whether to allow capturing and cancelling payment intents. This is `true` by default.
Expand Down Expand Up @@ -88,10 +119,14 @@ type AccountSessionComponentsPayoutsParams struct {

// 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).
type AccountSessionComponentsParams struct {
// Configuration for the account management embedded component.
AccountManagement *AccountSessionComponentsAccountManagementParams `form:"account_management"`
// Configuration for the account onboarding embedded component.
AccountOnboarding *AccountSessionComponentsAccountOnboardingParams `form:"account_onboarding"`
// Configuration for the documents embedded component.
Documents *AccountSessionComponentsDocumentsParams `form:"documents"`
// Configuration for the notification banner embedded component.
NotificationBanner *AccountSessionComponentsNotificationBannerParams `form:"notification_banner"`
// Configuration for the payment details embedded component.
PaymentDetails *AccountSessionComponentsPaymentDetailsParams `form:"payment_details"`
// Configuration for the payments embedded component.
Expand All @@ -116,7 +151,19 @@ func (p *AccountSessionParams) AddExpand(f string) {
p.Expand = append(p.Expand, &f)
}

type AccountSessionComponentsAccountOnboardingFeatures struct{}
type AccountSessionComponentsAccountManagementFeatures struct {
// Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.
ExternalAccountCollection bool `json:"external_account_collection"`
}
type AccountSessionComponentsAccountManagement struct {
// Whether the embedded component is enabled.
Enabled bool `json:"enabled"`
Features *AccountSessionComponentsAccountManagementFeatures `json:"features"`
}
type AccountSessionComponentsAccountOnboardingFeatures struct {
// Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.
ExternalAccountCollection bool `json:"external_account_collection"`
}
type AccountSessionComponentsAccountOnboarding struct {
// Whether the embedded component is enabled.
Enabled bool `json:"enabled"`
Expand All @@ -128,6 +175,15 @@ type AccountSessionComponentsDocuments struct {
Enabled bool `json:"enabled"`
Features *AccountSessionComponentsDocumentsFeatures `json:"features"`
}
type AccountSessionComponentsNotificationBannerFeatures struct {
// Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.
ExternalAccountCollection bool `json:"external_account_collection"`
}
type AccountSessionComponentsNotificationBanner struct {
// Whether the embedded component is enabled.
Enabled bool `json:"enabled"`
Features *AccountSessionComponentsNotificationBannerFeatures `json:"features"`
}
type AccountSessionComponentsPaymentDetailsFeatures struct {
// Whether to allow capturing and cancelling payment intents. This is `true` by default.
CapturePayments bool `json:"capture_payments"`
Expand Down Expand Up @@ -172,11 +228,13 @@ type AccountSessionComponentsPayouts struct {
Features *AccountSessionComponentsPayoutsFeatures `json:"features"`
}
type AccountSessionComponents struct {
AccountOnboarding *AccountSessionComponentsAccountOnboarding `json:"account_onboarding"`
Documents *AccountSessionComponentsDocuments `json:"documents"`
PaymentDetails *AccountSessionComponentsPaymentDetails `json:"payment_details"`
Payments *AccountSessionComponentsPayments `json:"payments"`
Payouts *AccountSessionComponentsPayouts `json:"payouts"`
AccountManagement *AccountSessionComponentsAccountManagement `json:"account_management"`
AccountOnboarding *AccountSessionComponentsAccountOnboarding `json:"account_onboarding"`
Documents *AccountSessionComponentsDocuments `json:"documents"`
NotificationBanner *AccountSessionComponentsNotificationBanner `json:"notification_banner"`
PaymentDetails *AccountSessionComponentsPaymentDetails `json:"payment_details"`
Payments *AccountSessionComponentsPayments `json:"payments"`
Payouts *AccountSessionComponentsPayouts `json:"payouts"`
}

// An AccountSession allows a Connect platform to grant access to a connected account in Connect embedded components.
Expand Down
4 changes: 2 additions & 2 deletions bankaccount.go
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,7 @@ type BankAccountFutureRequirements struct {
Errors []*BankAccountFutureRequirementsError `json:"errors"`
// Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the external account.
PastDue []string `json:"past_due"`
// Fields that may become required depending on the results of verification or review. Will be an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`.
// Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
PendingVerification []string `json:"pending_verification"`
}

Expand All @@ -434,7 +434,7 @@ type BankAccountRequirements struct {
Errors []*BankAccountRequirementsError `json:"errors"`
// Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the external account.
PastDue []string `json:"past_due"`
// Fields that may become required depending on the results of verification or review. Will be an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`.
// Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
PendingVerification []string `json:"pending_verification"`
}

Expand Down
2 changes: 1 addition & 1 deletion billing_meter.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ type BillingMeterValueSettings struct {
EventPayloadKey string `json:"event_payload_key"`
}

// A billing meter is a resource that allows you to track usage of a particular event. For example, you might create a billing meter to track the number of API calls made by a particular user. You can then use the billing meter to charge the user for the number of API calls they make.
// A billing meter is a resource that allows you to track usage of a particular event. For example, you might create a billing meter to track the number of API calls made by a particular user. You can then attach the billing meter to a price and attach the price to a subscription to charge the user for the number of API calls they make.
type BillingMeter struct {
APIResource
// Time at which the object was created. Measured in seconds since the Unix epoch.
Expand Down
10 changes: 6 additions & 4 deletions billing_metereventadjustment.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const (
BillingMeterEventAdjustmentStatusPending BillingMeterEventAdjustmentStatus = "pending"
)

// Specifies whether to cancel a single event or a range of events for a time period.
// Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
type BillingMeterEventAdjustmentType string

// List of values that BillingMeterEventAdjustmentType can take
Expand All @@ -38,7 +38,7 @@ type BillingMeterEventAdjustmentParams struct {
EventName *string `form:"event_name"`
// Specifies which fields in the response should be expanded.
Expand []*string `form:"expand"`
// Specifies whether to cancel a single event or a range of events for a time period.
// Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
Type *string `form:"type"`
}

Expand All @@ -47,14 +47,16 @@ func (p *BillingMeterEventAdjustmentParams) AddExpand(f string) {
p.Expand = append(p.Expand, &f)
}

// Specifies which event to cancel.
type BillingMeterEventAdjustmentCancel struct {
// Unique identifier for the event.
Identifier string `json:"identifier"`
}

// A billing meter event adjustment represents the status of a meter event adjustment.
// A billing meter event adjustment is a resource that allows you to cancel a meter event. For example, you might create a billing meter event adjustment to cancel a meter event that was created in error or attached to the wrong customer.
type BillingMeterEventAdjustment struct {
APIResource
// Specifies which event to cancel.
Cancel *BillingMeterEventAdjustmentCancel `json:"cancel"`
// The name of the meter event. Corresponds with the `event_name` field on a meter.
EventName string `json:"event_name"`
Expand All @@ -64,6 +66,6 @@ type BillingMeterEventAdjustment struct {
Object string `json:"object"`
// The meter event adjustment's status.
Status BillingMeterEventAdjustmentStatus `json:"status"`
// Specifies whether to cancel a single event or a range of events for a time period.
// Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
Type BillingMeterEventAdjustmentType `json:"type"`
}
4 changes: 2 additions & 2 deletions billingportal_session.go
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ type BillingPortalSessionParams struct {
FlowData *BillingPortalSessionFlowDataParams `form:"flow_data"`
// The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer's `preferred_locales` or browser's locale is used.
Locale *string `form:"locale"`
// The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#on-behalf-of). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
// The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
OnBehalfOf *string `form:"on_behalf_of"`
// The default URL to redirect customers to when they click on the portal's link to return to your website.
ReturnURL *string `form:"return_url"`
Expand Down Expand Up @@ -272,7 +272,7 @@ type BillingPortalSession struct {
Locale string `json:"locale"`
// String representing the object's type. Objects of the same type share the same value.
Object string `json:"object"`
// The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#on-behalf-of). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
// The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
OnBehalfOf string `json:"on_behalf_of"`
// The URL to redirect customers to when they click on the portal's link to return to your website.
ReturnURL string `json:"return_url"`
Expand Down
4 changes: 2 additions & 2 deletions capability.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ type CapabilityFutureRequirements struct {
EventuallyDue []string `json:"eventually_due"`
// Fields that weren't collected by `requirements.current_deadline`. These fields need to be collected to enable the capability on the account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.
PastDue []string `json:"past_due"`
// Fields that may become required depending on the results of verification or review. Will be an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`.
// Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.
PendingVerification []string `json:"pending_verification"`
}

Expand Down Expand Up @@ -131,7 +131,7 @@ type CapabilityRequirements struct {
EventuallyDue []string `json:"eventually_due"`
// Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the capability on the account.
PastDue []string `json:"past_due"`
// Fields that may become required depending on the results of verification or review. Will be an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`.
// Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
PendingVerification []string `json:"pending_verification"`
}

Expand Down
Loading
Loading