From 7f56ae5d8626b159e4fc771373bd51c1eb2262bf Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 3 Nov 2026 20:58:07 +0000 Subject: [PATCH] Update generated code for v2596 and fcd36ef9298b7a9e8a2a18bc4f6162b100aa8bbc --- ...26-11-03_stripe-openapi_521cfcca.change.md | 8 +++ CODEGEN_VERSION | 2 +- stripe/params/v2/core/__init__.py | 5 ++ .../v2/core/_account_session_create_params.py | 13 ++++ stripe/v2/core/_account_session.py | 19 ++++++ tests/test_generated_examples.py | 62 ++++++++++++++++++- 6 files changed, 105 insertions(+), 4 deletions(-) create mode 100644 .hark/changes/2026-11-03_stripe-openapi_521cfcca.change.md diff --git a/.hark/changes/2026-11-03_stripe-openapi_521cfcca.change.md b/.hark/changes/2026-11-03_stripe-openapi_521cfcca.change.md new file mode 100644 index 000000000..6a38e7e35 --- /dev/null +++ b/.hark/changes/2026-11-03_stripe-openapi_521cfcca.change.md @@ -0,0 +1,8 @@ +--- +title: Update generated code +pr_url: https://github.com/stripe/stripe-python/pull/1961 +semver_level: minor +is_stripe_api_change: true +--- + +* Add support for `business_profile_management` on `V2.Core.AccountSession.Component` and `v2.core.AccountSessionCreateParamsComponent` diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index f99af06cd..a22905938 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -305a4cda5bfda341d0099795803d0af4637923c0 \ No newline at end of file +fcd36ef9298b7a9e8a2a18bc4f6162b100aa8bbc \ No newline at end of file diff --git a/stripe/params/v2/core/__init__.py b/stripe/params/v2/core/__init__.py index 982da1fa3..386bbf668 100644 --- a/stripe/params/v2/core/__init__.py +++ b/stripe/params/v2/core/__init__.py @@ -747,6 +747,7 @@ AccountSessionCreateParamsComponentsBalanceReport as AccountSessionCreateParamsComponentsBalanceReport, AccountSessionCreateParamsComponentsBalances as AccountSessionCreateParamsComponentsBalances, AccountSessionCreateParamsComponentsBills as AccountSessionCreateParamsComponentsBills, + AccountSessionCreateParamsComponentsBusinessProfileManagement as AccountSessionCreateParamsComponentsBusinessProfileManagement, AccountSessionCreateParamsComponentsCapitalFinancing as AccountSessionCreateParamsComponentsCapitalFinancing, AccountSessionCreateParamsComponentsCapitalFinancingApplication as AccountSessionCreateParamsComponentsCapitalFinancingApplication, AccountSessionCreateParamsComponentsCapitalFinancingPromotion as AccountSessionCreateParamsComponentsCapitalFinancingPromotion, @@ -4548,6 +4549,10 @@ "stripe.params.v2.core._account_session_create_params", False, ), + "AccountSessionCreateParamsComponentsBusinessProfileManagement": ( + "stripe.params.v2.core._account_session_create_params", + False, + ), "AccountSessionCreateParamsComponentsCapitalFinancing": ( "stripe.params.v2.core._account_session_create_params", False, diff --git a/stripe/params/v2/core/_account_session_create_params.py b/stripe/params/v2/core/_account_session_create_params.py index b6d19ccbf..04349ed70 100644 --- a/stripe/params/v2/core/_account_session_create_params.py +++ b/stripe/params/v2/core/_account_session_create_params.py @@ -62,6 +62,12 @@ class AccountSessionCreateParamsComponents(TypedDict): """ Settings for the Bills embedded component. """ + business_profile_management: NotRequired[ + "AccountSessionCreateParamsComponentsBusinessProfileManagement" + ] + """ + Settings for the Business Profile Management embedded component. + """ capital_financing: NotRequired[ "AccountSessionCreateParamsComponentsCapitalFinancing" ] @@ -300,6 +306,13 @@ class AccountSessionCreateParamsComponentsBills(TypedDict): """ +class AccountSessionCreateParamsComponentsBusinessProfileManagement(TypedDict): + enabled: bool + """ + Whether this embedded component is enabled. + """ + + class AccountSessionCreateParamsComponentsCapitalFinancing(TypedDict): enabled: bool """ diff --git a/stripe/v2/core/_account_session.py b/stripe/v2/core/_account_session.py index c3070ad00..ea98e07bb 100644 --- a/stripe/v2/core/_account_session.py +++ b/stripe/v2/core/_account_session.py @@ -187,6 +187,20 @@ class Scopes(StripeObject): """ _inner_class_types = {"scopes": Scopes} + class BusinessProfileManagement(StripeObject): + class Scopes(StripeObject): + pass + + enabled: bool + """ + Whether this embedded component is enabled. + """ + scopes: Scopes + """ + The scopes available to this embedded component. + """ + _inner_class_types = {"scopes": Scopes} + class CapitalFinancing(StripeObject): class Scopes(StripeObject): pass @@ -880,6 +894,10 @@ class Scopes(StripeObject): """ Settings for the Bills embedded component. """ + business_profile_management: BusinessProfileManagement + """ + Settings for the Business Profile Management embedded component. + """ capital_financing: CapitalFinancing """ Settings for the Capital Financing embedded component. @@ -1013,6 +1031,7 @@ class Scopes(StripeObject): "balance_report": BalanceReport, "balances": Balances, "bills": Bills, + "business_profile_management": BusinessProfileManagement, "capital_financing": CapitalFinancing, "capital_financing_application": CapitalFinancingApplication, "capital_financing_promotion": CapitalFinancingPromotion, diff --git a/tests/test_generated_examples.py b/tests/test_generated_examples.py index 65767e25b..215b7b8f0 100644 --- a/tests/test_generated_examples.py +++ b/tests/test_generated_examples.py @@ -46583,6 +46583,7 @@ def test_v2_core_account_session_post_service( "balance_report": {"enabled": True}, "balances": {"enabled": True}, "bills": {"enabled": True}, + "business_profile_management": {"enabled": True}, "capital_financing": {"enabled": True}, "capital_financing_application": {"enabled": True}, "capital_financing_promotion": {"enabled": True}, @@ -46622,7 +46623,7 @@ def test_v2_core_account_session_post_service( path="/v2/core/account_sessions", query_string="", api_base="https://api.stripe.com", - post_data='{"account":"account","components":{"account_management":{"enabled":true},"account_onboarding":{"enabled":true},"agentic_commerce_settings":{"enabled":true},"app_install":{"enabled":true},"app_viewport":{"enabled":true},"balance_report":{"enabled":true},"balances":{"enabled":true},"bills":{"enabled":true},"capital_financing":{"enabled":true},"capital_financing_application":{"enabled":true},"capital_financing_promotion":{"enabled":true},"check_scanning":{"enabled":true},"disputes_list":{"enabled":true},"documents":{"enabled":true},"export_tax_transactions":{"enabled":true},"financial_account_rewards":{"enabled":true},"financial_accounts":{"enabled":true},"financial_accounts_transactions":{"enabled":true},"instant_payouts_promotion":{"enabled":true},"invoice_history":{"enabled":true},"issuing_card":{"enabled":true},"issuing_cards_list":{"enabled":true},"network_cost_passthrough_report":{"enabled":true},"notification_banner":{"enabled":true},"payment_details":{"enabled":true},"payment_disputes":{"enabled":true},"payment_method_settings":{"enabled":true},"payments":{"enabled":true},"payout_details":{"enabled":true},"payout_reconciliation_report":{"enabled":true},"payouts":{"enabled":true},"payouts_list":{"enabled":true},"product_tax_code_selector":{"enabled":true},"reporting_chart":{"enabled":true},"tax_registrations":{"enabled":true},"tax_settings":{"enabled":true},"tax_threshold_monitoring":{"enabled":true},"terminal_hardware_orders":{"enabled":true},"terminal_hardware_shop":{"enabled":true}}}', + post_data='{"account":"account","components":{"account_management":{"enabled":true},"account_onboarding":{"enabled":true},"agentic_commerce_settings":{"enabled":true},"app_install":{"enabled":true},"app_viewport":{"enabled":true},"balance_report":{"enabled":true},"balances":{"enabled":true},"bills":{"enabled":true},"business_profile_management":{"enabled":true},"capital_financing":{"enabled":true},"capital_financing_application":{"enabled":true},"capital_financing_promotion":{"enabled":true},"check_scanning":{"enabled":true},"disputes_list":{"enabled":true},"documents":{"enabled":true},"export_tax_transactions":{"enabled":true},"financial_account_rewards":{"enabled":true},"financial_accounts":{"enabled":true},"financial_accounts_transactions":{"enabled":true},"instant_payouts_promotion":{"enabled":true},"invoice_history":{"enabled":true},"issuing_card":{"enabled":true},"issuing_cards_list":{"enabled":true},"network_cost_passthrough_report":{"enabled":true},"notification_banner":{"enabled":true},"payment_details":{"enabled":true},"payment_disputes":{"enabled":true},"payment_method_settings":{"enabled":true},"payments":{"enabled":true},"payout_details":{"enabled":true},"payout_reconciliation_report":{"enabled":true},"payouts":{"enabled":true},"payouts_list":{"enabled":true},"product_tax_code_selector":{"enabled":true},"reporting_chart":{"enabled":true},"tax_registrations":{"enabled":true},"tax_settings":{"enabled":true},"tax_threshold_monitoring":{"enabled":true},"terminal_hardware_orders":{"enabled":true},"terminal_hardware_shop":{"enabled":true}}}', is_json=True, ) @@ -47696,7 +47697,7 @@ def test_v2_data_analytics_metric_query_post_service( is_json=True, ) - def test_v2_data_operation_post_service( + def test_v2_data_operation_search_post_required_service( self, http_client_mock: HTTPClientMock ) -> None: http_client_mock.stub_request( @@ -47718,6 +47719,35 @@ def test_v2_data_operation_post_service( is_json=True, ) + def test_v2_data_operation_search_post_all_service( + self, http_client_mock: HTTPClientMock + ) -> None: + http_client_mock.stub_request( + "post", + "/v2/data/operations/search", + ) + client = StripeClient( + "sk_test_123", + http_client=http_client_mock.get_mock_http_client(), + ) + + client.v2.data.operations.search( + { + "catalogs": ["schemas"], + "limit": 102976443, + "page": "page", + "query": "query", + } + ) + http_client_mock.assert_requested( + "post", + path="/v2/data/operations/search", + query_string="", + api_base="https://api.stripe.com", + post_data='{"catalogs":["schemas"],"limit":102976443,"page":"page","query":"query"}', + is_json=True, + ) + def test_v2_data_query_run_post_service( self, http_client_mock: HTTPClientMock ) -> None: @@ -52263,7 +52293,33 @@ def test_v2_tax_manual_rule_post_3_service( is_json=True, ) - def test_v2_tax_operation_post_service( + def test_v2_tax_operation_resolve_address_post_required_service( + self, http_client_mock: HTTPClientMock + ) -> None: + http_client_mock.stub_request( + "post", + "/v2/tax/operations/resolve_address", + ) + client = StripeClient( + "sk_test_123", + http_client=http_client_mock.get_mock_http_client(), + ) + + client.v2.tax.operations.resolve_address( + { + "address": {"country": "country"}, + } + ) + http_client_mock.assert_requested( + "post", + path="/v2/tax/operations/resolve_address", + query_string="", + api_base="https://api.stripe.com", + post_data='{"address":{"country":"country"}}', + is_json=True, + ) + + def test_v2_tax_operation_resolve_address_post_all_service( self, http_client_mock: HTTPClientMock ) -> None: http_client_mock.stub_request(