Skip to content

Commit

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

* Update generated code for v943

* Update generated code for v944

* Update generated code for v945

* Update generated code for v946

* Update generated code for v947

* Update generated code for v948

* Update generated code for v949

* Update generated code for v950

---------

Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Co-authored-by: Ramya Rao <100975018+ramya-stripe@users.noreply.github.com>
  • Loading branch information
stripe-openapi[bot] and ramya-stripe authored Apr 11, 2024
1 parent 4346e49 commit b106d48
Show file tree
Hide file tree
Showing 45 changed files with 916 additions and 82 deletions.
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 stripe/_account.py
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,7 @@ class Error(StripeObject):
"""
pending_verification: Optional[List[str]]
"""
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.
"""
_inner_class_types = {"alternatives": Alternative, "errors": Error}

Expand Down Expand Up @@ -893,7 +893,7 @@ class Error(StripeObject):
"""
pending_verification: Optional[List[str]]
"""
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.
"""
_inner_class_types = {"alternatives": Alternative, "errors": Error}

Expand Down
90 changes: 88 additions & 2 deletions stripe/_account_session.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,26 @@ class AccountSession(CreateableAPIResource["AccountSession"]):
OBJECT_NAME: ClassVar[Literal["account_session"]] = "account_session"

class Components(StripeObject):
class AccountManagement(StripeObject):
class Features(StripeObject):
external_account_collection: bool
"""
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.
"""

enabled: bool
"""
Whether the embedded component is enabled.
"""
features: Features
_inner_class_types = {"features": Features}

class AccountOnboarding(StripeObject):
class Features(StripeObject):
pass
external_account_collection: bool
"""
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.
"""

enabled: bool
"""
Expand All @@ -43,6 +60,20 @@ class Features(StripeObject):
features: Features
_inner_class_types = {"features": Features}

class NotificationBanner(StripeObject):
class Features(StripeObject):
external_account_collection: bool
"""
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.
"""

enabled: bool
"""
Whether the embedded component is enabled.
"""
features: Features
_inner_class_types = {"features": Features}

class PaymentDetails(StripeObject):
class Features(StripeObject):
capture_payments: bool
Expand Down Expand Up @@ -117,14 +148,18 @@ class Features(StripeObject):
features: Features
_inner_class_types = {"features": Features}

account_management: AccountManagement
account_onboarding: AccountOnboarding
documents: Documents
notification_banner: NotificationBanner
payment_details: PaymentDetails
payments: Payments
payouts: Payouts
_inner_class_types = {
"account_management": AccountManagement,
"account_onboarding": AccountOnboarding,
"documents": Documents,
"notification_banner": NotificationBanner,
"payment_details": PaymentDetails,
"payments": Payments,
"payouts": Payouts,
Expand All @@ -145,6 +180,12 @@ class CreateParams(RequestOptions):
"""

class CreateParamsComponents(TypedDict):
account_management: NotRequired[
"AccountSession.CreateParamsComponentsAccountManagement"
]
"""
Configuration for the account management embedded component.
"""
account_onboarding: NotRequired[
"AccountSession.CreateParamsComponentsAccountOnboarding"
]
Expand All @@ -157,6 +198,12 @@ class CreateParamsComponents(TypedDict):
"""
Configuration for the documents embedded component.
"""
notification_banner: NotRequired[
"AccountSession.CreateParamsComponentsNotificationBanner"
]
"""
Configuration for the notification banner embedded component.
"""
payment_details: NotRequired[
"AccountSession.CreateParamsComponentsPaymentDetails"
]
Expand All @@ -172,6 +219,24 @@ class CreateParamsComponents(TypedDict):
Configuration for the payouts embedded component.
"""

class CreateParamsComponentsAccountManagement(TypedDict):
enabled: bool
"""
Whether the embedded component is enabled.
"""
features: NotRequired[
"AccountSession.CreateParamsComponentsAccountManagementFeatures"
]
"""
The list of features enabled in the embedded component.
"""

class CreateParamsComponentsAccountManagementFeatures(TypedDict):
external_account_collection: NotRequired[bool]
"""
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.
"""

class CreateParamsComponentsAccountOnboarding(TypedDict):
enabled: bool
"""
Expand All @@ -185,7 +250,10 @@ class CreateParamsComponentsAccountOnboarding(TypedDict):
"""

class CreateParamsComponentsAccountOnboardingFeatures(TypedDict):
pass
external_account_collection: NotRequired[bool]
"""
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.
"""

class CreateParamsComponentsDocuments(TypedDict):
enabled: bool
Expand All @@ -202,6 +270,24 @@ class CreateParamsComponentsDocuments(TypedDict):
class CreateParamsComponentsDocumentsFeatures(TypedDict):
pass

class CreateParamsComponentsNotificationBanner(TypedDict):
enabled: bool
"""
Whether the embedded component is enabled.
"""
features: NotRequired[
"AccountSession.CreateParamsComponentsNotificationBannerFeatures"
]
"""
The list of features enabled in the embedded component.
"""

class CreateParamsComponentsNotificationBannerFeatures(TypedDict):
external_account_collection: NotRequired[bool]
"""
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.
"""

class CreateParamsComponentsPaymentDetails(TypedDict):
enabled: bool
"""
Expand Down
53 changes: 52 additions & 1 deletion stripe/_account_session_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ class CreateParams(TypedDict):
"""

class CreateParamsComponents(TypedDict):
account_management: NotRequired[
"AccountSessionService.CreateParamsComponentsAccountManagement"
]
"""
Configuration for the account management embedded component.
"""
account_onboarding: NotRequired[
"AccountSessionService.CreateParamsComponentsAccountOnboarding"
]
Expand All @@ -35,6 +41,12 @@ class CreateParamsComponents(TypedDict):
"""
Configuration for the documents embedded component.
"""
notification_banner: NotRequired[
"AccountSessionService.CreateParamsComponentsNotificationBanner"
]
"""
Configuration for the notification banner embedded component.
"""
payment_details: NotRequired[
"AccountSessionService.CreateParamsComponentsPaymentDetails"
]
Expand All @@ -54,6 +66,24 @@ class CreateParamsComponents(TypedDict):
Configuration for the payouts embedded component.
"""

class CreateParamsComponentsAccountManagement(TypedDict):
enabled: bool
"""
Whether the embedded component is enabled.
"""
features: NotRequired[
"AccountSessionService.CreateParamsComponentsAccountManagementFeatures"
]
"""
The list of features enabled in the embedded component.
"""

class CreateParamsComponentsAccountManagementFeatures(TypedDict):
external_account_collection: NotRequired[bool]
"""
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.
"""

class CreateParamsComponentsAccountOnboarding(TypedDict):
enabled: bool
"""
Expand All @@ -67,7 +97,10 @@ class CreateParamsComponentsAccountOnboarding(TypedDict):
"""

class CreateParamsComponentsAccountOnboardingFeatures(TypedDict):
pass
external_account_collection: NotRequired[bool]
"""
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.
"""

class CreateParamsComponentsDocuments(TypedDict):
enabled: bool
Expand All @@ -84,6 +117,24 @@ class CreateParamsComponentsDocuments(TypedDict):
class CreateParamsComponentsDocumentsFeatures(TypedDict):
pass

class CreateParamsComponentsNotificationBanner(TypedDict):
enabled: bool
"""
Whether the embedded component is enabled.
"""
features: NotRequired[
"AccountSessionService.CreateParamsComponentsNotificationBannerFeatures"
]
"""
The list of features enabled in the embedded component.
"""

class CreateParamsComponentsNotificationBannerFeatures(TypedDict):
external_account_collection: NotRequired[bool]
"""
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.
"""

class CreateParamsComponentsPaymentDetails(TypedDict):
enabled: bool
"""
Expand Down
4 changes: 2 additions & 2 deletions stripe/_bank_account.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ class Error(StripeObject):
"""
pending_verification: Optional[List[str]]
"""
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.
"""
_inner_class_types = {"errors": Error}

Expand Down Expand Up @@ -274,7 +274,7 @@ class Error(StripeObject):
"""
pending_verification: Optional[List[str]]
"""
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.
"""
_inner_class_types = {"errors": Error}

Expand Down
4 changes: 2 additions & 2 deletions stripe/_capability.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ class Error(StripeObject):
"""
pending_verification: List[str]
"""
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.
"""
_inner_class_types = {"alternatives": Alternative, "errors": Error}

Expand Down Expand Up @@ -316,7 +316,7 @@ class Error(StripeObject):
"""
pending_verification: List[str]
"""
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.
"""
_inner_class_types = {"alternatives": Alternative, "errors": Error}

Expand Down
13 changes: 9 additions & 4 deletions stripe/_charge.py
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,9 @@ class Alipay(StripeObject):
Transaction ID of this particular Alipay transaction.
"""

class AmazonPay(StripeObject):
pass

class AuBecsDebit(StripeObject):
bsb_number: Optional[str]
"""
Expand Down Expand Up @@ -1575,6 +1578,7 @@ class Zip(StripeObject):
affirm: Optional[Affirm]
afterpay_clearpay: Optional[AfterpayClearpay]
alipay: Optional[Alipay]
amazon_pay: Optional[AmazonPay]
au_becs_debit: Optional[AuBecsDebit]
bacs_debit: Optional[BacsDebit]
bancontact: Optional[Bancontact]
Expand Down Expand Up @@ -1624,6 +1628,7 @@ class Zip(StripeObject):
"affirm": Affirm,
"afterpay_clearpay": AfterpayClearpay,
"alipay": Alipay,
"amazon_pay": AmazonPay,
"au_becs_debit": AuBecsDebit,
"bacs_debit": BacsDebit,
"bancontact": Bancontact,
Expand Down Expand Up @@ -1776,7 +1781,7 @@ class CreateParams(RequestOptions):
application_fee: NotRequired[int]
application_fee_amount: NotRequired[int]
"""
A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees).
A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collect-fees).
"""
capture: NotRequired[bool]
"""
Expand Down Expand Up @@ -1805,7 +1810,7 @@ class CreateParams(RequestOptions):
"""
on_behalf_of: NotRequired[str]
"""
The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#on-behalf-of).
The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
"""
radar_options: NotRequired["Charge.CreateParamsRadarOptions"]
"""
Expand Down Expand Up @@ -2120,11 +2125,11 @@ class SearchParams(RequestOptions):
"""
application_fee: Optional[ExpandableField["ApplicationFee"]]
"""
The application fee (if any) for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees) for details.
The application fee (if any) for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collect-fees) for details.
"""
application_fee_amount: Optional[int]
"""
The amount of the application fee (if any) requested for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collecting-fees) for details.
The amount of the application fee (if any) requested for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collect-fees) for details.
"""
authorization_code: Optional[str]
"""
Expand Down
Loading

0 comments on commit b106d48

Please sign in to comment.