diff --git a/.hark/changes/2026-09-18_markisaackogan_mark-path-params-as-positional-only.change.md b/.hark/changes/2026-09-18_markisaackogan_mark-path-params-as-positional-only.change.md new file mode 100644 index 000000000..f0112513d --- /dev/null +++ b/.hark/changes/2026-09-18_markisaackogan_mark-path-params-as-positional-only.change.md @@ -0,0 +1,9 @@ +--- +title: Make path parameters positional-only in all service methods +pr_url: https://github.com/stripe/stripe-python/pull/1920 +semver_level: major +--- + +Path parameters must now be passed positionally to service methods. Passing them by keyword is no longer supported. This prevents parameter names derived from the API specification from becoming part of the public interface. + + Resource methods are unaffected by this change. diff --git a/.hark/migration-guides/v16.md b/.hark/migration-guides/v16.md index d1d065a40..a505f380b 100644 --- a/.hark/migration-guides/v16.md +++ b/.hark/migration-guides/v16.md @@ -20,3 +20,21 @@ response = stripe_object.request("get", "/v1/example") client = stripe.StripeClient("sk_test_...") response = client.raw_request("get", "/v1/example") ``` + +## Keyword arguments are no longer allowed in Stripe service methods + +Path parameters in all service methods must now be passed positionally instead of by keyword. + +For example, a customer ID that was previously accepted as a keyword argument: + +```python +customer = client.v1.customers.retrieve(customer="cus_123") +``` + +must now be passed positionally: + +```python +customer = client.v1.customers.retrieve("cus_123") +``` + +Update calls to service methods, including async service methods, to pass path parameters before any request parameters or options. Resource methods are unaffected by this change. diff --git a/CHANGELOG.md b/CHANGELOG.md index cb037398e..e9ef0f2d4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,16 @@ Instead, edit a corresponding `.change.md` file and run `hark build`. # Changelog +## Unreleased +* [#1904](https://github.com/stripe/stripe-python/pull/1904) Support `EventNotification`s with singleton related objects +* [#1909](https://github.com/stripe/stripe-python/pull/1909) Allow suppressing Stripe notices + Set the `STRIPE_SUPPRESS_NOTICES` environment variable to `true` to suppress Stripe notices in test and sandbox environments when not running under a detected AI agent. Notices remain enabled by default and continue to be shown to AI agents. +* [#1911](https://github.com/stripe/stripe-python/pull/1911) Fix account scoping for event notification handler callback clients + - Fix callback clients to use the event's Stripe context and preserve the original client's non-account configuration. + - Fix API errors when using an event notification handler with a client configured with a Stripe account. +* ⚠️ [#1919](https://github.com/stripe/stripe-python/pull/1919) Make path parameters positional-only in all service methods + Path parameters must now be passed positionally to service methods. Passing them by keyword is no longer supported. Resource methods are unaffected by this change. + ## 15.6.1 - 2026-09-01 * [#1860](https://github.com/stripe/stripe-python/pull/1860) Dispatch discriminated union fields to their variant class * [#1896](https://github.com/stripe/stripe-python/pull/1896) Harden API requestor code against malicious URLs diff --git a/stripe/_account.py b/stripe/_account.py index 649080c72..00f55f3d6 100644 --- a/stripe/_account.py +++ b/stripe/_account.py @@ -1919,7 +1919,7 @@ async def list_async( @classmethod def _cls_persons( - cls, account: str, **params: Unpack["AccountPersonsParams"] + cls, account: str, /, **params: Unpack["AccountPersonsParams"] ) -> ListObject["Person"]: """ Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. @@ -1938,7 +1938,7 @@ def _cls_persons( @overload @staticmethod def persons( - account: str, **params: Unpack["AccountPersonsParams"] + account: str, /, **params: Unpack["AccountPersonsParams"] ) -> ListObject["Person"]: """ Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. @@ -1974,7 +1974,7 @@ def persons( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_persons_async( - cls, account: str, **params: Unpack["AccountPersonsParams"] + cls, account: str, /, **params: Unpack["AccountPersonsParams"] ) -> ListObject["Person"]: """ Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. @@ -1993,7 +1993,7 @@ async def _cls_persons_async( @overload @staticmethod async def persons_async( - account: str, **params: Unpack["AccountPersonsParams"] + account: str, /, **params: Unpack["AccountPersonsParams"] ) -> ListObject["Person"]: """ Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. @@ -2029,7 +2029,7 @@ async def persons_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_reject( - cls, account: str, **params: Unpack["AccountRejectParams"] + cls, account: str, /, **params: Unpack["AccountRejectParams"] ) -> "Account": """ With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious. @@ -2050,7 +2050,7 @@ def _cls_reject( @overload @staticmethod def reject( - account: str, **params: Unpack["AccountRejectParams"] + account: str, /, **params: Unpack["AccountRejectParams"] ) -> "Account": """ With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious. @@ -2090,7 +2090,7 @@ def reject( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_reject_async( - cls, account: str, **params: Unpack["AccountRejectParams"] + cls, account: str, /, **params: Unpack["AccountRejectParams"] ) -> "Account": """ With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious. @@ -2111,7 +2111,7 @@ async def _cls_reject_async( @overload @staticmethod async def reject_async( - account: str, **params: Unpack["AccountRejectParams"] + account: str, /, **params: Unpack["AccountRejectParams"] ) -> "Account": """ With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious. @@ -2153,7 +2153,7 @@ async def reject_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_unreject( - cls, account: str, **params: Unpack["AccountUnrejectParams"] + cls, account: str, /, **params: Unpack["AccountUnrejectParams"] ) -> "Account": """ With Connect, you can unreject accounts that you have previously rejected. @@ -2176,7 +2176,7 @@ def _cls_unreject( @overload @staticmethod def unreject( - account: str, **params: Unpack["AccountUnrejectParams"] + account: str, /, **params: Unpack["AccountUnrejectParams"] ) -> "Account": """ With Connect, you can unreject accounts that you have previously rejected. @@ -2222,7 +2222,7 @@ def unreject( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_unreject_async( - cls, account: str, **params: Unpack["AccountUnrejectParams"] + cls, account: str, /, **params: Unpack["AccountUnrejectParams"] ) -> "Account": """ With Connect, you can unreject accounts that you have previously rejected. @@ -2245,7 +2245,7 @@ async def _cls_unreject_async( @overload @staticmethod async def unreject_async( - account: str, **params: Unpack["AccountUnrejectParams"] + account: str, /, **params: Unpack["AccountUnrejectParams"] ) -> "Account": """ With Connect, you can unreject accounts that you have previously rejected. @@ -2343,7 +2343,7 @@ def serialize(self, previous): @classmethod def list_capabilities( - cls, account: str, **params: Unpack["AccountListCapabilitiesParams"] + cls, account: str, /, **params: Unpack["AccountListCapabilitiesParams"] ) -> ListObject["Capability"]: """ Returns a list of capabilities associated with the account. The capabilities are returned sorted by creation date, with the most recent capability appearing first. @@ -2361,7 +2361,7 @@ def list_capabilities( @classmethod async def list_capabilities_async( - cls, account: str, **params: Unpack["AccountListCapabilitiesParams"] + cls, account: str, /, **params: Unpack["AccountListCapabilitiesParams"] ) -> ListObject["Capability"]: """ Returns a list of capabilities associated with the account. The capabilities are returned sorted by creation date, with the most recent capability appearing first. @@ -2382,6 +2382,7 @@ def retrieve_capability( cls, account: str, capability: str, + /, **params: Unpack["AccountRetrieveCapabilityParams"], ) -> "Capability": """ @@ -2404,6 +2405,7 @@ async def retrieve_capability_async( cls, account: str, capability: str, + /, **params: Unpack["AccountRetrieveCapabilityParams"], ) -> "Capability": """ @@ -2426,6 +2428,7 @@ def modify_capability( cls, account: str, capability: str, + /, **params: Unpack["AccountModifyCapabilityParams"], ) -> "Capability": """ @@ -2448,6 +2451,7 @@ async def modify_capability_async( cls, account: str, capability: str, + /, **params: Unpack["AccountModifyCapabilityParams"], ) -> "Capability": """ @@ -2470,6 +2474,7 @@ def delete_external_account( cls, account: str, id: str, + /, **params: Unpack["AccountDeleteExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2491,6 +2496,7 @@ async def delete_external_account_async( cls, account: str, id: str, + /, **params: Unpack["AccountDeleteExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2512,6 +2518,7 @@ def retrieve_external_account( cls, account: str, id: str, + /, **params: Unpack["AccountRetrieveExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2533,6 +2540,7 @@ async def retrieve_external_account_async( cls, account: str, id: str, + /, **params: Unpack["AccountRetrieveExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2554,6 +2562,7 @@ def modify_external_account( cls, account: str, id: str, + /, **params: Unpack["AccountModifyExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2582,6 +2591,7 @@ async def modify_external_account_async( cls, account: str, id: str, + /, **params: Unpack["AccountModifyExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2609,6 +2619,7 @@ async def modify_external_account_async( def list_external_accounts( cls, account: str, + /, **params: Unpack["AccountListExternalAccountsParams"], ) -> ListObject[Union["BankAccount", "Card"]]: """ @@ -2629,6 +2640,7 @@ def list_external_accounts( async def list_external_accounts_async( cls, account: str, + /, **params: Unpack["AccountListExternalAccountsParams"], ) -> ListObject[Union["BankAccount", "Card"]]: """ @@ -2649,6 +2661,7 @@ async def list_external_accounts_async( def create_external_account( cls, account: str, + /, **params: Unpack["AccountCreateExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2669,6 +2682,7 @@ def create_external_account( async def create_external_account_async( cls, account: str, + /, **params: Unpack["AccountCreateExternalAccountParams"], ) -> Union["BankAccount", "Card"]: """ @@ -2687,7 +2701,7 @@ async def create_external_account_async( @classmethod def create_login_link( - cls, account: str, **params: Unpack["AccountCreateLoginLinkParams"] + cls, account: str, /, **params: Unpack["AccountCreateLoginLinkParams"] ) -> "LoginLink": """ Creates a login link for a connected account to access the Express Dashboard. @@ -2707,7 +2721,7 @@ def create_login_link( @classmethod async def create_login_link_async( - cls, account: str, **params: Unpack["AccountCreateLoginLinkParams"] + cls, account: str, /, **params: Unpack["AccountCreateLoginLinkParams"] ) -> "LoginLink": """ Creates a login link for a connected account to access the Express Dashboard. @@ -2730,6 +2744,7 @@ def delete_person( cls, account: str, person: str, + /, **params: Unpack["AccountDeletePersonParams"], ) -> "Person": """ @@ -2751,6 +2766,7 @@ async def delete_person_async( cls, account: str, person: str, + /, **params: Unpack["AccountDeletePersonParams"], ) -> "Person": """ @@ -2772,6 +2788,7 @@ def retrieve_person( cls, account: str, person: str, + /, **params: Unpack["AccountRetrievePersonParams"], ) -> "Person": """ @@ -2793,6 +2810,7 @@ async def retrieve_person_async( cls, account: str, person: str, + /, **params: Unpack["AccountRetrievePersonParams"], ) -> "Person": """ @@ -2814,6 +2832,7 @@ def modify_person( cls, account: str, person: str, + /, **params: Unpack["AccountModifyPersonParams"], ) -> "Person": """ @@ -2835,6 +2854,7 @@ async def modify_person_async( cls, account: str, person: str, + /, **params: Unpack["AccountModifyPersonParams"], ) -> "Person": """ @@ -2853,7 +2873,7 @@ async def modify_person_async( @classmethod def list_persons( - cls, account: str, **params: Unpack["AccountListPersonsParams"] + cls, account: str, /, **params: Unpack["AccountListPersonsParams"] ) -> ListObject["Person"]: """ Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. @@ -2871,7 +2891,7 @@ def list_persons( @classmethod async def list_persons_async( - cls, account: str, **params: Unpack["AccountListPersonsParams"] + cls, account: str, /, **params: Unpack["AccountListPersonsParams"] ) -> ListObject["Person"]: """ Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first. @@ -2889,7 +2909,7 @@ async def list_persons_async( @classmethod def create_person( - cls, account: str, **params: Unpack["AccountCreatePersonParams"] + cls, account: str, /, **params: Unpack["AccountCreatePersonParams"] ) -> "Person": """ Creates a new person. @@ -2907,7 +2927,7 @@ def create_person( @classmethod async def create_person_async( - cls, account: str, **params: Unpack["AccountCreatePersonParams"] + cls, account: str, /, **params: Unpack["AccountCreatePersonParams"] ) -> "Person": """ Creates a new person. diff --git a/stripe/_account_capability_service.py b/stripe/_account_capability_service.py index afe33c8c4..9c58c1a93 100644 --- a/stripe/_account_capability_service.py +++ b/stripe/_account_capability_service.py @@ -24,6 +24,7 @@ class AccountCapabilityService(StripeService): def list( self, account: str, + /, params: Optional["AccountCapabilityListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Capability]": @@ -46,6 +47,7 @@ def list( async def list_async( self, account: str, + /, params: Optional["AccountCapabilityListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Capability]": @@ -69,6 +71,7 @@ def retrieve( self, account: str, capability: str, + /, params: Optional["AccountCapabilityRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Capability": @@ -93,6 +96,7 @@ async def retrieve_async( self, account: str, capability: str, + /, params: Optional["AccountCapabilityRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Capability": @@ -117,6 +121,7 @@ def update( self, account: str, capability: str, + /, params: Optional["AccountCapabilityUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Capability": @@ -141,6 +146,7 @@ async def update_async( self, account: str, capability: str, + /, params: Optional["AccountCapabilityUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Capability": diff --git a/stripe/_account_external_account_service.py b/stripe/_account_external_account_service.py index c599096f0..4d78dae7a 100644 --- a/stripe/_account_external_account_service.py +++ b/stripe/_account_external_account_service.py @@ -33,6 +33,7 @@ def delete( self, account: str, id: str, + /, params: Optional["AccountExternalAccountDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -57,6 +58,7 @@ async def delete_async( self, account: str, id: str, + /, params: Optional["AccountExternalAccountDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -81,6 +83,7 @@ def retrieve( self, account: str, id: str, + /, params: Optional["AccountExternalAccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -105,6 +108,7 @@ async def retrieve_async( self, account: str, id: str, + /, params: Optional["AccountExternalAccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -129,6 +133,7 @@ def update( self, account: str, id: str, + /, params: Optional["AccountExternalAccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -160,6 +165,7 @@ async def update_async( self, account: str, id: str, + /, params: Optional["AccountExternalAccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -190,6 +196,7 @@ async def update_async( def list( self, account: str, + /, params: Optional["AccountExternalAccountListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Union[BankAccount, Card]]": @@ -212,6 +219,7 @@ def list( async def list_async( self, account: str, + /, params: Optional["AccountExternalAccountListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Union[BankAccount, Card]]": @@ -234,6 +242,7 @@ async def list_async( def create( self, account: str, + /, params: "AccountExternalAccountCreateParams", options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": @@ -256,6 +265,7 @@ def create( async def create_async( self, account: str, + /, params: "AccountExternalAccountCreateParams", options: Optional["RequestOptions"] = None, ) -> "Union[BankAccount, Card]": diff --git a/stripe/_account_login_link_service.py b/stripe/_account_login_link_service.py index 39212510d..bee20933e 100644 --- a/stripe/_account_login_link_service.py +++ b/stripe/_account_login_link_service.py @@ -17,6 +17,7 @@ class AccountLoginLinkService(StripeService): def create( self, account: str, + /, params: Optional["AccountLoginLinkCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "LoginLink": @@ -41,6 +42,7 @@ def create( async def create_async( self, account: str, + /, params: Optional["AccountLoginLinkCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "LoginLink": diff --git a/stripe/_account_person_service.py b/stripe/_account_person_service.py index 1720d8c1a..d0b6748fa 100644 --- a/stripe/_account_person_service.py +++ b/stripe/_account_person_service.py @@ -31,6 +31,7 @@ def delete( self, account: str, person: str, + /, params: Optional["AccountPersonDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -55,6 +56,7 @@ async def delete_async( self, account: str, person: str, + /, params: Optional["AccountPersonDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -79,6 +81,7 @@ def retrieve( self, account: str, person: str, + /, params: Optional["AccountPersonRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -103,6 +106,7 @@ async def retrieve_async( self, account: str, person: str, + /, params: Optional["AccountPersonRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -127,6 +131,7 @@ def update( self, account: str, person: str, + /, params: Optional["AccountPersonUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -151,6 +156,7 @@ async def update_async( self, account: str, person: str, + /, params: Optional["AccountPersonUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -174,6 +180,7 @@ async def update_async( def list( self, account: str, + /, params: Optional["AccountPersonListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Person]": @@ -196,6 +203,7 @@ def list( async def list_async( self, account: str, + /, params: Optional["AccountPersonListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Person]": @@ -218,6 +226,7 @@ async def list_async( def create( self, account: str, + /, params: Optional["AccountPersonCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": @@ -240,6 +249,7 @@ def create( async def create_async( self, account: str, + /, params: Optional["AccountPersonCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Person": diff --git a/stripe/_account_service.py b/stripe/_account_service.py index f38963b99..e813d438e 100644 --- a/stripe/_account_service.py +++ b/stripe/_account_service.py @@ -72,6 +72,7 @@ def __getattr__(self, name): def delete( self, account: str, + /, params: Optional["AccountDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -98,6 +99,7 @@ def delete( async def delete_async( self, account: str, + /, params: Optional["AccountDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -124,6 +126,7 @@ async def delete_async( def retrieve( self, account: str, + /, params: Optional["AccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -144,6 +147,7 @@ def retrieve( async def retrieve_async( self, account: str, + /, params: Optional["AccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -164,6 +168,7 @@ async def retrieve_async( def update( self, account: str, + /, params: Optional["AccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -196,6 +201,7 @@ def update( async def update_async( self, account: str, + /, params: Optional["AccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -352,6 +358,7 @@ async def create_async( def reject( self, account: str, + /, params: "AccountRejectParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -376,6 +383,7 @@ def reject( async def reject_async( self, account: str, + /, params: "AccountRejectParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -400,6 +408,7 @@ async def reject_async( def unreject( self, account: str, + /, params: Optional["AccountUnrejectParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -426,6 +435,7 @@ def unreject( async def unreject_async( self, account: str, + /, params: Optional["AccountUnrejectParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": diff --git a/stripe/_api_requestor.py b/stripe/_api_requestor.py index 37f2011db..e94147c5e 100644 --- a/stripe/_api_requestor.py +++ b/stripe/_api_requestor.py @@ -518,6 +518,7 @@ def specific_oauth_error(self, rbody, rcode, resp, rheaders, error_code): ("CODEX_CI", "codex_cli"), ("CURSOR_AGENT", "cursor"), ("GEMINI_CLI", "gemini_cli"), + ("HERMES_AGENT", "hermes"), ("OPENCLAW_SHELL", "openclaw"), ("OPENCODE", "open_code"), # aiAgents: The end of the section generated from our OpenAPI spec diff --git a/stripe/_apple_pay_domain_service.py b/stripe/_apple_pay_domain_service.py index 6c72f7d65..beb0b6559 100644 --- a/stripe/_apple_pay_domain_service.py +++ b/stripe/_apple_pay_domain_service.py @@ -27,6 +27,7 @@ class ApplePayDomainService(StripeService): def delete( self, domain: str, + /, params: Optional["ApplePayDomainDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplePayDomain": @@ -49,6 +50,7 @@ def delete( async def delete_async( self, domain: str, + /, params: Optional["ApplePayDomainDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplePayDomain": @@ -71,6 +73,7 @@ async def delete_async( def retrieve( self, domain: str, + /, params: Optional["ApplePayDomainRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplePayDomain": @@ -93,6 +96,7 @@ def retrieve( async def retrieve_async( self, domain: str, + /, params: Optional["ApplePayDomainRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplePayDomain": diff --git a/stripe/_application_fee.py b/stripe/_application_fee.py index a1db92e4e..b99021d30 100644 --- a/stripe/_application_fee.py +++ b/stripe/_application_fee.py @@ -159,7 +159,7 @@ async def list_async( @classmethod def _cls_refund( - cls, id: str, **params: Unpack["ApplicationFeeRefundParams"] + cls, id: str, /, **params: Unpack["ApplicationFeeRefundParams"] ) -> "ApplicationFeeRefund": """ Refunds an application fee that has previously been collected but not yet refunded. @@ -184,7 +184,7 @@ def _cls_refund( @overload @staticmethod def refund( - id: str, **params: Unpack["ApplicationFeeRefundParams"] + id: str, /, **params: Unpack["ApplicationFeeRefundParams"] ) -> "ApplicationFeeRefund": """ Refunds an application fee that has previously been collected but not yet refunded. @@ -244,7 +244,7 @@ def refund( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_refund_async( - cls, id: str, **params: Unpack["ApplicationFeeRefundParams"] + cls, id: str, /, **params: Unpack["ApplicationFeeRefundParams"] ) -> "ApplicationFeeRefund": """ Refunds an application fee that has previously been collected but not yet refunded. @@ -269,7 +269,7 @@ async def _cls_refund_async( @overload @staticmethod async def refund_async( - id: str, **params: Unpack["ApplicationFeeRefundParams"] + id: str, /, **params: Unpack["ApplicationFeeRefundParams"] ) -> "ApplicationFeeRefund": """ Refunds an application fee that has previously been collected but not yet refunded. @@ -354,6 +354,7 @@ def retrieve_refund( cls, fee: str, id: str, + /, **params: Unpack["ApplicationFeeRetrieveRefundParams"], ) -> "ApplicationFeeRefund": """ @@ -375,6 +376,7 @@ async def retrieve_refund_async( cls, fee: str, id: str, + /, **params: Unpack["ApplicationFeeRetrieveRefundParams"], ) -> "ApplicationFeeRefund": """ @@ -396,6 +398,7 @@ def modify_refund( cls, fee: str, id: str, + /, **params: Unpack["ApplicationFeeModifyRefundParams"], ) -> "ApplicationFeeRefund": """ @@ -419,6 +422,7 @@ async def modify_refund_async( cls, fee: str, id: str, + /, **params: Unpack["ApplicationFeeModifyRefundParams"], ) -> "ApplicationFeeRefund": """ @@ -439,7 +443,7 @@ async def modify_refund_async( @classmethod def list_refunds( - cls, id: str, **params: Unpack["ApplicationFeeListRefundsParams"] + cls, id: str, /, **params: Unpack["ApplicationFeeListRefundsParams"] ) -> ListObject["ApplicationFeeRefund"]: """ You can see a list of the refunds belonging to a specific application fee. Note that the 10 most recent refunds are always available by default on the application fee object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds. @@ -455,7 +459,7 @@ def list_refunds( @classmethod async def list_refunds_async( - cls, id: str, **params: Unpack["ApplicationFeeListRefundsParams"] + cls, id: str, /, **params: Unpack["ApplicationFeeListRefundsParams"] ) -> ListObject["ApplicationFeeRefund"]: """ You can see a list of the refunds belonging to a specific application fee. Note that the 10 most recent refunds are always available by default on the application fee object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds. @@ -471,7 +475,7 @@ async def list_refunds_async( @classmethod def create_refund( - cls, id: str, **params: Unpack["ApplicationFeeCreateRefundParams"] + cls, id: str, /, **params: Unpack["ApplicationFeeCreateRefundParams"] ) -> "ApplicationFeeRefund": """ Refunds an application fee that has previously been collected but not yet refunded. @@ -495,7 +499,7 @@ def create_refund( @classmethod async def create_refund_async( - cls, id: str, **params: Unpack["ApplicationFeeCreateRefundParams"] + cls, id: str, /, **params: Unpack["ApplicationFeeCreateRefundParams"] ) -> "ApplicationFeeRefund": """ Refunds an application fee that has previously been collected but not yet refunded. diff --git a/stripe/_application_fee_refund_service.py b/stripe/_application_fee_refund_service.py index 1f109689e..ed0180ce1 100644 --- a/stripe/_application_fee_refund_service.py +++ b/stripe/_application_fee_refund_service.py @@ -28,6 +28,7 @@ def retrieve( self, fee: str, id: str, + /, params: Optional["ApplicationFeeRefundRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFeeRefund": @@ -52,6 +53,7 @@ async def retrieve_async( self, fee: str, id: str, + /, params: Optional["ApplicationFeeRefundRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFeeRefund": @@ -76,6 +78,7 @@ def update( self, fee: str, id: str, + /, params: Optional["ApplicationFeeRefundUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFeeRefund": @@ -102,6 +105,7 @@ async def update_async( self, fee: str, id: str, + /, params: Optional["ApplicationFeeRefundUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFeeRefund": @@ -127,6 +131,7 @@ async def update_async( def list( self, id: str, + /, params: Optional["ApplicationFeeRefundListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[ApplicationFeeRefund]": @@ -147,6 +152,7 @@ def list( async def list_async( self, id: str, + /, params: Optional["ApplicationFeeRefundListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[ApplicationFeeRefund]": @@ -167,6 +173,7 @@ async def list_async( def create( self, id: str, + /, params: Optional["ApplicationFeeRefundCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFeeRefund": @@ -195,6 +202,7 @@ def create( async def create_async( self, id: str, + /, params: Optional["ApplicationFeeRefundCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFeeRefund": diff --git a/stripe/_application_fee_service.py b/stripe/_application_fee_service.py index 814c3ad95..1926ea117 100644 --- a/stripe/_application_fee_service.py +++ b/stripe/_application_fee_service.py @@ -91,6 +91,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["ApplicationFeeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFee": @@ -111,6 +112,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["ApplicationFeeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ApplicationFee": diff --git a/stripe/_balance_transaction_service.py b/stripe/_balance_transaction_service.py index 2166a14fc..44c7eb0c1 100644 --- a/stripe/_balance_transaction_service.py +++ b/stripe/_balance_transaction_service.py @@ -63,6 +63,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["BalanceTransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "BalanceTransaction": @@ -85,6 +86,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["BalanceTransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "BalanceTransaction": diff --git a/stripe/_charge.py b/stripe/_charge.py index f46178727..24f3e833b 100644 --- a/stripe/_charge.py +++ b/stripe/_charge.py @@ -2553,7 +2553,7 @@ class TransferData(StripeObject): @classmethod def _cls_capture( - cls, charge: str, **params: Unpack["ChargeCaptureParams"] + cls, charge: str, /, **params: Unpack["ChargeCaptureParams"] ) -> "Charge": """ Capture the payment of an existing, uncaptured charge that was created with the capture option set to false. @@ -2576,7 +2576,7 @@ def _cls_capture( @overload @staticmethod def capture( - charge: str, **params: Unpack["ChargeCaptureParams"] + charge: str, /, **params: Unpack["ChargeCaptureParams"] ) -> "Charge": """ Capture the payment of an existing, uncaptured charge that was created with the capture option set to false. @@ -2622,7 +2622,7 @@ def capture( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_capture_async( - cls, charge: str, **params: Unpack["ChargeCaptureParams"] + cls, charge: str, /, **params: Unpack["ChargeCaptureParams"] ) -> "Charge": """ Capture the payment of an existing, uncaptured charge that was created with the capture option set to false. @@ -2645,7 +2645,7 @@ async def _cls_capture_async( @overload @staticmethod async def capture_async( - charge: str, **params: Unpack["ChargeCaptureParams"] + charge: str, /, **params: Unpack["ChargeCaptureParams"] ) -> "Charge": """ Capture the payment of an existing, uncaptured charge that was created with the capture option set to false. @@ -2882,6 +2882,7 @@ def retrieve_refund( cls, charge: str, refund: str, + /, **params: Unpack["ChargeRetrieveRefundParams"], ) -> "Refund": """ @@ -2903,6 +2904,7 @@ async def retrieve_refund_async( cls, charge: str, refund: str, + /, **params: Unpack["ChargeRetrieveRefundParams"], ) -> "Refund": """ @@ -2921,7 +2923,7 @@ async def retrieve_refund_async( @classmethod def list_refunds( - cls, charge: str, **params: Unpack["ChargeListRefundsParams"] + cls, charge: str, /, **params: Unpack["ChargeListRefundsParams"] ) -> ListObject["Refund"]: """ You can see a list of the refunds belonging to a specific charge. Note that the 10 most recent refunds are always available by default on the charge object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds. @@ -2939,7 +2941,7 @@ def list_refunds( @classmethod async def list_refunds_async( - cls, charge: str, **params: Unpack["ChargeListRefundsParams"] + cls, charge: str, /, **params: Unpack["ChargeListRefundsParams"] ) -> ListObject["Refund"]: """ You can see a list of the refunds belonging to a specific charge. Note that the 10 most recent refunds are always available by default on the charge object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds. diff --git a/stripe/_charge_service.py b/stripe/_charge_service.py index 2fca76593..a0acadb50 100644 --- a/stripe/_charge_service.py +++ b/stripe/_charge_service.py @@ -102,6 +102,7 @@ async def create_async( def retrieve( self, charge: str, + /, params: Optional["ChargeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Charge": @@ -122,6 +123,7 @@ def retrieve( async def retrieve_async( self, charge: str, + /, params: Optional["ChargeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Charge": @@ -142,6 +144,7 @@ async def retrieve_async( def update( self, charge: str, + /, params: Optional["ChargeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Charge": @@ -162,6 +165,7 @@ def update( async def update_async( self, charge: str, + /, params: Optional["ChargeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Charge": @@ -226,6 +230,7 @@ async def search_async( def capture( self, charge: str, + /, params: Optional["ChargeCaptureParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Charge": @@ -252,6 +257,7 @@ def capture( async def capture_async( self, charge: str, + /, params: Optional["ChargeCaptureParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Charge": diff --git a/stripe/_confirmation_token_service.py b/stripe/_confirmation_token_service.py index 066b43fcf..cccbceccd 100644 --- a/stripe/_confirmation_token_service.py +++ b/stripe/_confirmation_token_service.py @@ -17,6 +17,7 @@ class ConfirmationTokenService(StripeService): def retrieve( self, confirmation_token: str, + /, params: Optional["ConfirmationTokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ConfirmationToken": @@ -39,6 +40,7 @@ def retrieve( async def retrieve_async( self, confirmation_token: str, + /, params: Optional["ConfirmationTokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ConfirmationToken": diff --git a/stripe/_country_spec_service.py b/stripe/_country_spec_service.py index b5e14736e..135ca9160 100644 --- a/stripe/_country_spec_service.py +++ b/stripe/_country_spec_service.py @@ -57,6 +57,7 @@ async def list_async( def retrieve( self, country: str, + /, params: Optional["CountrySpecRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CountrySpec": @@ -79,6 +80,7 @@ def retrieve( async def retrieve_async( self, country: str, + /, params: Optional["CountrySpecRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CountrySpec": diff --git a/stripe/_coupon_service.py b/stripe/_coupon_service.py index c927d272c..46b383138 100644 --- a/stripe/_coupon_service.py +++ b/stripe/_coupon_service.py @@ -20,6 +20,7 @@ class CouponService(StripeService): def delete( self, coupon: str, + /, params: Optional["CouponDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Coupon": @@ -40,6 +41,7 @@ def delete( async def delete_async( self, coupon: str, + /, params: Optional["CouponDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Coupon": @@ -60,6 +62,7 @@ async def delete_async( def retrieve( self, coupon: str, + /, params: Optional["CouponRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Coupon": @@ -80,6 +83,7 @@ def retrieve( async def retrieve_async( self, coupon: str, + /, params: Optional["CouponRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Coupon": @@ -100,6 +104,7 @@ async def retrieve_async( def update( self, coupon: str, + /, params: Optional["CouponUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Coupon": @@ -120,6 +125,7 @@ def update( async def update_async( self, coupon: str, + /, params: Optional["CouponUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Coupon": diff --git a/stripe/_credit_note.py b/stripe/_credit_note.py index 3eb6a8657..1a1665317 100644 --- a/stripe/_credit_note.py +++ b/stripe/_credit_note.py @@ -604,7 +604,7 @@ async def retrieve_async( @classmethod def _cls_void_credit_note( - cls, id: str, **params: Unpack["CreditNoteVoidCreditNoteParams"] + cls, id: str, /, **params: Unpack["CreditNoteVoidCreditNoteParams"] ) -> "CreditNote": """ Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding). @@ -621,7 +621,7 @@ def _cls_void_credit_note( @overload @staticmethod def void_credit_note( - id: str, **params: Unpack["CreditNoteVoidCreditNoteParams"] + id: str, /, **params: Unpack["CreditNoteVoidCreditNoteParams"] ) -> "CreditNote": """ Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding). @@ -657,7 +657,7 @@ def void_credit_note( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_void_credit_note_async( - cls, id: str, **params: Unpack["CreditNoteVoidCreditNoteParams"] + cls, id: str, /, **params: Unpack["CreditNoteVoidCreditNoteParams"] ) -> "CreditNote": """ Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding). @@ -674,7 +674,7 @@ async def _cls_void_credit_note_async( @overload @staticmethod async def void_credit_note_async( - id: str, **params: Unpack["CreditNoteVoidCreditNoteParams"] + id: str, /, **params: Unpack["CreditNoteVoidCreditNoteParams"] ) -> "CreditNote": """ Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding). @@ -710,7 +710,7 @@ async def void_credit_note_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def list_lines( - cls, credit_note: str, **params: Unpack["CreditNoteListLinesParams"] + cls, credit_note: str, /, **params: Unpack["CreditNoteListLinesParams"] ) -> ListObject["CreditNoteLineItem"]: """ When retrieving a credit note, you'll get a lines property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -728,7 +728,7 @@ def list_lines( @classmethod async def list_lines_async( - cls, credit_note: str, **params: Unpack["CreditNoteListLinesParams"] + cls, credit_note: str, /, **params: Unpack["CreditNoteListLinesParams"] ) -> ListObject["CreditNoteLineItem"]: """ When retrieving a credit note, you'll get a lines property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. diff --git a/stripe/_credit_note_line_item_service.py b/stripe/_credit_note_line_item_service.py index e5b85b2d5..ea1f5d098 100644 --- a/stripe/_credit_note_line_item_service.py +++ b/stripe/_credit_note_line_item_service.py @@ -18,6 +18,7 @@ class CreditNoteLineItemService(StripeService): def list( self, credit_note: str, + /, params: Optional["CreditNoteLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CreditNoteLineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, credit_note: str, + /, params: Optional["CreditNoteLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CreditNoteLineItem]": diff --git a/stripe/_credit_note_service.py b/stripe/_credit_note_service.py index ab9ea98e9..089760b4d 100644 --- a/stripe/_credit_note_service.py +++ b/stripe/_credit_note_service.py @@ -169,6 +169,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["CreditNoteRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditNote": @@ -189,6 +190,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["CreditNoteRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditNote": @@ -209,6 +211,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["CreditNoteUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditNote": @@ -229,6 +232,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["CreditNoteUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditNote": @@ -287,6 +291,7 @@ async def preview_async( def void_credit_note( self, id: str, + /, params: Optional["CreditNoteVoidCreditNoteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditNote": @@ -307,6 +312,7 @@ def void_credit_note( async def void_credit_note_async( self, id: str, + /, params: Optional["CreditNoteVoidCreditNoteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditNote": diff --git a/stripe/_customer.py b/stripe/_customer.py index 9ef7186a0..282e5a4f8 100644 --- a/stripe/_customer.py +++ b/stripe/_customer.py @@ -462,6 +462,7 @@ async def create_async( def _cls_create_funding_instructions( cls, customer: str, + /, **params: Unpack["CustomerCreateFundingInstructionsParams"], ) -> "FundingInstructions": """ @@ -484,6 +485,7 @@ def _cls_create_funding_instructions( @staticmethod def create_funding_instructions( customer: str, + /, **params: Unpack["CustomerCreateFundingInstructionsParams"], ) -> "FundingInstructions": """ @@ -528,6 +530,7 @@ def create_funding_instructions( # pyright: ignore[reportGeneralTypeIssues] async def _cls_create_funding_instructions_async( cls, customer: str, + /, **params: Unpack["CustomerCreateFundingInstructionsParams"], ) -> "FundingInstructions": """ @@ -550,6 +553,7 @@ async def _cls_create_funding_instructions_async( @staticmethod async def create_funding_instructions_async( customer: str, + /, **params: Unpack["CustomerCreateFundingInstructionsParams"], ) -> "FundingInstructions": """ @@ -688,7 +692,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_delete_discount( - cls, customer: str, **params: Unpack["CustomerDeleteDiscountParams"] + cls, customer: str, /, **params: Unpack["CustomerDeleteDiscountParams"] ) -> "Discount": """ Removes the currently applied discount on a customer. @@ -707,7 +711,7 @@ def _cls_delete_discount( @overload @staticmethod def delete_discount( - customer: str, **params: Unpack["CustomerDeleteDiscountParams"] + customer: str, /, **params: Unpack["CustomerDeleteDiscountParams"] ) -> "Discount": """ Removes the currently applied discount on a customer. @@ -743,7 +747,7 @@ def delete_discount( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_delete_discount_async( - cls, customer: str, **params: Unpack["CustomerDeleteDiscountParams"] + cls, customer: str, /, **params: Unpack["CustomerDeleteDiscountParams"] ) -> "Discount": """ Removes the currently applied discount on a customer. @@ -762,7 +766,7 @@ async def _cls_delete_discount_async( @overload @staticmethod async def delete_discount_async( - customer: str, **params: Unpack["CustomerDeleteDiscountParams"] + customer: str, /, **params: Unpack["CustomerDeleteDiscountParams"] ) -> "Discount": """ Removes the currently applied discount on a customer. @@ -840,6 +844,7 @@ async def list_async( def _cls_list_payment_methods( cls, customer: str, + /, **params: Unpack["CustomerListPaymentMethodsParams"], ) -> ListObject["PaymentMethod"]: """ @@ -859,7 +864,7 @@ def _cls_list_payment_methods( @overload @staticmethod def list_payment_methods( - customer: str, **params: Unpack["CustomerListPaymentMethodsParams"] + customer: str, /, **params: Unpack["CustomerListPaymentMethodsParams"] ) -> ListObject["PaymentMethod"]: """ Returns a list of PaymentMethods for a given Customer @@ -897,6 +902,7 @@ def list_payment_methods( # pyright: ignore[reportGeneralTypeIssues] async def _cls_list_payment_methods_async( cls, customer: str, + /, **params: Unpack["CustomerListPaymentMethodsParams"], ) -> ListObject["PaymentMethod"]: """ @@ -916,7 +922,7 @@ async def _cls_list_payment_methods_async( @overload @staticmethod async def list_payment_methods_async( - customer: str, **params: Unpack["CustomerListPaymentMethodsParams"] + customer: str, /, **params: Unpack["CustomerListPaymentMethodsParams"] ) -> ListObject["PaymentMethod"]: """ Returns a list of PaymentMethods for a given Customer @@ -1015,6 +1021,7 @@ def _cls_retrieve_payment_method( cls, customer: str, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1037,6 +1044,7 @@ def _cls_retrieve_payment_method( def retrieve_payment_method( customer: str, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1048,6 +1056,7 @@ def retrieve_payment_method( def retrieve_payment_method( self, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1059,6 +1068,7 @@ def retrieve_payment_method( def retrieve_payment_method( # pyright: ignore[reportGeneralTypeIssues] self, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1081,6 +1091,7 @@ async def _cls_retrieve_payment_method_async( cls, customer: str, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1103,6 +1114,7 @@ async def _cls_retrieve_payment_method_async( async def retrieve_payment_method_async( customer: str, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1114,6 +1126,7 @@ async def retrieve_payment_method_async( async def retrieve_payment_method_async( self, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1125,6 +1138,7 @@ async def retrieve_payment_method_async( async def retrieve_payment_method_async( # pyright: ignore[reportGeneralTypeIssues] self, payment_method: str, + /, **params: Unpack["CustomerRetrievePaymentMethodParams"], ) -> "PaymentMethod": """ @@ -1184,6 +1198,7 @@ async def search_auto_paging_iter_async( def list_balance_transactions( cls, customer: str, + /, **params: Unpack["CustomerListBalanceTransactionsParams"], ) -> ListObject["CustomerBalanceTransaction"]: """ @@ -1204,6 +1219,7 @@ def list_balance_transactions( async def list_balance_transactions_async( cls, customer: str, + /, **params: Unpack["CustomerListBalanceTransactionsParams"], ) -> ListObject["CustomerBalanceTransaction"]: """ @@ -1224,6 +1240,7 @@ async def list_balance_transactions_async( def create_balance_transaction( cls, customer: str, + /, **params: Unpack["CustomerCreateBalanceTransactionParams"], ) -> "CustomerBalanceTransaction": """ @@ -1244,6 +1261,7 @@ def create_balance_transaction( async def create_balance_transaction_async( cls, customer: str, + /, **params: Unpack["CustomerCreateBalanceTransactionParams"], ) -> "CustomerBalanceTransaction": """ @@ -1265,6 +1283,7 @@ def retrieve_balance_transaction( cls, customer: str, transaction: str, + /, **params: Unpack["CustomerRetrieveBalanceTransactionParams"], ) -> "CustomerBalanceTransaction": """ @@ -1287,6 +1306,7 @@ async def retrieve_balance_transaction_async( cls, customer: str, transaction: str, + /, **params: Unpack["CustomerRetrieveBalanceTransactionParams"], ) -> "CustomerBalanceTransaction": """ @@ -1309,6 +1329,7 @@ def modify_balance_transaction( cls, customer: str, transaction: str, + /, **params: Unpack["CustomerModifyBalanceTransactionParams"], ) -> "CustomerBalanceTransaction": """ @@ -1331,6 +1352,7 @@ async def modify_balance_transaction_async( cls, customer: str, transaction: str, + /, **params: Unpack["CustomerModifyBalanceTransactionParams"], ) -> "CustomerBalanceTransaction": """ @@ -1352,6 +1374,7 @@ async def modify_balance_transaction_async( def list_cash_balance_transactions( cls, customer: str, + /, **params: Unpack["CustomerListCashBalanceTransactionsParams"], ) -> ListObject["CustomerCashBalanceTransaction"]: """ @@ -1372,6 +1395,7 @@ def list_cash_balance_transactions( async def list_cash_balance_transactions_async( cls, customer: str, + /, **params: Unpack["CustomerListCashBalanceTransactionsParams"], ) -> ListObject["CustomerCashBalanceTransaction"]: """ @@ -1393,6 +1417,7 @@ def retrieve_cash_balance_transaction( cls, customer: str, transaction: str, + /, **params: Unpack["CustomerRetrieveCashBalanceTransactionParams"], ) -> "CustomerCashBalanceTransaction": """ @@ -1415,6 +1440,7 @@ async def retrieve_cash_balance_transaction_async( cls, customer: str, transaction: str, + /, **params: Unpack["CustomerRetrieveCashBalanceTransactionParams"], ) -> "CustomerCashBalanceTransaction": """ @@ -1434,7 +1460,7 @@ async def retrieve_cash_balance_transaction_async( @classmethod def list_sources( - cls, customer: str, **params: Unpack["CustomerListSourcesParams"] + cls, customer: str, /, **params: Unpack["CustomerListSourcesParams"] ) -> ListObject[Union["Account", "BankAccount", "Card", "Source"]]: """ List sources for a specified customer. @@ -1452,7 +1478,7 @@ def list_sources( @classmethod async def list_sources_async( - cls, customer: str, **params: Unpack["CustomerListSourcesParams"] + cls, customer: str, /, **params: Unpack["CustomerListSourcesParams"] ) -> ListObject[Union["Account", "BankAccount", "Card", "Source"]]: """ List sources for a specified customer. @@ -1470,7 +1496,7 @@ async def list_sources_async( @classmethod def create_source( - cls, customer: str, **params: Unpack["CustomerCreateSourceParams"] + cls, customer: str, /, **params: Unpack["CustomerCreateSourceParams"] ) -> Union["Account", "BankAccount", "Card", "Source"]: """ When you create a new credit card, you must specify a customer or recipient on which to create it. @@ -1492,7 +1518,7 @@ def create_source( @classmethod async def create_source_async( - cls, customer: str, **params: Unpack["CustomerCreateSourceParams"] + cls, customer: str, /, **params: Unpack["CustomerCreateSourceParams"] ) -> Union["Account", "BankAccount", "Card", "Source"]: """ When you create a new credit card, you must specify a customer or recipient on which to create it. @@ -1517,6 +1543,7 @@ def retrieve_source( cls, customer: str, id: str, + /, **params: Unpack["CustomerRetrieveSourceParams"], ) -> Union["Account", "BankAccount", "Card", "Source"]: """ @@ -1538,6 +1565,7 @@ async def retrieve_source_async( cls, customer: str, id: str, + /, **params: Unpack["CustomerRetrieveSourceParams"], ) -> Union["Account", "BankAccount", "Card", "Source"]: """ @@ -1559,6 +1587,7 @@ def modify_source( cls, customer: str, id: str, + /, **params: Unpack["CustomerModifySourceParams"], ) -> Union["Account", "BankAccount", "Card", "Source"]: """ @@ -1580,6 +1609,7 @@ async def modify_source_async( cls, customer: str, id: str, + /, **params: Unpack["CustomerModifySourceParams"], ) -> Union["Account", "BankAccount", "Card", "Source"]: """ @@ -1601,6 +1631,7 @@ def delete_source( cls, customer: str, id: str, + /, **params: Unpack["CustomerDeleteSourceParams"], ) -> Union["Account", "BankAccount", "Card", "Source"]: """ @@ -1622,6 +1653,7 @@ async def delete_source_async( cls, customer: str, id: str, + /, **params: Unpack["CustomerDeleteSourceParams"], ) -> Union["Account", "BankAccount", "Card", "Source"]: """ @@ -1640,7 +1672,7 @@ async def delete_source_async( @classmethod def create_tax_id( - cls, customer: str, **params: Unpack["CustomerCreateTaxIdParams"] + cls, customer: str, /, **params: Unpack["CustomerCreateTaxIdParams"] ) -> "TaxId": """ Creates a new tax_id object for a customer. @@ -1658,7 +1690,7 @@ def create_tax_id( @classmethod async def create_tax_id_async( - cls, customer: str, **params: Unpack["CustomerCreateTaxIdParams"] + cls, customer: str, /, **params: Unpack["CustomerCreateTaxIdParams"] ) -> "TaxId": """ Creates a new tax_id object for a customer. @@ -1679,6 +1711,7 @@ def retrieve_tax_id( cls, customer: str, id: str, + /, **params: Unpack["CustomerRetrieveTaxIdParams"], ) -> "TaxId": """ @@ -1700,6 +1733,7 @@ async def retrieve_tax_id_async( cls, customer: str, id: str, + /, **params: Unpack["CustomerRetrieveTaxIdParams"], ) -> "TaxId": """ @@ -1721,6 +1755,7 @@ def delete_tax_id( cls, customer: str, id: str, + /, **params: Unpack["CustomerDeleteTaxIdParams"], ) -> "TaxId": """ @@ -1742,6 +1777,7 @@ async def delete_tax_id_async( cls, customer: str, id: str, + /, **params: Unpack["CustomerDeleteTaxIdParams"], ) -> "TaxId": """ @@ -1760,7 +1796,7 @@ async def delete_tax_id_async( @classmethod def list_tax_ids( - cls, customer: str, **params: Unpack["CustomerListTaxIdsParams"] + cls, customer: str, /, **params: Unpack["CustomerListTaxIdsParams"] ) -> ListObject["TaxId"]: """ Returns a list of tax IDs for a customer. @@ -1778,7 +1814,7 @@ def list_tax_ids( @classmethod async def list_tax_ids_async( - cls, customer: str, **params: Unpack["CustomerListTaxIdsParams"] + cls, customer: str, /, **params: Unpack["CustomerListTaxIdsParams"] ) -> ListObject["TaxId"]: """ Returns a list of tax IDs for a customer. @@ -1798,6 +1834,7 @@ async def list_tax_ids_async( def retrieve_cash_balance( cls, customer: str, + /, **params: Unpack["CustomerRetrieveCashBalanceParams"], ) -> "CashBalance": """ @@ -1818,6 +1855,7 @@ def retrieve_cash_balance( async def retrieve_cash_balance_async( cls, customer: str, + /, **params: Unpack["CustomerRetrieveCashBalanceParams"], ) -> "CashBalance": """ @@ -1836,7 +1874,10 @@ async def retrieve_cash_balance_async( @classmethod def modify_cash_balance( - cls, customer: str, **params: Unpack["CustomerModifyCashBalanceParams"] + cls, + customer: str, + /, + **params: Unpack["CustomerModifyCashBalanceParams"], ) -> "CashBalance": """ Changes the settings on a customer's cash balance. @@ -1854,7 +1895,10 @@ def modify_cash_balance( @classmethod async def modify_cash_balance_async( - cls, customer: str, **params: Unpack["CustomerModifyCashBalanceParams"] + cls, + customer: str, + /, + **params: Unpack["CustomerModifyCashBalanceParams"], ) -> "CashBalance": """ Changes the settings on a customer's cash balance. @@ -1877,6 +1921,7 @@ class TestHelpers(APIResourceTestHelpers["Customer"]): def _cls_fund_cash_balance( cls, customer: str, + /, **params: Unpack["CustomerFundCashBalanceParams"], ) -> "CustomerCashBalanceTransaction": """ @@ -1896,7 +1941,7 @@ def _cls_fund_cash_balance( @overload @staticmethod def fund_cash_balance( - customer: str, **params: Unpack["CustomerFundCashBalanceParams"] + customer: str, /, **params: Unpack["CustomerFundCashBalanceParams"] ) -> "CustomerCashBalanceTransaction": """ Create an incoming testmode bank transfer @@ -1934,6 +1979,7 @@ def fund_cash_balance( # pyright: ignore[reportGeneralTypeIssues] async def _cls_fund_cash_balance_async( cls, customer: str, + /, **params: Unpack["CustomerFundCashBalanceParams"], ) -> "CustomerCashBalanceTransaction": """ @@ -1953,7 +1999,7 @@ async def _cls_fund_cash_balance_async( @overload @staticmethod async def fund_cash_balance_async( - customer: str, **params: Unpack["CustomerFundCashBalanceParams"] + customer: str, /, **params: Unpack["CustomerFundCashBalanceParams"] ) -> "CustomerCashBalanceTransaction": """ Create an incoming testmode bank transfer diff --git a/stripe/_customer_balance_transaction_service.py b/stripe/_customer_balance_transaction_service.py index 5a4feab8c..5c52b89da 100644 --- a/stripe/_customer_balance_transaction_service.py +++ b/stripe/_customer_balance_transaction_service.py @@ -27,6 +27,7 @@ class CustomerBalanceTransactionService(StripeService): def list( self, customer: str, + /, params: Optional["CustomerBalanceTransactionListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CustomerBalanceTransaction]": @@ -49,6 +50,7 @@ def list( async def list_async( self, customer: str, + /, params: Optional["CustomerBalanceTransactionListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CustomerBalanceTransaction]": @@ -71,6 +73,7 @@ async def list_async( def create( self, customer: str, + /, params: "CustomerBalanceTransactionCreateParams", options: Optional["RequestOptions"] = None, ) -> "CustomerBalanceTransaction": @@ -93,6 +96,7 @@ def create( async def create_async( self, customer: str, + /, params: "CustomerBalanceTransactionCreateParams", options: Optional["RequestOptions"] = None, ) -> "CustomerBalanceTransaction": @@ -116,6 +120,7 @@ def retrieve( self, customer: str, transaction: str, + /, params: Optional["CustomerBalanceTransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CustomerBalanceTransaction": @@ -140,6 +145,7 @@ async def retrieve_async( self, customer: str, transaction: str, + /, params: Optional["CustomerBalanceTransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CustomerBalanceTransaction": @@ -164,6 +170,7 @@ def update( self, customer: str, transaction: str, + /, params: Optional["CustomerBalanceTransactionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CustomerBalanceTransaction": @@ -188,6 +195,7 @@ async def update_async( self, customer: str, transaction: str, + /, params: Optional["CustomerBalanceTransactionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CustomerBalanceTransaction": diff --git a/stripe/_customer_cash_balance_service.py b/stripe/_customer_cash_balance_service.py index 80ea75f17..05ac73314 100644 --- a/stripe/_customer_cash_balance_service.py +++ b/stripe/_customer_cash_balance_service.py @@ -20,6 +20,7 @@ class CustomerCashBalanceService(StripeService): def retrieve( self, customer: str, + /, params: Optional["CustomerCashBalanceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CashBalance": @@ -42,6 +43,7 @@ def retrieve( async def retrieve_async( self, customer: str, + /, params: Optional["CustomerCashBalanceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CashBalance": @@ -64,6 +66,7 @@ async def retrieve_async( def update( self, customer: str, + /, params: Optional["CustomerCashBalanceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CashBalance": @@ -86,6 +89,7 @@ def update( async def update_async( self, customer: str, + /, params: Optional["CustomerCashBalanceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CashBalance": diff --git a/stripe/_customer_cash_balance_transaction_service.py b/stripe/_customer_cash_balance_transaction_service.py index e9ceb3203..5e25ad234 100644 --- a/stripe/_customer_cash_balance_transaction_service.py +++ b/stripe/_customer_cash_balance_transaction_service.py @@ -23,6 +23,7 @@ class CustomerCashBalanceTransactionService(StripeService): def list( self, customer: str, + /, params: Optional["CustomerCashBalanceTransactionListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CustomerCashBalanceTransaction]": @@ -45,6 +46,7 @@ def list( async def list_async( self, customer: str, + /, params: Optional["CustomerCashBalanceTransactionListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CustomerCashBalanceTransaction]": @@ -68,6 +70,7 @@ def retrieve( self, customer: str, transaction: str, + /, params: Optional[ "CustomerCashBalanceTransactionRetrieveParams" ] = None, @@ -94,6 +97,7 @@ async def retrieve_async( self, customer: str, transaction: str, + /, params: Optional[ "CustomerCashBalanceTransactionRetrieveParams" ] = None, diff --git a/stripe/_customer_funding_instructions_service.py b/stripe/_customer_funding_instructions_service.py index 463434fe7..673c64ff1 100644 --- a/stripe/_customer_funding_instructions_service.py +++ b/stripe/_customer_funding_instructions_service.py @@ -17,6 +17,7 @@ class CustomerFundingInstructionsService(StripeService): def create( self, customer: str, + /, params: "CustomerFundingInstructionsCreateParams", options: Optional["RequestOptions"] = None, ) -> "FundingInstructions": @@ -41,6 +42,7 @@ def create( async def create_async( self, customer: str, + /, params: "CustomerFundingInstructionsCreateParams", options: Optional["RequestOptions"] = None, ) -> "FundingInstructions": diff --git a/stripe/_customer_payment_method_service.py b/stripe/_customer_payment_method_service.py index 05d0e9b6d..48eaa5fbb 100644 --- a/stripe/_customer_payment_method_service.py +++ b/stripe/_customer_payment_method_service.py @@ -21,6 +21,7 @@ class CustomerPaymentMethodService(StripeService): def list( self, customer: str, + /, params: Optional["CustomerPaymentMethodListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[PaymentMethod]": @@ -43,6 +44,7 @@ def list( async def list_async( self, customer: str, + /, params: Optional["CustomerPaymentMethodListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[PaymentMethod]": @@ -66,6 +68,7 @@ def retrieve( self, customer: str, payment_method: str, + /, params: Optional["CustomerPaymentMethodRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -90,6 +93,7 @@ async def retrieve_async( self, customer: str, payment_method: str, + /, params: Optional["CustomerPaymentMethodRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": diff --git a/stripe/_customer_payment_source_service.py b/stripe/_customer_payment_source_service.py index 589ccff6d..606eeac0a 100644 --- a/stripe/_customer_payment_source_service.py +++ b/stripe/_customer_payment_source_service.py @@ -37,6 +37,7 @@ class CustomerPaymentSourceService(StripeService): def list( self, customer: str, + /, params: Optional["CustomerPaymentSourceListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Union[Account, BankAccount, Card, Source]]": @@ -59,6 +60,7 @@ def list( async def list_async( self, customer: str, + /, params: Optional["CustomerPaymentSourceListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Union[Account, BankAccount, Card, Source]]": @@ -81,6 +83,7 @@ async def list_async( def create( self, customer: str, + /, params: "CustomerPaymentSourceCreateParams", options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -107,6 +110,7 @@ def create( async def create_async( self, customer: str, + /, params: "CustomerPaymentSourceCreateParams", options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -134,6 +138,7 @@ def retrieve( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -158,6 +163,7 @@ async def retrieve_async( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -182,6 +188,7 @@ def update( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -206,6 +213,7 @@ async def update_async( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -230,6 +238,7 @@ def delete( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -254,6 +263,7 @@ async def delete_async( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -278,6 +288,7 @@ def verify( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceVerifyParams"] = None, options: Optional["RequestOptions"] = None, ) -> "BankAccount": @@ -302,6 +313,7 @@ async def verify_async( self, customer: str, id: str, + /, params: Optional["CustomerPaymentSourceVerifyParams"] = None, options: Optional["RequestOptions"] = None, ) -> "BankAccount": diff --git a/stripe/_customer_service.py b/stripe/_customer_service.py index e7037cde1..277859998 100644 --- a/stripe/_customer_service.py +++ b/stripe/_customer_service.py @@ -101,6 +101,7 @@ def __getattr__(self, name): def delete( self, customer: str, + /, params: Optional["CustomerDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Customer": @@ -123,6 +124,7 @@ def delete( async def delete_async( self, customer: str, + /, params: Optional["CustomerDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Customer": @@ -145,6 +147,7 @@ async def delete_async( def retrieve( self, customer: str, + /, params: Optional["CustomerRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Customer": @@ -167,6 +170,7 @@ def retrieve( async def retrieve_async( self, customer: str, + /, params: Optional["CustomerRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Customer": @@ -189,6 +193,7 @@ async def retrieve_async( def update( self, customer: str, + /, params: Optional["CustomerUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Customer": @@ -213,6 +218,7 @@ def update( async def update_async( self, customer: str, + /, params: Optional["CustomerUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Customer": @@ -237,6 +243,7 @@ async def update_async( def delete_discount( self, customer: str, + /, params: Optional["CustomerDeleteDiscountParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Discount": @@ -259,6 +266,7 @@ def delete_discount( async def delete_discount_async( self, customer: str, + /, params: Optional["CustomerDeleteDiscountParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Discount": diff --git a/stripe/_customer_tax_id_service.py b/stripe/_customer_tax_id_service.py index 617c1f895..6b4a7bf1a 100644 --- a/stripe/_customer_tax_id_service.py +++ b/stripe/_customer_tax_id_service.py @@ -28,6 +28,7 @@ def delete( self, customer: str, id: str, + /, params: Optional["CustomerTaxIdDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -52,6 +53,7 @@ async def delete_async( self, customer: str, id: str, + /, params: Optional["CustomerTaxIdDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -76,6 +78,7 @@ def retrieve( self, customer: str, id: str, + /, params: Optional["CustomerTaxIdRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -100,6 +103,7 @@ async def retrieve_async( self, customer: str, id: str, + /, params: Optional["CustomerTaxIdRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -123,6 +127,7 @@ async def retrieve_async( def list( self, customer: str, + /, params: Optional["CustomerTaxIdListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[TaxId]": @@ -145,6 +150,7 @@ def list( async def list_async( self, customer: str, + /, params: Optional["CustomerTaxIdListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[TaxId]": @@ -167,6 +173,7 @@ async def list_async( def create( self, customer: str, + /, params: "CustomerTaxIdCreateParams", options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -189,6 +196,7 @@ def create( async def create_async( self, customer: str, + /, params: "CustomerTaxIdCreateParams", options: Optional["RequestOptions"] = None, ) -> "TaxId": diff --git a/stripe/_discount.py b/stripe/_discount.py index d62b10208..3f034e979 100644 --- a/stripe/_discount.py +++ b/stripe/_discount.py @@ -2,7 +2,7 @@ # File generated from our OpenAPI spec from stripe._expandable_field import ExpandableField from stripe._stripe_object import StripeObject -from typing import ClassVar, Optional +from typing import ClassVar, Optional, Union from typing_extensions import Literal, TYPE_CHECKING if TYPE_CHECKING: @@ -26,7 +26,7 @@ class Source(StripeObject): """ The coupon that was redeemed to create this discount. """ - type: Literal["coupon"] + type: Union[Literal["coupon"], str] """ The source type of the discount. """ diff --git a/stripe/_dispute.py b/stripe/_dispute.py index 75d8d9794..a6869930b 100644 --- a/stripe/_dispute.py +++ b/stripe/_dispute.py @@ -534,7 +534,7 @@ class Paypal(StripeObject): @classmethod def _cls_close( - cls, dispute: str, **params: Unpack["DisputeCloseParams"] + cls, dispute: str, /, **params: Unpack["DisputeCloseParams"] ) -> "Dispute": """ Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute (accepting it), acknowledging it as lost. @@ -555,7 +555,7 @@ def _cls_close( @overload @staticmethod def close( - dispute: str, **params: Unpack["DisputeCloseParams"] + dispute: str, /, **params: Unpack["DisputeCloseParams"] ) -> "Dispute": """ Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute (accepting it), acknowledging it as lost. @@ -595,7 +595,7 @@ def close( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_close_async( - cls, dispute: str, **params: Unpack["DisputeCloseParams"] + cls, dispute: str, /, **params: Unpack["DisputeCloseParams"] ) -> "Dispute": """ Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute (accepting it), acknowledging it as lost. @@ -616,7 +616,7 @@ async def _cls_close_async( @overload @staticmethod async def close_async( - dispute: str, **params: Unpack["DisputeCloseParams"] + dispute: str, /, **params: Unpack["DisputeCloseParams"] ) -> "Dispute": """ Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute (accepting it), acknowledging it as lost. diff --git a/stripe/_dispute_service.py b/stripe/_dispute_service.py index 0d4345fe4..ab89167af 100644 --- a/stripe/_dispute_service.py +++ b/stripe/_dispute_service.py @@ -57,6 +57,7 @@ async def list_async( def retrieve( self, dispute: str, + /, params: Optional["DisputeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -77,6 +78,7 @@ def retrieve( async def retrieve_async( self, dispute: str, + /, params: Optional["DisputeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -97,6 +99,7 @@ async def retrieve_async( def update( self, dispute: str, + /, params: Optional["DisputeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -119,6 +122,7 @@ def update( async def update_async( self, dispute: str, + /, params: Optional["DisputeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -141,6 +145,7 @@ async def update_async( def close( self, dispute: str, + /, params: Optional["DisputeCloseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -165,6 +170,7 @@ def close( async def close_async( self, dispute: str, + /, params: Optional["DisputeCloseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": diff --git a/stripe/_ephemeral_key_service.py b/stripe/_ephemeral_key_service.py index a8d45b08a..20cafc5a0 100644 --- a/stripe/_ephemeral_key_service.py +++ b/stripe/_ephemeral_key_service.py @@ -20,6 +20,7 @@ class EphemeralKeyService(StripeService): def delete( self, key: str, + /, params: Optional["EphemeralKeyDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EphemeralKey": @@ -40,6 +41,7 @@ def delete( async def delete_async( self, key: str, + /, params: Optional["EphemeralKeyDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EphemeralKey": diff --git a/stripe/_event_service.py b/stripe/_event_service.py index f11a9e1ee..2ea67cd99 100644 --- a/stripe/_event_service.py +++ b/stripe/_event_service.py @@ -55,6 +55,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["EventRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Event": @@ -75,6 +76,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["EventRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Event": diff --git a/stripe/_exchange_rate_service.py b/stripe/_exchange_rate_service.py index 16675be03..d39b18642 100644 --- a/stripe/_exchange_rate_service.py +++ b/stripe/_exchange_rate_service.py @@ -61,6 +61,7 @@ async def list_async( def retrieve( self, rate_id: str, + /, params: Optional["ExchangeRateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ExchangeRate": @@ -85,6 +86,7 @@ def retrieve( async def retrieve_async( self, rate_id: str, + /, params: Optional["ExchangeRateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ExchangeRate": diff --git a/stripe/_file_link_service.py b/stripe/_file_link_service.py index 8a9653803..c40e7fa67 100644 --- a/stripe/_file_link_service.py +++ b/stripe/_file_link_service.py @@ -95,6 +95,7 @@ async def create_async( def retrieve( self, link: str, + /, params: Optional["FileLinkRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FileLink": @@ -115,6 +116,7 @@ def retrieve( async def retrieve_async( self, link: str, + /, params: Optional["FileLinkRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FileLink": @@ -135,6 +137,7 @@ async def retrieve_async( def update( self, link: str, + /, params: Optional["FileLinkUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FileLink": @@ -155,6 +158,7 @@ def update( async def update_async( self, link: str, + /, params: Optional["FileLinkUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FileLink": diff --git a/stripe/_file_service.py b/stripe/_file_service.py index 7822f15e4..1f16e3e57 100644 --- a/stripe/_file_service.py +++ b/stripe/_file_service.py @@ -104,6 +104,7 @@ async def create_async( def retrieve( self, file: str, + /, params: Optional["FileRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "File": @@ -124,6 +125,7 @@ def retrieve( async def retrieve_async( self, file: str, + /, params: Optional["FileRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "File": diff --git a/stripe/_invoice.py b/stripe/_invoice.py index 113ef5f88..0edd9f7a7 100644 --- a/stripe/_invoice.py +++ b/stripe/_invoice.py @@ -1694,7 +1694,7 @@ class TaxRateDetails(StripeObject): @classmethod def _cls_add_lines( - cls, invoice: str, **params: Unpack["InvoiceAddLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceAddLinesParams"] ) -> "Invoice": """ Adds multiple line items to an invoice. This is only possible when an invoice is still a draft. @@ -1713,7 +1713,7 @@ def _cls_add_lines( @overload @staticmethod def add_lines( - invoice: str, **params: Unpack["InvoiceAddLinesParams"] + invoice: str, /, **params: Unpack["InvoiceAddLinesParams"] ) -> "Invoice": """ Adds multiple line items to an invoice. This is only possible when an invoice is still a draft. @@ -1749,7 +1749,7 @@ def add_lines( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_add_lines_async( - cls, invoice: str, **params: Unpack["InvoiceAddLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceAddLinesParams"] ) -> "Invoice": """ Adds multiple line items to an invoice. This is only possible when an invoice is still a draft. @@ -1768,7 +1768,7 @@ async def _cls_add_lines_async( @overload @staticmethod async def add_lines_async( - invoice: str, **params: Unpack["InvoiceAddLinesParams"] + invoice: str, /, **params: Unpack["InvoiceAddLinesParams"] ) -> "Invoice": """ Adds multiple line items to an invoice. This is only possible when an invoice is still a draft. @@ -1804,7 +1804,7 @@ async def add_lines_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_attach_payment( - cls, invoice: str, **params: Unpack["InvoiceAttachPaymentParams"] + cls, invoice: str, /, **params: Unpack["InvoiceAttachPaymentParams"] ) -> "Invoice": """ Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments. @@ -1832,7 +1832,7 @@ def _cls_attach_payment( @overload @staticmethod def attach_payment( - invoice: str, **params: Unpack["InvoiceAttachPaymentParams"] + invoice: str, /, **params: Unpack["InvoiceAttachPaymentParams"] ) -> "Invoice": """ Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments. @@ -1895,7 +1895,7 @@ def attach_payment( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_attach_payment_async( - cls, invoice: str, **params: Unpack["InvoiceAttachPaymentParams"] + cls, invoice: str, /, **params: Unpack["InvoiceAttachPaymentParams"] ) -> "Invoice": """ Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments. @@ -1923,7 +1923,7 @@ async def _cls_attach_payment_async( @overload @staticmethod async def attach_payment_async( - invoice: str, **params: Unpack["InvoiceAttachPaymentParams"] + invoice: str, /, **params: Unpack["InvoiceAttachPaymentParams"] ) -> "Invoice": """ Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments. @@ -2158,7 +2158,7 @@ async def delete_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_finalize_invoice( - cls, invoice: str, **params: Unpack["InvoiceFinalizeInvoiceParams"] + cls, invoice: str, /, **params: Unpack["InvoiceFinalizeInvoiceParams"] ) -> "Invoice": """ Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method. @@ -2177,7 +2177,7 @@ def _cls_finalize_invoice( @overload @staticmethod def finalize_invoice( - invoice: str, **params: Unpack["InvoiceFinalizeInvoiceParams"] + invoice: str, /, **params: Unpack["InvoiceFinalizeInvoiceParams"] ) -> "Invoice": """ Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method. @@ -2213,7 +2213,7 @@ def finalize_invoice( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_finalize_invoice_async( - cls, invoice: str, **params: Unpack["InvoiceFinalizeInvoiceParams"] + cls, invoice: str, /, **params: Unpack["InvoiceFinalizeInvoiceParams"] ) -> "Invoice": """ Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method. @@ -2232,7 +2232,7 @@ async def _cls_finalize_invoice_async( @overload @staticmethod async def finalize_invoice_async( - invoice: str, **params: Unpack["InvoiceFinalizeInvoiceParams"] + invoice: str, /, **params: Unpack["InvoiceFinalizeInvoiceParams"] ) -> "Invoice": """ Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method. @@ -2308,7 +2308,10 @@ async def list_async( @classmethod def _cls_mark_uncollectible( - cls, invoice: str, **params: Unpack["InvoiceMarkUncollectibleParams"] + cls, + invoice: str, + /, + **params: Unpack["InvoiceMarkUncollectibleParams"], ) -> "Invoice": """ Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes. @@ -2327,7 +2330,7 @@ def _cls_mark_uncollectible( @overload @staticmethod def mark_uncollectible( - invoice: str, **params: Unpack["InvoiceMarkUncollectibleParams"] + invoice: str, /, **params: Unpack["InvoiceMarkUncollectibleParams"] ) -> "Invoice": """ Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes. @@ -2363,7 +2366,10 @@ def mark_uncollectible( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_mark_uncollectible_async( - cls, invoice: str, **params: Unpack["InvoiceMarkUncollectibleParams"] + cls, + invoice: str, + /, + **params: Unpack["InvoiceMarkUncollectibleParams"], ) -> "Invoice": """ Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes. @@ -2382,7 +2388,7 @@ async def _cls_mark_uncollectible_async( @overload @staticmethod async def mark_uncollectible_async( - invoice: str, **params: Unpack["InvoiceMarkUncollectibleParams"] + invoice: str, /, **params: Unpack["InvoiceMarkUncollectibleParams"] ) -> "Invoice": """ Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes. @@ -2462,7 +2468,7 @@ async def modify_async( @classmethod def _cls_pay( - cls, invoice: str, **params: Unpack["InvoicePayParams"] + cls, invoice: str, /, **params: Unpack["InvoicePayParams"] ) -> "Invoice": """ Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. @@ -2480,7 +2486,9 @@ def _cls_pay( @overload @staticmethod - def pay(invoice: str, **params: Unpack["InvoicePayParams"]) -> "Invoice": + def pay( + invoice: str, /, **params: Unpack["InvoicePayParams"] + ) -> "Invoice": """ Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. """ @@ -2513,7 +2521,7 @@ def pay( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_pay_async( - cls, invoice: str, **params: Unpack["InvoicePayParams"] + cls, invoice: str, /, **params: Unpack["InvoicePayParams"] ) -> "Invoice": """ Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. @@ -2532,7 +2540,7 @@ async def _cls_pay_async( @overload @staticmethod async def pay_async( - invoice: str, **params: Unpack["InvoicePayParams"] + invoice: str, /, **params: Unpack["InvoicePayParams"] ) -> "Invoice": """ Stripe automatically creates and then attempts to collect payment on invoices for customers on subscriptions according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to attempt payment on an invoice out of the normal collection schedule or for some other reason, you can do so. @@ -2568,7 +2576,7 @@ async def pay_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_remove_lines( - cls, invoice: str, **params: Unpack["InvoiceRemoveLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceRemoveLinesParams"] ) -> "Invoice": """ Removes multiple line items from an invoice. This is only possible when an invoice is still a draft. @@ -2587,7 +2595,7 @@ def _cls_remove_lines( @overload @staticmethod def remove_lines( - invoice: str, **params: Unpack["InvoiceRemoveLinesParams"] + invoice: str, /, **params: Unpack["InvoiceRemoveLinesParams"] ) -> "Invoice": """ Removes multiple line items from an invoice. This is only possible when an invoice is still a draft. @@ -2623,7 +2631,7 @@ def remove_lines( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_remove_lines_async( - cls, invoice: str, **params: Unpack["InvoiceRemoveLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceRemoveLinesParams"] ) -> "Invoice": """ Removes multiple line items from an invoice. This is only possible when an invoice is still a draft. @@ -2642,7 +2650,7 @@ async def _cls_remove_lines_async( @overload @staticmethod async def remove_lines_async( - invoice: str, **params: Unpack["InvoiceRemoveLinesParams"] + invoice: str, /, **params: Unpack["InvoiceRemoveLinesParams"] ) -> "Invoice": """ Removes multiple line items from an invoice. This is only possible when an invoice is still a draft. @@ -2700,7 +2708,7 @@ async def retrieve_async( @classmethod def _cls_send_invoice( - cls, invoice: str, **params: Unpack["InvoiceSendInvoiceParams"] + cls, invoice: str, /, **params: Unpack["InvoiceSendInvoiceParams"] ) -> "Invoice": """ Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. @@ -2721,7 +2729,7 @@ def _cls_send_invoice( @overload @staticmethod def send_invoice( - invoice: str, **params: Unpack["InvoiceSendInvoiceParams"] + invoice: str, /, **params: Unpack["InvoiceSendInvoiceParams"] ) -> "Invoice": """ Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. @@ -2763,7 +2771,7 @@ def send_invoice( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_send_invoice_async( - cls, invoice: str, **params: Unpack["InvoiceSendInvoiceParams"] + cls, invoice: str, /, **params: Unpack["InvoiceSendInvoiceParams"] ) -> "Invoice": """ Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. @@ -2784,7 +2792,7 @@ async def _cls_send_invoice_async( @overload @staticmethod async def send_invoice_async( - invoice: str, **params: Unpack["InvoiceSendInvoiceParams"] + invoice: str, /, **params: Unpack["InvoiceSendInvoiceParams"] ) -> "Invoice": """ Stripe will automatically send invoices to customers according to your [subscriptions settings](https://dashboard.stripe.com/account/billing/automatic). However, if you'd like to manually send an invoice to your customer out of the normal schedule, you can do so. When sending invoices that have already been paid, there will be no reference to the payment in the email. @@ -2826,7 +2834,7 @@ async def send_invoice_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_update_lines( - cls, invoice: str, **params: Unpack["InvoiceUpdateLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceUpdateLinesParams"] ) -> "Invoice": """ Updates multiple line items on an invoice. This is only possible when an invoice is still a draft. @@ -2845,7 +2853,7 @@ def _cls_update_lines( @overload @staticmethod def update_lines( - invoice: str, **params: Unpack["InvoiceUpdateLinesParams"] + invoice: str, /, **params: Unpack["InvoiceUpdateLinesParams"] ) -> "Invoice": """ Updates multiple line items on an invoice. This is only possible when an invoice is still a draft. @@ -2881,7 +2889,7 @@ def update_lines( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_update_lines_async( - cls, invoice: str, **params: Unpack["InvoiceUpdateLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceUpdateLinesParams"] ) -> "Invoice": """ Updates multiple line items on an invoice. This is only possible when an invoice is still a draft. @@ -2900,7 +2908,7 @@ async def _cls_update_lines_async( @overload @staticmethod async def update_lines_async( - invoice: str, **params: Unpack["InvoiceUpdateLinesParams"] + invoice: str, /, **params: Unpack["InvoiceUpdateLinesParams"] ) -> "Invoice": """ Updates multiple line items on an invoice. This is only possible when an invoice is still a draft. @@ -2936,7 +2944,7 @@ async def update_lines_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_void_invoice( - cls, invoice: str, **params: Unpack["InvoiceVoidInvoiceParams"] + cls, invoice: str, /, **params: Unpack["InvoiceVoidInvoiceParams"] ) -> "Invoice": """ Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api/invoices/delete), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found. @@ -2957,7 +2965,7 @@ def _cls_void_invoice( @overload @staticmethod def void_invoice( - invoice: str, **params: Unpack["InvoiceVoidInvoiceParams"] + invoice: str, /, **params: Unpack["InvoiceVoidInvoiceParams"] ) -> "Invoice": """ Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api/invoices/delete), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found. @@ -2999,7 +3007,7 @@ def void_invoice( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_void_invoice_async( - cls, invoice: str, **params: Unpack["InvoiceVoidInvoiceParams"] + cls, invoice: str, /, **params: Unpack["InvoiceVoidInvoiceParams"] ) -> "Invoice": """ Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api/invoices/delete), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found. @@ -3020,7 +3028,7 @@ async def _cls_void_invoice_async( @overload @staticmethod async def void_invoice_async( - invoice: str, **params: Unpack["InvoiceVoidInvoiceParams"] + invoice: str, /, **params: Unpack["InvoiceVoidInvoiceParams"] ) -> "Invoice": """ Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api/invoices/delete), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found. @@ -3100,7 +3108,7 @@ async def search_auto_paging_iter_async( @classmethod def list_lines( - cls, invoice: str, **params: Unpack["InvoiceListLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceListLinesParams"] ) -> ListObject["InvoiceLineItem"]: """ When retrieving an invoice, you'll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -3118,7 +3126,7 @@ def list_lines( @classmethod async def list_lines_async( - cls, invoice: str, **params: Unpack["InvoiceListLinesParams"] + cls, invoice: str, /, **params: Unpack["InvoiceListLinesParams"] ) -> ListObject["InvoiceLineItem"]: """ When retrieving an invoice, you'll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. diff --git a/stripe/_invoice_item_service.py b/stripe/_invoice_item_service.py index 975b632c3..03f73b2ec 100644 --- a/stripe/_invoice_item_service.py +++ b/stripe/_invoice_item_service.py @@ -28,6 +28,7 @@ class InvoiceItemService(StripeService): def delete( self, invoiceitem: str, + /, params: Optional["InvoiceItemDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceItem": @@ -50,6 +51,7 @@ def delete( async def delete_async( self, invoiceitem: str, + /, params: Optional["InvoiceItemDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceItem": @@ -72,6 +74,7 @@ async def delete_async( def retrieve( self, invoiceitem: str, + /, params: Optional["InvoiceItemRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceItem": @@ -94,6 +97,7 @@ def retrieve( async def retrieve_async( self, invoiceitem: str, + /, params: Optional["InvoiceItemRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceItem": @@ -116,6 +120,7 @@ async def retrieve_async( def update( self, invoiceitem: str, + /, params: Optional["InvoiceItemUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceItem": @@ -138,6 +143,7 @@ def update( async def update_async( self, invoiceitem: str, + /, params: Optional["InvoiceItemUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceItem": diff --git a/stripe/_invoice_line_item_service.py b/stripe/_invoice_line_item_service.py index fde1d01de..cfddd8d61 100644 --- a/stripe/_invoice_line_item_service.py +++ b/stripe/_invoice_line_item_service.py @@ -21,6 +21,7 @@ class InvoiceLineItemService(StripeService): def list( self, invoice: str, + /, params: Optional["InvoiceLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[InvoiceLineItem]": @@ -43,6 +44,7 @@ def list( async def list_async( self, invoice: str, + /, params: Optional["InvoiceLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[InvoiceLineItem]": @@ -66,6 +68,7 @@ def update( self, invoice: str, line_item_id: str, + /, params: Optional["InvoiceLineItemUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceLineItem": @@ -93,6 +96,7 @@ async def update_async( self, invoice: str, line_item_id: str, + /, params: Optional["InvoiceLineItemUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceLineItem": diff --git a/stripe/_invoice_payment_service.py b/stripe/_invoice_payment_service.py index c7e998e3f..f5ed117c7 100644 --- a/stripe/_invoice_payment_service.py +++ b/stripe/_invoice_payment_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, invoice_payment: str, + /, params: Optional["InvoicePaymentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoicePayment": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, invoice_payment: str, + /, params: Optional["InvoicePaymentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoicePayment": diff --git a/stripe/_invoice_rendering_template.py b/stripe/_invoice_rendering_template.py index f70a67258..6486596eb 100644 --- a/stripe/_invoice_rendering_template.py +++ b/stripe/_invoice_rendering_template.py @@ -70,6 +70,7 @@ class InvoiceRenderingTemplate( def _cls_archive( cls, template: str, + /, **params: Unpack["InvoiceRenderingTemplateArchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -90,6 +91,7 @@ def _cls_archive( @staticmethod def archive( template: str, + /, **params: Unpack["InvoiceRenderingTemplateArchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -128,6 +130,7 @@ def archive( # pyright: ignore[reportGeneralTypeIssues] async def _cls_archive_async( cls, template: str, + /, **params: Unpack["InvoiceRenderingTemplateArchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -148,6 +151,7 @@ async def _cls_archive_async( @staticmethod async def archive_async( template: str, + /, **params: Unpack["InvoiceRenderingTemplateArchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -252,6 +256,7 @@ async def retrieve_async( def _cls_unarchive( cls, template: str, + /, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -272,6 +277,7 @@ def _cls_unarchive( @staticmethod def unarchive( template: str, + /, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -310,6 +316,7 @@ def unarchive( # pyright: ignore[reportGeneralTypeIssues] async def _cls_unarchive_async( cls, template: str, + /, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"], ) -> "InvoiceRenderingTemplate": """ @@ -330,6 +337,7 @@ async def _cls_unarchive_async( @staticmethod async def unarchive_async( template: str, + /, **params: Unpack["InvoiceRenderingTemplateUnarchiveParams"], ) -> "InvoiceRenderingTemplate": """ diff --git a/stripe/_invoice_rendering_template_service.py b/stripe/_invoice_rendering_template_service.py index 674bc2b55..919da6209 100644 --- a/stripe/_invoice_rendering_template_service.py +++ b/stripe/_invoice_rendering_template_service.py @@ -65,6 +65,7 @@ async def list_async( def retrieve( self, template: str, + /, params: Optional["InvoiceRenderingTemplateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceRenderingTemplate": @@ -87,6 +88,7 @@ def retrieve( async def retrieve_async( self, template: str, + /, params: Optional["InvoiceRenderingTemplateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceRenderingTemplate": @@ -109,6 +111,7 @@ async def retrieve_async( def archive( self, template: str, + /, params: Optional["InvoiceRenderingTemplateArchiveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceRenderingTemplate": @@ -131,6 +134,7 @@ def archive( async def archive_async( self, template: str, + /, params: Optional["InvoiceRenderingTemplateArchiveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceRenderingTemplate": @@ -153,6 +157,7 @@ async def archive_async( def unarchive( self, template: str, + /, params: Optional["InvoiceRenderingTemplateUnarchiveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceRenderingTemplate": @@ -175,6 +180,7 @@ def unarchive( async def unarchive_async( self, template: str, + /, params: Optional["InvoiceRenderingTemplateUnarchiveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InvoiceRenderingTemplate": diff --git a/stripe/_invoice_service.py b/stripe/_invoice_service.py index a201d0504..1e05f1e5b 100644 --- a/stripe/_invoice_service.py +++ b/stripe/_invoice_service.py @@ -78,6 +78,7 @@ def __getattr__(self, name): def delete( self, invoice: str, + /, params: Optional["InvoiceDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -98,6 +99,7 @@ def delete( async def delete_async( self, invoice: str, + /, params: Optional["InvoiceDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -118,6 +120,7 @@ async def delete_async( def retrieve( self, invoice: str, + /, params: Optional["InvoiceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -138,6 +141,7 @@ def retrieve( async def retrieve_async( self, invoice: str, + /, params: Optional["InvoiceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -158,6 +162,7 @@ async def retrieve_async( def update( self, invoice: str, + /, params: Optional["InvoiceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -183,6 +188,7 @@ def update( async def update_async( self, invoice: str, + /, params: Optional["InvoiceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -328,6 +334,7 @@ async def search_async( def add_lines( self, invoice: str, + /, params: "InvoiceAddLinesParams", options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -350,6 +357,7 @@ def add_lines( async def add_lines_async( self, invoice: str, + /, params: "InvoiceAddLinesParams", options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -372,6 +380,7 @@ async def add_lines_async( def attach_payment( self, invoice: str, + /, params: Optional["InvoiceAttachPaymentParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -403,6 +412,7 @@ def attach_payment( async def attach_payment_async( self, invoice: str, + /, params: Optional["InvoiceAttachPaymentParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -434,6 +444,7 @@ async def attach_payment_async( def finalize_invoice( self, invoice: str, + /, params: Optional["InvoiceFinalizeInvoiceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -456,6 +467,7 @@ def finalize_invoice( async def finalize_invoice_async( self, invoice: str, + /, params: Optional["InvoiceFinalizeInvoiceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -478,6 +490,7 @@ async def finalize_invoice_async( def mark_uncollectible( self, invoice: str, + /, params: Optional["InvoiceMarkUncollectibleParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -500,6 +513,7 @@ def mark_uncollectible( async def mark_uncollectible_async( self, invoice: str, + /, params: Optional["InvoiceMarkUncollectibleParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -522,6 +536,7 @@ async def mark_uncollectible_async( def pay( self, invoice: str, + /, params: Optional["InvoicePayParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -544,6 +559,7 @@ def pay( async def pay_async( self, invoice: str, + /, params: Optional["InvoicePayParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -566,6 +582,7 @@ async def pay_async( def remove_lines( self, invoice: str, + /, params: "InvoiceRemoveLinesParams", options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -588,6 +605,7 @@ def remove_lines( async def remove_lines_async( self, invoice: str, + /, params: "InvoiceRemoveLinesParams", options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -610,6 +628,7 @@ async def remove_lines_async( def send_invoice( self, invoice: str, + /, params: Optional["InvoiceSendInvoiceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -634,6 +653,7 @@ def send_invoice( async def send_invoice_async( self, invoice: str, + /, params: Optional["InvoiceSendInvoiceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -658,6 +678,7 @@ async def send_invoice_async( def update_lines( self, invoice: str, + /, params: "InvoiceUpdateLinesParams", options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -680,6 +701,7 @@ def update_lines( async def update_lines_async( self, invoice: str, + /, params: "InvoiceUpdateLinesParams", options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -702,6 +724,7 @@ async def update_lines_async( def void_invoice( self, invoice: str, + /, params: Optional["InvoiceVoidInvoiceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": @@ -726,6 +749,7 @@ def void_invoice( async def void_invoice_async( self, invoice: str, + /, params: Optional["InvoiceVoidInvoiceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Invoice": diff --git a/stripe/_mandate_service.py b/stripe/_mandate_service.py index 265674ba8..f4af45ab1 100644 --- a/stripe/_mandate_service.py +++ b/stripe/_mandate_service.py @@ -15,6 +15,7 @@ class MandateService(StripeService): def retrieve( self, mandate: str, + /, params: Optional["MandateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Mandate": @@ -35,6 +36,7 @@ def retrieve( async def retrieve_async( self, mandate: str, + /, params: Optional["MandateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Mandate": diff --git a/stripe/_payment_attempt_record.py b/stripe/_payment_attempt_record.py index 4b0aca536..1df8dcc20 100644 --- a/stripe/_payment_attempt_record.py +++ b/stripe/_payment_attempt_record.py @@ -276,7 +276,7 @@ class Card(StripeObject): """ card: Optional[Card] - type: Optional[Literal["card"]] + type: Optional[Union[Literal["card"], str]] """ funding type of the underlying payment method. """ @@ -1703,7 +1703,7 @@ class Card(StripeObject): """ card: Optional[Card] - type: Optional[Literal["card"]] + type: Optional[Union[Literal["card"], str]] """ Funding type of the underlying payment method. """ diff --git a/stripe/_payment_attempt_record_service.py b/stripe/_payment_attempt_record_service.py index 0ee17d353..62893b087 100644 --- a/stripe/_payment_attempt_record_service.py +++ b/stripe/_payment_attempt_record_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["PaymentAttemptRecordRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentAttemptRecord": @@ -79,6 +80,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["PaymentAttemptRecordRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentAttemptRecord": diff --git a/stripe/_payment_intent.py b/stripe/_payment_intent.py index dcaa81981..0e8bed4e8 100644 --- a/stripe/_payment_intent.py +++ b/stripe/_payment_intent.py @@ -2853,7 +2853,7 @@ class WechatPay(StripeObject): """ The client type that the end customer will pay from """ - setup_future_usage: Optional[Literal["none"]] + setup_future_usage: Optional[Union[Literal["none"], str]] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. @@ -3502,6 +3502,7 @@ class PaymentData(StripeObject): def _cls_apply_customer_balance( cls, intent: str, + /, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"], ) -> "PaymentIntent": """ @@ -3522,6 +3523,7 @@ def _cls_apply_customer_balance( @staticmethod def apply_customer_balance( intent: str, + /, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"], ) -> "PaymentIntent": """ @@ -3560,6 +3562,7 @@ def apply_customer_balance( # pyright: ignore[reportGeneralTypeIssues] async def _cls_apply_customer_balance_async( cls, intent: str, + /, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"], ) -> "PaymentIntent": """ @@ -3580,6 +3583,7 @@ async def _cls_apply_customer_balance_async( @staticmethod async def apply_customer_balance_async( intent: str, + /, **params: Unpack["PaymentIntentApplyCustomerBalanceParams"], ) -> "PaymentIntent": """ @@ -3616,7 +3620,7 @@ async def apply_customer_balance_async( # pyright: ignore[reportGeneralTypeIssu @classmethod def _cls_cancel( - cls, intent: str, **params: Unpack["PaymentIntentCancelParams"] + cls, intent: str, /, **params: Unpack["PaymentIntentCancelParams"] ) -> "PaymentIntent": """ You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing. @@ -3639,7 +3643,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - intent: str, **params: Unpack["PaymentIntentCancelParams"] + intent: str, /, **params: Unpack["PaymentIntentCancelParams"] ) -> "PaymentIntent": """ You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing. @@ -3687,7 +3691,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, intent: str, **params: Unpack["PaymentIntentCancelParams"] + cls, intent: str, /, **params: Unpack["PaymentIntentCancelParams"] ) -> "PaymentIntent": """ You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing. @@ -3710,7 +3714,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - intent: str, **params: Unpack["PaymentIntentCancelParams"] + intent: str, /, **params: Unpack["PaymentIntentCancelParams"] ) -> "PaymentIntent": """ You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing. @@ -3758,7 +3762,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_capture( - cls, intent: str, **params: Unpack["PaymentIntentCaptureParams"] + cls, intent: str, /, **params: Unpack["PaymentIntentCaptureParams"] ) -> "PaymentIntent": """ Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture. @@ -3781,7 +3785,7 @@ def _cls_capture( @overload @staticmethod def capture( - intent: str, **params: Unpack["PaymentIntentCaptureParams"] + intent: str, /, **params: Unpack["PaymentIntentCaptureParams"] ) -> "PaymentIntent": """ Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture. @@ -3829,7 +3833,7 @@ def capture( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_capture_async( - cls, intent: str, **params: Unpack["PaymentIntentCaptureParams"] + cls, intent: str, /, **params: Unpack["PaymentIntentCaptureParams"] ) -> "PaymentIntent": """ Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture. @@ -3852,7 +3856,7 @@ async def _cls_capture_async( @overload @staticmethod async def capture_async( - intent: str, **params: Unpack["PaymentIntentCaptureParams"] + intent: str, /, **params: Unpack["PaymentIntentCaptureParams"] ) -> "PaymentIntent": """ Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture. @@ -3900,7 +3904,7 @@ async def capture_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_confirm( - cls, intent: str, **params: Unpack["PaymentIntentConfirmParams"] + cls, intent: str, /, **params: Unpack["PaymentIntentConfirmParams"] ) -> "PaymentIntent": """ Confirm that your customer intends to pay with current or provided @@ -3948,7 +3952,7 @@ def _cls_confirm( @overload @staticmethod def confirm( - intent: str, **params: Unpack["PaymentIntentConfirmParams"] + intent: str, /, **params: Unpack["PaymentIntentConfirmParams"] ) -> "PaymentIntent": """ Confirm that your customer intends to pay with current or provided @@ -4071,7 +4075,7 @@ def confirm( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_confirm_async( - cls, intent: str, **params: Unpack["PaymentIntentConfirmParams"] + cls, intent: str, /, **params: Unpack["PaymentIntentConfirmParams"] ) -> "PaymentIntent": """ Confirm that your customer intends to pay with current or provided @@ -4119,7 +4123,7 @@ async def _cls_confirm_async( @overload @staticmethod async def confirm_async( - intent: str, **params: Unpack["PaymentIntentConfirmParams"] + intent: str, /, **params: Unpack["PaymentIntentConfirmParams"] ) -> "PaymentIntent": """ Confirm that your customer intends to pay with current or provided @@ -4294,6 +4298,7 @@ async def create_async( def _cls_increment_authorization( cls, intent: str, + /, **params: Unpack["PaymentIntentIncrementAuthorizationParams"], ) -> "PaymentIntent": """ @@ -4339,6 +4344,7 @@ def _cls_increment_authorization( @staticmethod def increment_authorization( intent: str, + /, **params: Unpack["PaymentIntentIncrementAuthorizationParams"], ) -> "PaymentIntent": """ @@ -4452,6 +4458,7 @@ def increment_authorization( # pyright: ignore[reportGeneralTypeIssues] async def _cls_increment_authorization_async( cls, intent: str, + /, **params: Unpack["PaymentIntentIncrementAuthorizationParams"], ) -> "PaymentIntent": """ @@ -4497,6 +4504,7 @@ async def _cls_increment_authorization_async( @staticmethod async def increment_authorization_async( intent: str, + /, **params: Unpack["PaymentIntentIncrementAuthorizationParams"], ) -> "PaymentIntent": """ @@ -4726,6 +4734,7 @@ async def retrieve_async( def _cls_verify_microdeposits( cls, intent: str, + /, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"], ) -> "PaymentIntent": """ @@ -4745,7 +4754,9 @@ def _cls_verify_microdeposits( @overload @staticmethod def verify_microdeposits( - intent: str, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"] + intent: str, + /, + **params: Unpack["PaymentIntentVerifyMicrodepositsParams"], ) -> "PaymentIntent": """ Verifies microdeposits on a PaymentIntent object. @@ -4783,6 +4794,7 @@ def verify_microdeposits( # pyright: ignore[reportGeneralTypeIssues] async def _cls_verify_microdeposits_async( cls, intent: str, + /, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"], ) -> "PaymentIntent": """ @@ -4802,7 +4814,9 @@ async def _cls_verify_microdeposits_async( @overload @staticmethod async def verify_microdeposits_async( - intent: str, **params: Unpack["PaymentIntentVerifyMicrodepositsParams"] + intent: str, + /, + **params: Unpack["PaymentIntentVerifyMicrodepositsParams"], ) -> "PaymentIntent": """ Verifies microdeposits on a PaymentIntent object. @@ -4880,6 +4894,7 @@ async def search_auto_paging_iter_async( def list_amount_details_line_items( cls, intent: str, + /, **params: Unpack["PaymentIntentListAmountDetailsLineItemsParams"], ) -> ListObject["PaymentIntentAmountDetailsLineItem"]: """ @@ -4900,6 +4915,7 @@ def list_amount_details_line_items( async def list_amount_details_line_items_async( cls, intent: str, + /, **params: Unpack["PaymentIntentListAmountDetailsLineItemsParams"], ) -> ListObject["PaymentIntentAmountDetailsLineItem"]: """ diff --git a/stripe/_payment_intent_amount_details_line_item_service.py b/stripe/_payment_intent_amount_details_line_item_service.py index a8ac4bc15..1cadd061e 100644 --- a/stripe/_payment_intent_amount_details_line_item_service.py +++ b/stripe/_payment_intent_amount_details_line_item_service.py @@ -20,6 +20,7 @@ class PaymentIntentAmountDetailsLineItemService(StripeService): def list( self, intent: str, + /, params: Optional[ "PaymentIntentAmountDetailsLineItemListParams" ] = None, @@ -44,6 +45,7 @@ def list( async def list_async( self, intent: str, + /, params: Optional[ "PaymentIntentAmountDetailsLineItemListParams" ] = None, diff --git a/stripe/_payment_intent_service.py b/stripe/_payment_intent_service.py index 694a3397c..2d17ac05b 100644 --- a/stripe/_payment_intent_service.py +++ b/stripe/_payment_intent_service.py @@ -175,6 +175,7 @@ async def create_async( def retrieve( self, intent: str, + /, params: Optional["PaymentIntentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -201,6 +202,7 @@ def retrieve( async def retrieve_async( self, intent: str, + /, params: Optional["PaymentIntentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -227,6 +229,7 @@ async def retrieve_async( def update( self, intent: str, + /, params: Optional["PaymentIntentUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -255,6 +258,7 @@ def update( async def update_async( self, intent: str, + /, params: Optional["PaymentIntentUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -327,6 +331,7 @@ async def search_async( def apply_customer_balance( self, intent: str, + /, params: Optional["PaymentIntentApplyCustomerBalanceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -349,6 +354,7 @@ def apply_customer_balance( async def apply_customer_balance_async( self, intent: str, + /, params: Optional["PaymentIntentApplyCustomerBalanceParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -371,6 +377,7 @@ async def apply_customer_balance_async( def cancel( self, intent: str, + /, params: Optional["PaymentIntentCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -397,6 +404,7 @@ def cancel( async def cancel_async( self, intent: str, + /, params: Optional["PaymentIntentCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -423,6 +431,7 @@ async def cancel_async( def capture( self, intent: str, + /, params: Optional["PaymentIntentCaptureParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -449,6 +458,7 @@ def capture( async def capture_async( self, intent: str, + /, params: Optional["PaymentIntentCaptureParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -475,6 +485,7 @@ async def capture_async( def confirm( self, intent: str, + /, params: Optional["PaymentIntentConfirmParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -526,6 +537,7 @@ def confirm( async def confirm_async( self, intent: str, + /, params: Optional["PaymentIntentConfirmParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -577,6 +589,7 @@ async def confirm_async( def increment_authorization( self, intent: str, + /, params: "PaymentIntentIncrementAuthorizationParams", options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -624,6 +637,7 @@ def increment_authorization( async def increment_authorization_async( self, intent: str, + /, params: "PaymentIntentIncrementAuthorizationParams", options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -671,6 +685,7 @@ async def increment_authorization_async( def verify_microdeposits( self, intent: str, + /, params: Optional["PaymentIntentVerifyMicrodepositsParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": @@ -693,6 +708,7 @@ def verify_microdeposits( async def verify_microdeposits_async( self, intent: str, + /, params: Optional["PaymentIntentVerifyMicrodepositsParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentIntent": diff --git a/stripe/_payment_link.py b/stripe/_payment_link.py index 4721e3f8d..dbfa6d386 100644 --- a/stripe/_payment_link.py +++ b/stripe/_payment_link.py @@ -1046,6 +1046,7 @@ async def list_async( def _cls_list_line_items( cls, payment_link: str, + /, **params: Unpack["PaymentLinkListLineItemsParams"], ) -> ListObject["LineItem"]: """ @@ -1065,7 +1066,9 @@ def _cls_list_line_items( @overload @staticmethod def list_line_items( - payment_link: str, **params: Unpack["PaymentLinkListLineItemsParams"] + payment_link: str, + /, + **params: Unpack["PaymentLinkListLineItemsParams"], ) -> ListObject["LineItem"]: """ When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -1103,6 +1106,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues] async def _cls_list_line_items_async( cls, payment_link: str, + /, **params: Unpack["PaymentLinkListLineItemsParams"], ) -> ListObject["LineItem"]: """ @@ -1122,7 +1126,9 @@ async def _cls_list_line_items_async( @overload @staticmethod async def list_line_items_async( - payment_link: str, **params: Unpack["PaymentLinkListLineItemsParams"] + payment_link: str, + /, + **params: Unpack["PaymentLinkListLineItemsParams"], ) -> ListObject["LineItem"]: """ When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. diff --git a/stripe/_payment_link_line_item_service.py b/stripe/_payment_link_line_item_service.py index d480f536c..43d6a43da 100644 --- a/stripe/_payment_link_line_item_service.py +++ b/stripe/_payment_link_line_item_service.py @@ -18,6 +18,7 @@ class PaymentLinkLineItemService(StripeService): def list( self, payment_link: str, + /, params: Optional["PaymentLinkLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, payment_link: str, + /, params: Optional["PaymentLinkLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": diff --git a/stripe/_payment_link_service.py b/stripe/_payment_link_service.py index 0fc673475..9536b8df4 100644 --- a/stripe/_payment_link_service.py +++ b/stripe/_payment_link_service.py @@ -133,6 +133,7 @@ async def create_async( def retrieve( self, payment_link: str, + /, params: Optional["PaymentLinkRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentLink": @@ -155,6 +156,7 @@ def retrieve( async def retrieve_async( self, payment_link: str, + /, params: Optional["PaymentLinkRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentLink": @@ -177,6 +179,7 @@ async def retrieve_async( def update( self, payment_link: str, + /, params: Optional["PaymentLinkUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentLink": @@ -199,6 +202,7 @@ def update( async def update_async( self, payment_link: str, + /, params: Optional["PaymentLinkUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentLink": diff --git a/stripe/_payment_method.py b/stripe/_payment_method.py index 16bb9cb5f..b85f20483 100644 --- a/stripe/_payment_method.py +++ b/stripe/_payment_method.py @@ -1654,7 +1654,10 @@ class Zip(StripeObject): @classmethod def _cls_attach( - cls, payment_method: str, **params: Unpack["PaymentMethodAttachParams"] + cls, + payment_method: str, + /, + **params: Unpack["PaymentMethodAttachParams"], ) -> "PaymentMethod": """ Attaches a PaymentMethod object to a Customer. @@ -1685,7 +1688,7 @@ def _cls_attach( @overload @staticmethod def attach( - payment_method: str, **params: Unpack["PaymentMethodAttachParams"] + payment_method: str, /, **params: Unpack["PaymentMethodAttachParams"] ) -> "PaymentMethod": """ Attaches a PaymentMethod object to a Customer. @@ -1757,7 +1760,10 @@ def attach( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_attach_async( - cls, payment_method: str, **params: Unpack["PaymentMethodAttachParams"] + cls, + payment_method: str, + /, + **params: Unpack["PaymentMethodAttachParams"], ) -> "PaymentMethod": """ Attaches a PaymentMethod object to a Customer. @@ -1788,7 +1794,7 @@ async def _cls_attach_async( @overload @staticmethod async def attach_async( - payment_method: str, **params: Unpack["PaymentMethodAttachParams"] + payment_method: str, /, **params: Unpack["PaymentMethodAttachParams"] ) -> "PaymentMethod": """ Attaches a PaymentMethod object to a Customer. @@ -1896,7 +1902,10 @@ async def create_async( @classmethod def _cls_detach( - cls, payment_method: str, **params: Unpack["PaymentMethodDetachParams"] + cls, + payment_method: str, + /, + **params: Unpack["PaymentMethodDetachParams"], ) -> "PaymentMethod": """ Detaches a PaymentMethod object from a Customer. Detachment is permanent and irreversible — once detached, a PaymentMethod can no longer be used for payments or re-attached to a Customer. @@ -1915,7 +1924,7 @@ def _cls_detach( @overload @staticmethod def detach( - payment_method: str, **params: Unpack["PaymentMethodDetachParams"] + payment_method: str, /, **params: Unpack["PaymentMethodDetachParams"] ) -> "PaymentMethod": """ Detaches a PaymentMethod object from a Customer. Detachment is permanent and irreversible — once detached, a PaymentMethod can no longer be used for payments or re-attached to a Customer. @@ -1951,7 +1960,10 @@ def detach( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_detach_async( - cls, payment_method: str, **params: Unpack["PaymentMethodDetachParams"] + cls, + payment_method: str, + /, + **params: Unpack["PaymentMethodDetachParams"], ) -> "PaymentMethod": """ Detaches a PaymentMethod object from a Customer. Detachment is permanent and irreversible — once detached, a PaymentMethod can no longer be used for payments or re-attached to a Customer. @@ -1970,7 +1982,7 @@ async def _cls_detach_async( @overload @staticmethod async def detach_async( - payment_method: str, **params: Unpack["PaymentMethodDetachParams"] + payment_method: str, /, **params: Unpack["PaymentMethodDetachParams"] ) -> "PaymentMethod": """ Detaches a PaymentMethod object from a Customer. Detachment is permanent and irreversible — once detached, a PaymentMethod can no longer be used for payments or re-attached to a Customer. diff --git a/stripe/_payment_method_configuration_service.py b/stripe/_payment_method_configuration_service.py index e8421f119..8a637b2cb 100644 --- a/stripe/_payment_method_configuration_service.py +++ b/stripe/_payment_method_configuration_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, configuration: str, + /, params: Optional["PaymentMethodConfigurationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodConfiguration": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, configuration: str, + /, params: Optional["PaymentMethodConfigurationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodConfiguration": @@ -147,6 +149,7 @@ async def retrieve_async( def update( self, configuration: str, + /, params: Optional["PaymentMethodConfigurationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodConfiguration": @@ -169,6 +172,7 @@ def update( async def update_async( self, configuration: str, + /, params: Optional["PaymentMethodConfigurationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodConfiguration": diff --git a/stripe/_payment_method_domain.py b/stripe/_payment_method_domain.py index 31d7467bd..d60833b78 100644 --- a/stripe/_payment_method_domain.py +++ b/stripe/_payment_method_domain.py @@ -326,6 +326,7 @@ async def retrieve_async( def _cls_validate( cls, payment_method_domain: str, + /, **params: Unpack["PaymentMethodDomainValidateParams"], ) -> "PaymentMethodDomain": """ @@ -351,6 +352,7 @@ def _cls_validate( @staticmethod def validate( payment_method_domain: str, + /, **params: Unpack["PaymentMethodDomainValidateParams"], ) -> "PaymentMethodDomain": """ @@ -404,6 +406,7 @@ def validate( # pyright: ignore[reportGeneralTypeIssues] async def _cls_validate_async( cls, payment_method_domain: str, + /, **params: Unpack["PaymentMethodDomainValidateParams"], ) -> "PaymentMethodDomain": """ @@ -429,6 +432,7 @@ async def _cls_validate_async( @staticmethod async def validate_async( payment_method_domain: str, + /, **params: Unpack["PaymentMethodDomainValidateParams"], ) -> "PaymentMethodDomain": """ diff --git a/stripe/_payment_method_domain_service.py b/stripe/_payment_method_domain_service.py index 122bb45a3..f508640e4 100644 --- a/stripe/_payment_method_domain_service.py +++ b/stripe/_payment_method_domain_service.py @@ -106,6 +106,7 @@ async def create_async( def retrieve( self, payment_method_domain: str, + /, params: Optional["PaymentMethodDomainRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodDomain": @@ -128,6 +129,7 @@ def retrieve( async def retrieve_async( self, payment_method_domain: str, + /, params: Optional["PaymentMethodDomainRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodDomain": @@ -150,6 +152,7 @@ async def retrieve_async( def update( self, payment_method_domain: str, + /, params: Optional["PaymentMethodDomainUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodDomain": @@ -172,6 +175,7 @@ def update( async def update_async( self, payment_method_domain: str, + /, params: Optional["PaymentMethodDomainUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodDomain": @@ -194,6 +198,7 @@ async def update_async( def validate( self, payment_method_domain: str, + /, params: Optional["PaymentMethodDomainValidateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodDomain": @@ -221,6 +226,7 @@ def validate( async def validate_async( self, payment_method_domain: str, + /, params: Optional["PaymentMethodDomainValidateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethodDomain": diff --git a/stripe/_payment_method_service.py b/stripe/_payment_method_service.py index 5df68e252..6018521a1 100644 --- a/stripe/_payment_method_service.py +++ b/stripe/_payment_method_service.py @@ -113,6 +113,7 @@ async def create_async( def retrieve( self, payment_method: str, + /, params: Optional["PaymentMethodRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -135,6 +136,7 @@ def retrieve( async def retrieve_async( self, payment_method: str, + /, params: Optional["PaymentMethodRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -157,6 +159,7 @@ async def retrieve_async( def update( self, payment_method: str, + /, params: Optional["PaymentMethodUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -179,6 +182,7 @@ def update( async def update_async( self, payment_method: str, + /, params: Optional["PaymentMethodUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -201,6 +205,7 @@ async def update_async( def attach( self, payment_method: str, + /, params: Optional["PaymentMethodAttachParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -235,6 +240,7 @@ def attach( async def attach_async( self, payment_method: str, + /, params: Optional["PaymentMethodAttachParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -269,6 +275,7 @@ async def attach_async( def detach( self, payment_method: str, + /, params: Optional["PaymentMethodDetachParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": @@ -291,6 +298,7 @@ def detach( async def detach_async( self, payment_method: str, + /, params: Optional["PaymentMethodDetachParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentMethod": diff --git a/stripe/_payment_record.py b/stripe/_payment_record.py index 3a226e282..fec2a8694 100644 --- a/stripe/_payment_record.py +++ b/stripe/_payment_record.py @@ -296,7 +296,7 @@ class Card(StripeObject): """ card: Optional[Card] - type: Optional[Literal["card"]] + type: Optional[Union[Literal["card"], str]] """ funding type of the underlying payment method. """ @@ -1723,7 +1723,7 @@ class Card(StripeObject): """ card: Optional[Card] - type: Optional[Literal["card"]] + type: Optional[Union[Literal["card"], str]] """ Funding type of the underlying payment method. """ @@ -2318,6 +2318,7 @@ async def report_payment_async( def _cls_report_payment_attempt( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptParams"], ) -> "PaymentRecord": """ @@ -2338,7 +2339,7 @@ def _cls_report_payment_attempt( @overload @staticmethod def report_payment_attempt( - id: str, **params: Unpack["PaymentRecordReportPaymentAttemptParams"] + id: str, /, **params: Unpack["PaymentRecordReportPaymentAttemptParams"] ) -> "PaymentRecord": """ Report a new payment attempt on the specified Payment Record. A new payment @@ -2379,6 +2380,7 @@ def report_payment_attempt( # pyright: ignore[reportGeneralTypeIssues] async def _cls_report_payment_attempt_async( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptParams"], ) -> "PaymentRecord": """ @@ -2399,7 +2401,7 @@ async def _cls_report_payment_attempt_async( @overload @staticmethod async def report_payment_attempt_async( - id: str, **params: Unpack["PaymentRecordReportPaymentAttemptParams"] + id: str, /, **params: Unpack["PaymentRecordReportPaymentAttemptParams"] ) -> "PaymentRecord": """ Report a new payment attempt on the specified Payment Record. A new payment @@ -2440,6 +2442,7 @@ async def report_payment_attempt_async( # pyright: ignore[reportGeneralTypeIssu def _cls_report_payment_attempt_canceled( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptCanceledParams"], ) -> "PaymentRecord": """ @@ -2461,6 +2464,7 @@ def _cls_report_payment_attempt_canceled( @staticmethod def report_payment_attempt_canceled( id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptCanceledParams"], ) -> "PaymentRecord": """ @@ -2504,6 +2508,7 @@ def report_payment_attempt_canceled( # pyright: ignore[reportGeneralTypeIssues] async def _cls_report_payment_attempt_canceled_async( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptCanceledParams"], ) -> "PaymentRecord": """ @@ -2525,6 +2530,7 @@ async def _cls_report_payment_attempt_canceled_async( @staticmethod async def report_payment_attempt_canceled_async( id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptCanceledParams"], ) -> "PaymentRecord": """ @@ -2568,6 +2574,7 @@ async def report_payment_attempt_canceled_async( # pyright: ignore[reportGenera def _cls_report_payment_attempt_failed( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptFailedParams"], ) -> "PaymentRecord": """ @@ -2589,6 +2596,7 @@ def _cls_report_payment_attempt_failed( @staticmethod def report_payment_attempt_failed( id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptFailedParams"], ) -> "PaymentRecord": """ @@ -2630,6 +2638,7 @@ def report_payment_attempt_failed( # pyright: ignore[reportGeneralTypeIssues] async def _cls_report_payment_attempt_failed_async( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptFailedParams"], ) -> "PaymentRecord": """ @@ -2651,6 +2660,7 @@ async def _cls_report_payment_attempt_failed_async( @staticmethod async def report_payment_attempt_failed_async( id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptFailedParams"], ) -> "PaymentRecord": """ @@ -2692,6 +2702,7 @@ async def report_payment_attempt_failed_async( # pyright: ignore[reportGeneralT def _cls_report_payment_attempt_guaranteed( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptGuaranteedParams"], ) -> "PaymentRecord": """ @@ -2713,6 +2724,7 @@ def _cls_report_payment_attempt_guaranteed( @staticmethod def report_payment_attempt_guaranteed( id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptGuaranteedParams"], ) -> "PaymentRecord": """ @@ -2756,6 +2768,7 @@ def report_payment_attempt_guaranteed( # pyright: ignore[reportGeneralTypeIssue async def _cls_report_payment_attempt_guaranteed_async( cls, id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptGuaranteedParams"], ) -> "PaymentRecord": """ @@ -2777,6 +2790,7 @@ async def _cls_report_payment_attempt_guaranteed_async( @staticmethod async def report_payment_attempt_guaranteed_async( id: str, + /, **params: Unpack["PaymentRecordReportPaymentAttemptGuaranteedParams"], ) -> "PaymentRecord": """ @@ -2820,6 +2834,7 @@ async def report_payment_attempt_guaranteed_async( # pyright: ignore[reportGene def _cls_report_payment_attempt_informational( cls, id: str, + /, **params: Unpack[ "PaymentRecordReportPaymentAttemptInformationalParams" ], @@ -2842,6 +2857,7 @@ def _cls_report_payment_attempt_informational( @staticmethod def report_payment_attempt_informational( id: str, + /, **params: Unpack[ "PaymentRecordReportPaymentAttemptInformationalParams" ], @@ -2888,6 +2904,7 @@ def report_payment_attempt_informational( # pyright: ignore[reportGeneralTypeIs async def _cls_report_payment_attempt_informational_async( cls, id: str, + /, **params: Unpack[ "PaymentRecordReportPaymentAttemptInformationalParams" ], @@ -2910,6 +2927,7 @@ async def _cls_report_payment_attempt_informational_async( @staticmethod async def report_payment_attempt_informational_async( id: str, + /, **params: Unpack[ "PaymentRecordReportPaymentAttemptInformationalParams" ], @@ -2954,7 +2972,7 @@ async def report_payment_attempt_informational_async( # pyright: ignore[reportG @classmethod def _cls_report_refund( - cls, id: str, **params: Unpack["PaymentRecordReportRefundParams"] + cls, id: str, /, **params: Unpack["PaymentRecordReportRefundParams"] ) -> "PaymentRecord": """ Report that the most recent payment attempt on the specified Payment Record @@ -2974,7 +2992,7 @@ def _cls_report_refund( @overload @staticmethod def report_refund( - id: str, **params: Unpack["PaymentRecordReportRefundParams"] + id: str, /, **params: Unpack["PaymentRecordReportRefundParams"] ) -> "PaymentRecord": """ Report that the most recent payment attempt on the specified Payment Record @@ -3013,7 +3031,7 @@ def report_refund( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_report_refund_async( - cls, id: str, **params: Unpack["PaymentRecordReportRefundParams"] + cls, id: str, /, **params: Unpack["PaymentRecordReportRefundParams"] ) -> "PaymentRecord": """ Report that the most recent payment attempt on the specified Payment Record @@ -3033,7 +3051,7 @@ async def _cls_report_refund_async( @overload @staticmethod async def report_refund_async( - id: str, **params: Unpack["PaymentRecordReportRefundParams"] + id: str, /, **params: Unpack["PaymentRecordReportRefundParams"] ) -> "PaymentRecord": """ Report that the most recent payment attempt on the specified Payment Record diff --git a/stripe/_payment_record_service.py b/stripe/_payment_record_service.py index 1601d6973..b10a83482 100644 --- a/stripe/_payment_record_service.py +++ b/stripe/_payment_record_service.py @@ -80,6 +80,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["PaymentRecordRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -100,6 +101,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["PaymentRecordRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -120,6 +122,7 @@ async def retrieve_async( def report_payment_attempt( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -143,6 +146,7 @@ def report_payment_attempt( async def report_payment_attempt_async( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -166,6 +170,7 @@ async def report_payment_attempt_async( def report_payment_attempt_canceled( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptCanceledParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -189,6 +194,7 @@ def report_payment_attempt_canceled( async def report_payment_attempt_canceled_async( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptCanceledParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -212,6 +218,7 @@ async def report_payment_attempt_canceled_async( def report_payment_attempt_failed( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptFailedParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -235,6 +242,7 @@ def report_payment_attempt_failed( async def report_payment_attempt_failed_async( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptFailedParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -258,6 +266,7 @@ async def report_payment_attempt_failed_async( def report_payment_attempt_guaranteed( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptGuaranteedParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -281,6 +290,7 @@ def report_payment_attempt_guaranteed( async def report_payment_attempt_guaranteed_async( self, id: str, + /, params: "PaymentRecordReportPaymentAttemptGuaranteedParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -304,6 +314,7 @@ async def report_payment_attempt_guaranteed_async( def report_payment_attempt_informational( self, id: str, + /, params: Optional[ "PaymentRecordReportPaymentAttemptInformationalParams" ] = None, @@ -328,6 +339,7 @@ def report_payment_attempt_informational( async def report_payment_attempt_informational_async( self, id: str, + /, params: Optional[ "PaymentRecordReportPaymentAttemptInformationalParams" ] = None, @@ -352,6 +364,7 @@ async def report_payment_attempt_informational_async( def report_refund( self, id: str, + /, params: "PaymentRecordReportRefundParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": @@ -375,6 +388,7 @@ def report_refund( async def report_refund_async( self, id: str, + /, params: "PaymentRecordReportRefundParams", options: Optional["RequestOptions"] = None, ) -> "PaymentRecord": diff --git a/stripe/_payout.py b/stripe/_payout.py index 1d40fbb53..81f269c27 100644 --- a/stripe/_payout.py +++ b/stripe/_payout.py @@ -166,7 +166,7 @@ class TraceId(StripeObject): @classmethod def _cls_cancel( - cls, payout: str, **params: Unpack["PayoutCancelParams"] + cls, payout: str, /, **params: Unpack["PayoutCancelParams"] ) -> "Payout": """ You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts. @@ -185,7 +185,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - payout: str, **params: Unpack["PayoutCancelParams"] + payout: str, /, **params: Unpack["PayoutCancelParams"] ) -> "Payout": """ You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts. @@ -219,7 +219,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, payout: str, **params: Unpack["PayoutCancelParams"] + cls, payout: str, /, **params: Unpack["PayoutCancelParams"] ) -> "Payout": """ You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts. @@ -238,7 +238,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - payout: str, **params: Unpack["PayoutCancelParams"] + payout: str, /, **params: Unpack["PayoutCancelParams"] ) -> "Payout": """ You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts. @@ -408,7 +408,7 @@ async def retrieve_async( @classmethod def _cls_reverse( - cls, payout: str, **params: Unpack["PayoutReverseParams"] + cls, payout: str, /, **params: Unpack["PayoutReverseParams"] ) -> "Payout": """ Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US and Canadian bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead. @@ -429,7 +429,7 @@ def _cls_reverse( @overload @staticmethod def reverse( - payout: str, **params: Unpack["PayoutReverseParams"] + payout: str, /, **params: Unpack["PayoutReverseParams"] ) -> "Payout": """ Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US and Canadian bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead. @@ -469,7 +469,7 @@ def reverse( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_reverse_async( - cls, payout: str, **params: Unpack["PayoutReverseParams"] + cls, payout: str, /, **params: Unpack["PayoutReverseParams"] ) -> "Payout": """ Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US and Canadian bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead. @@ -490,7 +490,7 @@ async def _cls_reverse_async( @overload @staticmethod async def reverse_async( - payout: str, **params: Unpack["PayoutReverseParams"] + payout: str, /, **params: Unpack["PayoutReverseParams"] ) -> "Payout": """ Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US and Canadian bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead. diff --git a/stripe/_payout_service.py b/stripe/_payout_service.py index 14920cc3a..b19b07983 100644 --- a/stripe/_payout_service.py +++ b/stripe/_payout_service.py @@ -105,6 +105,7 @@ async def create_async( def retrieve( self, payout: str, + /, params: Optional["PayoutRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, payout: str, + /, params: Optional["PayoutRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -145,6 +147,7 @@ async def retrieve_async( def update( self, payout: str, + /, params: Optional["PayoutUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -165,6 +168,7 @@ def update( async def update_async( self, payout: str, + /, params: Optional["PayoutUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -185,6 +189,7 @@ async def update_async( def cancel( self, payout: str, + /, params: Optional["PayoutCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -207,6 +212,7 @@ def cancel( async def cancel_async( self, payout: str, + /, params: Optional["PayoutCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -229,6 +235,7 @@ async def cancel_async( def reverse( self, payout: str, + /, params: Optional["PayoutReverseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": @@ -253,6 +260,7 @@ def reverse( async def reverse_async( self, payout: str, + /, params: Optional["PayoutReverseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Payout": diff --git a/stripe/_plan_service.py b/stripe/_plan_service.py index 8bbdf7304..b2bcd53a8 100644 --- a/stripe/_plan_service.py +++ b/stripe/_plan_service.py @@ -20,6 +20,7 @@ class PlanService(StripeService): def delete( self, plan: str, + /, params: Optional["PlanDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Plan": @@ -40,6 +41,7 @@ def delete( async def delete_async( self, plan: str, + /, params: Optional["PlanDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Plan": @@ -60,6 +62,7 @@ async def delete_async( def retrieve( self, plan: str, + /, params: Optional["PlanRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Plan": @@ -80,6 +83,7 @@ def retrieve( async def retrieve_async( self, plan: str, + /, params: Optional["PlanRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Plan": @@ -100,6 +104,7 @@ async def retrieve_async( def update( self, plan: str, + /, params: Optional["PlanUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Plan": @@ -120,6 +125,7 @@ def update( async def update_async( self, plan: str, + /, params: Optional["PlanUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Plan": diff --git a/stripe/_price_service.py b/stripe/_price_service.py index 5207dda39..1360c49d6 100644 --- a/stripe/_price_service.py +++ b/stripe/_price_service.py @@ -97,6 +97,7 @@ async def create_async( def retrieve( self, price: str, + /, params: Optional["PriceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Price": @@ -117,6 +118,7 @@ def retrieve( async def retrieve_async( self, price: str, + /, params: Optional["PriceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Price": @@ -137,6 +139,7 @@ async def retrieve_async( def update( self, price: str, + /, params: Optional["PriceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Price": @@ -157,6 +160,7 @@ def update( async def update_async( self, price: str, + /, params: Optional["PriceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Price": diff --git a/stripe/_product.py b/stripe/_product.py index e63587b5b..f48e62eff 100644 --- a/stripe/_product.py +++ b/stripe/_product.py @@ -436,6 +436,7 @@ def delete_feature( cls, product: str, id: str, + /, **params: Unpack["ProductDeleteFeatureParams"], ) -> "ProductFeature": """ @@ -457,6 +458,7 @@ async def delete_feature_async( cls, product: str, id: str, + /, **params: Unpack["ProductDeleteFeatureParams"], ) -> "ProductFeature": """ @@ -478,6 +480,7 @@ def retrieve_feature( cls, product: str, id: str, + /, **params: Unpack["ProductRetrieveFeatureParams"], ) -> "ProductFeature": """ @@ -499,6 +502,7 @@ async def retrieve_feature_async( cls, product: str, id: str, + /, **params: Unpack["ProductRetrieveFeatureParams"], ) -> "ProductFeature": """ @@ -517,7 +521,7 @@ async def retrieve_feature_async( @classmethod def list_features( - cls, product: str, **params: Unpack["ProductListFeaturesParams"] + cls, product: str, /, **params: Unpack["ProductListFeaturesParams"] ) -> ListObject["ProductFeature"]: """ Retrieve a list of features for a product @@ -535,7 +539,7 @@ def list_features( @classmethod async def list_features_async( - cls, product: str, **params: Unpack["ProductListFeaturesParams"] + cls, product: str, /, **params: Unpack["ProductListFeaturesParams"] ) -> ListObject["ProductFeature"]: """ Retrieve a list of features for a product @@ -553,7 +557,7 @@ async def list_features_async( @classmethod def create_feature( - cls, product: str, **params: Unpack["ProductCreateFeatureParams"] + cls, product: str, /, **params: Unpack["ProductCreateFeatureParams"] ) -> "ProductFeature": """ Creates a product_feature, which represents a feature attachment to a product @@ -571,7 +575,7 @@ def create_feature( @classmethod async def create_feature_async( - cls, product: str, **params: Unpack["ProductCreateFeatureParams"] + cls, product: str, /, **params: Unpack["ProductCreateFeatureParams"] ) -> "ProductFeature": """ Creates a product_feature, which represents a feature attachment to a product diff --git a/stripe/_product_feature_service.py b/stripe/_product_feature_service.py index 3eeba56fe..b53c375ec 100644 --- a/stripe/_product_feature_service.py +++ b/stripe/_product_feature_service.py @@ -28,6 +28,7 @@ def delete( self, product: str, id: str, + /, params: Optional["ProductFeatureDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ProductFeature": @@ -52,6 +53,7 @@ async def delete_async( self, product: str, id: str, + /, params: Optional["ProductFeatureDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ProductFeature": @@ -76,6 +78,7 @@ def retrieve( self, product: str, id: str, + /, params: Optional["ProductFeatureRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ProductFeature": @@ -100,6 +103,7 @@ async def retrieve_async( self, product: str, id: str, + /, params: Optional["ProductFeatureRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ProductFeature": @@ -123,6 +127,7 @@ async def retrieve_async( def list( self, product: str, + /, params: Optional["ProductFeatureListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[ProductFeature]": @@ -145,6 +150,7 @@ def list( async def list_async( self, product: str, + /, params: Optional["ProductFeatureListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[ProductFeature]": @@ -167,6 +173,7 @@ async def list_async( def create( self, product: str, + /, params: "ProductFeatureCreateParams", options: Optional["RequestOptions"] = None, ) -> "ProductFeature": @@ -189,6 +196,7 @@ def create( async def create_async( self, product: str, + /, params: "ProductFeatureCreateParams", options: Optional["RequestOptions"] = None, ) -> "ProductFeature": diff --git a/stripe/_product_service.py b/stripe/_product_service.py index c5eebca34..d042c2209 100644 --- a/stripe/_product_service.py +++ b/stripe/_product_service.py @@ -49,6 +49,7 @@ def __getattr__(self, name): def delete( self, id: str, + /, params: Optional["ProductDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": @@ -69,6 +70,7 @@ def delete( async def delete_async( self, id: str, + /, params: Optional["ProductDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": @@ -89,6 +91,7 @@ async def delete_async( def retrieve( self, id: str, + /, params: Optional["ProductRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": @@ -109,6 +112,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["ProductRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": @@ -129,6 +133,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["ProductUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": @@ -149,6 +154,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["ProductUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": diff --git a/stripe/_promotion_code_service.py b/stripe/_promotion_code_service.py index b8aaa4450..e33fd9801 100644 --- a/stripe/_promotion_code_service.py +++ b/stripe/_promotion_code_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, promotion_code: str, + /, params: Optional["PromotionCodeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PromotionCode": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, promotion_code: str, + /, params: Optional["PromotionCodeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PromotionCode": @@ -147,6 +149,7 @@ async def retrieve_async( def update( self, promotion_code: str, + /, params: Optional["PromotionCodeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PromotionCode": @@ -169,6 +172,7 @@ def update( async def update_async( self, promotion_code: str, + /, params: Optional["PromotionCodeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PromotionCode": diff --git a/stripe/_quote.py b/stripe/_quote.py index 2e334843e..5ea0d31a2 100644 --- a/stripe/_quote.py +++ b/stripe/_quote.py @@ -619,7 +619,7 @@ class TransferData(StripeObject): @classmethod def _cls_accept( - cls, quote: str, **params: Unpack["QuoteAcceptParams"] + cls, quote: str, /, **params: Unpack["QuoteAcceptParams"] ) -> "Quote": """ Accepts the specified quote. @@ -635,7 +635,9 @@ def _cls_accept( @overload @staticmethod - def accept(quote: str, **params: Unpack["QuoteAcceptParams"]) -> "Quote": + def accept( + quote: str, /, **params: Unpack["QuoteAcceptParams"] + ) -> "Quote": """ Accepts the specified quote. """ @@ -668,7 +670,7 @@ def accept( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_accept_async( - cls, quote: str, **params: Unpack["QuoteAcceptParams"] + cls, quote: str, /, **params: Unpack["QuoteAcceptParams"] ) -> "Quote": """ Accepts the specified quote. @@ -685,7 +687,7 @@ async def _cls_accept_async( @overload @staticmethod async def accept_async( - quote: str, **params: Unpack["QuoteAcceptParams"] + quote: str, /, **params: Unpack["QuoteAcceptParams"] ) -> "Quote": """ Accepts the specified quote. @@ -721,7 +723,7 @@ async def accept_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_cancel( - cls, quote: str, **params: Unpack["QuoteCancelParams"] + cls, quote: str, /, **params: Unpack["QuoteCancelParams"] ) -> "Quote": """ Cancels the quote. @@ -737,7 +739,9 @@ def _cls_cancel( @overload @staticmethod - def cancel(quote: str, **params: Unpack["QuoteCancelParams"]) -> "Quote": + def cancel( + quote: str, /, **params: Unpack["QuoteCancelParams"] + ) -> "Quote": """ Cancels the quote. """ @@ -770,7 +774,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, quote: str, **params: Unpack["QuoteCancelParams"] + cls, quote: str, /, **params: Unpack["QuoteCancelParams"] ) -> "Quote": """ Cancels the quote. @@ -787,7 +791,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - quote: str, **params: Unpack["QuoteCancelParams"] + quote: str, /, **params: Unpack["QuoteCancelParams"] ) -> "Quote": """ Cancels the quote. @@ -853,7 +857,7 @@ async def create_async( @classmethod def _cls_finalize_quote( - cls, quote: str, **params: Unpack["QuoteFinalizeQuoteParams"] + cls, quote: str, /, **params: Unpack["QuoteFinalizeQuoteParams"] ) -> "Quote": """ Finalizes the quote. @@ -870,7 +874,7 @@ def _cls_finalize_quote( @overload @staticmethod def finalize_quote( - quote: str, **params: Unpack["QuoteFinalizeQuoteParams"] + quote: str, /, **params: Unpack["QuoteFinalizeQuoteParams"] ) -> "Quote": """ Finalizes the quote. @@ -906,7 +910,7 @@ def finalize_quote( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_finalize_quote_async( - cls, quote: str, **params: Unpack["QuoteFinalizeQuoteParams"] + cls, quote: str, /, **params: Unpack["QuoteFinalizeQuoteParams"] ) -> "Quote": """ Finalizes the quote. @@ -923,7 +927,7 @@ async def _cls_finalize_quote_async( @overload @staticmethod async def finalize_quote_async( - quote: str, **params: Unpack["QuoteFinalizeQuoteParams"] + quote: str, /, **params: Unpack["QuoteFinalizeQuoteParams"] ) -> "Quote": """ Finalizes the quote. @@ -999,6 +1003,7 @@ async def list_async( def _cls_list_computed_upfront_line_items( cls, quote: str, + /, **params: Unpack["QuoteListComputedUpfrontLineItemsParams"], ) -> ListObject["LineItem"]: """ @@ -1018,7 +1023,9 @@ def _cls_list_computed_upfront_line_items( @overload @staticmethod def list_computed_upfront_line_items( - quote: str, **params: Unpack["QuoteListComputedUpfrontLineItemsParams"] + quote: str, + /, + **params: Unpack["QuoteListComputedUpfrontLineItemsParams"], ) -> ListObject["LineItem"]: """ When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items. @@ -1056,6 +1063,7 @@ def list_computed_upfront_line_items( # pyright: ignore[reportGeneralTypeIssues async def _cls_list_computed_upfront_line_items_async( cls, quote: str, + /, **params: Unpack["QuoteListComputedUpfrontLineItemsParams"], ) -> ListObject["LineItem"]: """ @@ -1075,7 +1083,9 @@ async def _cls_list_computed_upfront_line_items_async( @overload @staticmethod async def list_computed_upfront_line_items_async( - quote: str, **params: Unpack["QuoteListComputedUpfrontLineItemsParams"] + quote: str, + /, + **params: Unpack["QuoteListComputedUpfrontLineItemsParams"], ) -> ListObject["LineItem"]: """ When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items. @@ -1111,7 +1121,7 @@ async def list_computed_upfront_line_items_async( # pyright: ignore[reportGener @classmethod def _cls_list_line_items( - cls, quote: str, **params: Unpack["QuoteListLineItemsParams"] + cls, quote: str, /, **params: Unpack["QuoteListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -1130,7 +1140,7 @@ def _cls_list_line_items( @overload @staticmethod def list_line_items( - quote: str, **params: Unpack["QuoteListLineItemsParams"] + quote: str, /, **params: Unpack["QuoteListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -1166,7 +1176,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_list_line_items_async( - cls, quote: str, **params: Unpack["QuoteListLineItemsParams"] + cls, quote: str, /, **params: Unpack["QuoteListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -1185,7 +1195,7 @@ async def _cls_list_line_items_async( @overload @staticmethod async def list_line_items_async( - quote: str, **params: Unpack["QuoteListLineItemsParams"] + quote: str, /, **params: Unpack["QuoteListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -1252,7 +1262,9 @@ async def modify_async( ) @classmethod - def _cls_pdf(cls, quote: str, **params: Unpack["QuotePdfParams"]) -> Any: + def _cls_pdf( + cls, quote: str, /, **params: Unpack["QuotePdfParams"] + ) -> Any: """ Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf) """ @@ -1268,7 +1280,7 @@ def _cls_pdf(cls, quote: str, **params: Unpack["QuotePdfParams"]) -> Any: @overload @staticmethod - def pdf(quote: str, **params: Unpack["QuotePdfParams"]) -> Any: + def pdf(quote: str, /, **params: Unpack["QuotePdfParams"]) -> Any: """ Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf) """ @@ -1302,7 +1314,7 @@ def pdf( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_pdf_async( - cls, quote: str, **params: Unpack["QuotePdfParams"] + cls, quote: str, /, **params: Unpack["QuotePdfParams"] ) -> Any: """ Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf) @@ -1319,7 +1331,9 @@ async def _cls_pdf_async( @overload @staticmethod - async def pdf_async(quote: str, **params: Unpack["QuotePdfParams"]) -> Any: + async def pdf_async( + quote: str, /, **params: Unpack["QuotePdfParams"] + ) -> Any: """ Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf) """ diff --git a/stripe/_quote_computed_upfront_line_items_service.py b/stripe/_quote_computed_upfront_line_items_service.py index a9f5cf4d2..680bfb164 100644 --- a/stripe/_quote_computed_upfront_line_items_service.py +++ b/stripe/_quote_computed_upfront_line_items_service.py @@ -18,6 +18,7 @@ class QuoteComputedUpfrontLineItemsService(StripeService): def list( self, quote: str, + /, params: Optional["QuoteComputedUpfrontLineItemsListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, quote: str, + /, params: Optional["QuoteComputedUpfrontLineItemsListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": diff --git a/stripe/_quote_line_item_service.py b/stripe/_quote_line_item_service.py index ca5571800..b4ba6f24a 100644 --- a/stripe/_quote_line_item_service.py +++ b/stripe/_quote_line_item_service.py @@ -18,6 +18,7 @@ class QuoteLineItemService(StripeService): def list( self, quote: str, + /, params: Optional["QuoteLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, quote: str, + /, params: Optional["QuoteLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": diff --git a/stripe/_quote_service.py b/stripe/_quote_service.py index 80cd138b9..f75f87ee5 100644 --- a/stripe/_quote_service.py +++ b/stripe/_quote_service.py @@ -137,6 +137,7 @@ async def create_async( def retrieve( self, quote: str, + /, params: Optional["QuoteRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -157,6 +158,7 @@ def retrieve( async def retrieve_async( self, quote: str, + /, params: Optional["QuoteRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -177,6 +179,7 @@ async def retrieve_async( def update( self, quote: str, + /, params: Optional["QuoteUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -197,6 +200,7 @@ def update( async def update_async( self, quote: str, + /, params: Optional["QuoteUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -217,6 +221,7 @@ async def update_async( def accept( self, quote: str, + /, params: Optional["QuoteAcceptParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -237,6 +242,7 @@ def accept( async def accept_async( self, quote: str, + /, params: Optional["QuoteAcceptParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -257,6 +263,7 @@ async def accept_async( def cancel( self, quote: str, + /, params: Optional["QuoteCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -277,6 +284,7 @@ def cancel( async def cancel_async( self, quote: str, + /, params: Optional["QuoteCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -297,6 +305,7 @@ async def cancel_async( def finalize_quote( self, quote: str, + /, params: Optional["QuoteFinalizeQuoteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -317,6 +326,7 @@ def finalize_quote( async def finalize_quote_async( self, quote: str, + /, params: Optional["QuoteFinalizeQuoteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Quote": @@ -337,6 +347,7 @@ async def finalize_quote_async( def pdf( self, quote: str, + /, params: Optional["QuotePdfParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Any": @@ -357,6 +368,7 @@ def pdf( async def pdf_async( self, quote: str, + /, params: Optional["QuotePdfParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Any": diff --git a/stripe/_refund.py b/stripe/_refund.py index 3a873778e..608e4a08b 100644 --- a/stripe/_refund.py +++ b/stripe/_refund.py @@ -488,7 +488,7 @@ class PresentmentDetails(StripeObject): @classmethod def _cls_cancel( - cls, refund: str, **params: Unpack["RefundCancelParams"] + cls, refund: str, /, **params: Unpack["RefundCancelParams"] ) -> "Refund": """ Cancels a refund with a status of requires_action. @@ -509,7 +509,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - refund: str, **params: Unpack["RefundCancelParams"] + refund: str, /, **params: Unpack["RefundCancelParams"] ) -> "Refund": """ Cancels a refund with a status of requires_action. @@ -549,7 +549,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, refund: str, **params: Unpack["RefundCancelParams"] + cls, refund: str, /, **params: Unpack["RefundCancelParams"] ) -> "Refund": """ Cancels a refund with a status of requires_action. @@ -570,7 +570,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - refund: str, **params: Unpack["RefundCancelParams"] + refund: str, /, **params: Unpack["RefundCancelParams"] ) -> "Refund": """ Cancels a refund with a status of requires_action. @@ -765,7 +765,7 @@ class TestHelpers(APIResourceTestHelpers["Refund"]): @classmethod def _cls_expire( - cls, refund: str, **params: Unpack["RefundExpireParams"] + cls, refund: str, /, **params: Unpack["RefundExpireParams"] ) -> "Refund": """ Expire a refund with a status of requires_action. @@ -784,7 +784,7 @@ def _cls_expire( @overload @staticmethod def expire( - refund: str, **params: Unpack["RefundExpireParams"] + refund: str, /, **params: Unpack["RefundExpireParams"] ) -> "Refund": """ Expire a refund with a status of requires_action. @@ -818,7 +818,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_expire_async( - cls, refund: str, **params: Unpack["RefundExpireParams"] + cls, refund: str, /, **params: Unpack["RefundExpireParams"] ) -> "Refund": """ Expire a refund with a status of requires_action. @@ -837,7 +837,7 @@ async def _cls_expire_async( @overload @staticmethod async def expire_async( - refund: str, **params: Unpack["RefundExpireParams"] + refund: str, /, **params: Unpack["RefundExpireParams"] ) -> "Refund": """ Expire a refund with a status of requires_action. diff --git a/stripe/_refund_service.py b/stripe/_refund_service.py index 07b5c3417..d9a96c662 100644 --- a/stripe/_refund_service.py +++ b/stripe/_refund_service.py @@ -116,6 +116,7 @@ async def create_async( def retrieve( self, refund: str, + /, params: Optional["RefundRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": @@ -136,6 +137,7 @@ def retrieve( async def retrieve_async( self, refund: str, + /, params: Optional["RefundRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": @@ -156,6 +158,7 @@ async def retrieve_async( def update( self, refund: str, + /, params: Optional["RefundUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": @@ -178,6 +181,7 @@ def update( async def update_async( self, refund: str, + /, params: Optional["RefundUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": @@ -200,6 +204,7 @@ async def update_async( def cancel( self, refund: str, + /, params: Optional["RefundCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": @@ -224,6 +229,7 @@ def cancel( async def cancel_async( self, refund: str, + /, params: Optional["RefundCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": diff --git a/stripe/_review.py b/stripe/_review.py index 4f6de010e..482ed6732 100644 --- a/stripe/_review.py +++ b/stripe/_review.py @@ -136,7 +136,7 @@ class Session(StripeObject): @classmethod def _cls_approve( - cls, review: str, **params: Unpack["ReviewApproveParams"] + cls, review: str, /, **params: Unpack["ReviewApproveParams"] ) -> "Review": """ Approves a Review object, closing it and removing it from the list of reviews. @@ -155,7 +155,7 @@ def _cls_approve( @overload @staticmethod def approve( - review: str, **params: Unpack["ReviewApproveParams"] + review: str, /, **params: Unpack["ReviewApproveParams"] ) -> "Review": """ Approves a Review object, closing it and removing it from the list of reviews. @@ -189,7 +189,7 @@ def approve( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_approve_async( - cls, review: str, **params: Unpack["ReviewApproveParams"] + cls, review: str, /, **params: Unpack["ReviewApproveParams"] ) -> "Review": """ Approves a Review object, closing it and removing it from the list of reviews. @@ -208,7 +208,7 @@ async def _cls_approve_async( @overload @staticmethod async def approve_async( - review: str, **params: Unpack["ReviewApproveParams"] + review: str, /, **params: Unpack["ReviewApproveParams"] ) -> "Review": """ Approves a Review object, closing it and removing it from the list of reviews. diff --git a/stripe/_review_service.py b/stripe/_review_service.py index 030985dda..e2cb95135 100644 --- a/stripe/_review_service.py +++ b/stripe/_review_service.py @@ -56,6 +56,7 @@ async def list_async( def retrieve( self, review: str, + /, params: Optional["ReviewRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Review": @@ -76,6 +77,7 @@ def retrieve( async def retrieve_async( self, review: str, + /, params: Optional["ReviewRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Review": @@ -96,6 +98,7 @@ async def retrieve_async( def approve( self, review: str, + /, params: Optional["ReviewApproveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Review": @@ -118,6 +121,7 @@ def approve( async def approve_async( self, review: str, + /, params: Optional["ReviewApproveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Review": diff --git a/stripe/_setup_intent.py b/stripe/_setup_intent.py index b98824fbd..4794165df 100644 --- a/stripe/_setup_intent.py +++ b/stripe/_setup_intent.py @@ -1256,7 +1256,7 @@ class MandateOptions(StripeObject): @classmethod def _cls_cancel( - cls, intent: str, **params: Unpack["SetupIntentCancelParams"] + cls, intent: str, /, **params: Unpack["SetupIntentCancelParams"] ) -> "SetupIntent": """ You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. @@ -1277,7 +1277,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - intent: str, **params: Unpack["SetupIntentCancelParams"] + intent: str, /, **params: Unpack["SetupIntentCancelParams"] ) -> "SetupIntent": """ You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. @@ -1319,7 +1319,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, intent: str, **params: Unpack["SetupIntentCancelParams"] + cls, intent: str, /, **params: Unpack["SetupIntentCancelParams"] ) -> "SetupIntent": """ You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. @@ -1340,7 +1340,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - intent: str, **params: Unpack["SetupIntentCancelParams"] + intent: str, /, **params: Unpack["SetupIntentCancelParams"] ) -> "SetupIntent": """ You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action. @@ -1382,7 +1382,7 @@ async def cancel_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_confirm( - cls, intent: str, **params: Unpack["SetupIntentConfirmParams"] + cls, intent: str, /, **params: Unpack["SetupIntentConfirmParams"] ) -> "SetupIntent": """ Confirm that your customer intends to set up the current or @@ -1414,7 +1414,7 @@ def _cls_confirm( @overload @staticmethod def confirm( - intent: str, **params: Unpack["SetupIntentConfirmParams"] + intent: str, /, **params: Unpack["SetupIntentConfirmParams"] ) -> "SetupIntent": """ Confirm that your customer intends to set up the current or @@ -1489,7 +1489,7 @@ def confirm( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_confirm_async( - cls, intent: str, **params: Unpack["SetupIntentConfirmParams"] + cls, intent: str, /, **params: Unpack["SetupIntentConfirmParams"] ) -> "SetupIntent": """ Confirm that your customer intends to set up the current or @@ -1521,7 +1521,7 @@ async def _cls_confirm_async( @overload @staticmethod async def confirm_async( - intent: str, **params: Unpack["SetupIntentConfirmParams"] + intent: str, /, **params: Unpack["SetupIntentConfirmParams"] ) -> "SetupIntent": """ Confirm that your customer intends to set up the current or @@ -1740,6 +1740,7 @@ async def retrieve_async( def _cls_verify_microdeposits( cls, intent: str, + /, **params: Unpack["SetupIntentVerifyMicrodepositsParams"], ) -> "SetupIntent": """ @@ -1759,7 +1760,9 @@ def _cls_verify_microdeposits( @overload @staticmethod def verify_microdeposits( - intent: str, **params: Unpack["SetupIntentVerifyMicrodepositsParams"] + intent: str, + /, + **params: Unpack["SetupIntentVerifyMicrodepositsParams"], ) -> "SetupIntent": """ Verifies microdeposits on a SetupIntent object. @@ -1797,6 +1800,7 @@ def verify_microdeposits( # pyright: ignore[reportGeneralTypeIssues] async def _cls_verify_microdeposits_async( cls, intent: str, + /, **params: Unpack["SetupIntentVerifyMicrodepositsParams"], ) -> "SetupIntent": """ @@ -1816,7 +1820,9 @@ async def _cls_verify_microdeposits_async( @overload @staticmethod async def verify_microdeposits_async( - intent: str, **params: Unpack["SetupIntentVerifyMicrodepositsParams"] + intent: str, + /, + **params: Unpack["SetupIntentVerifyMicrodepositsParams"], ) -> "SetupIntent": """ Verifies microdeposits on a SetupIntent object. diff --git a/stripe/_setup_intent_service.py b/stripe/_setup_intent_service.py index 62d196d0c..f0adbeb4b 100644 --- a/stripe/_setup_intent_service.py +++ b/stripe/_setup_intent_service.py @@ -116,6 +116,7 @@ async def create_async( def retrieve( self, intent: str, + /, params: Optional["SetupIntentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -142,6 +143,7 @@ def retrieve( async def retrieve_async( self, intent: str, + /, params: Optional["SetupIntentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -168,6 +170,7 @@ async def retrieve_async( def update( self, intent: str, + /, params: Optional["SetupIntentUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -190,6 +193,7 @@ def update( async def update_async( self, intent: str, + /, params: Optional["SetupIntentUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -212,6 +216,7 @@ async def update_async( def cancel( self, intent: str, + /, params: Optional["SetupIntentCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -236,6 +241,7 @@ def cancel( async def cancel_async( self, intent: str, + /, params: Optional["SetupIntentCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -260,6 +266,7 @@ async def cancel_async( def confirm( self, intent: str, + /, params: Optional["SetupIntentConfirmParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -295,6 +302,7 @@ def confirm( async def confirm_async( self, intent: str, + /, params: Optional["SetupIntentConfirmParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -330,6 +338,7 @@ async def confirm_async( def verify_microdeposits( self, intent: str, + /, params: Optional["SetupIntentVerifyMicrodepositsParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": @@ -352,6 +361,7 @@ def verify_microdeposits( async def verify_microdeposits_async( self, intent: str, + /, params: Optional["SetupIntentVerifyMicrodepositsParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SetupIntent": diff --git a/stripe/_shipping_rate_service.py b/stripe/_shipping_rate_service.py index c11542923..739980bc6 100644 --- a/stripe/_shipping_rate_service.py +++ b/stripe/_shipping_rate_service.py @@ -101,6 +101,7 @@ async def create_async( def retrieve( self, shipping_rate_token: str, + /, params: Optional["ShippingRateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ShippingRate": @@ -123,6 +124,7 @@ def retrieve( async def retrieve_async( self, shipping_rate_token: str, + /, params: Optional["ShippingRateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ShippingRate": @@ -145,6 +147,7 @@ async def retrieve_async( def update( self, shipping_rate_token: str, + /, params: Optional["ShippingRateUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ShippingRate": @@ -167,6 +170,7 @@ def update( async def update_async( self, shipping_rate_token: str, + /, params: Optional["ShippingRateUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ShippingRate": diff --git a/stripe/_source.py b/stripe/_source.py index cec32918c..710580459 100644 --- a/stripe/_source.py +++ b/stripe/_source.py @@ -632,6 +632,7 @@ async def create_async( def _cls_list_source_transactions( cls, source: str, + /, **params: Unpack["SourceListSourceTransactionsParams"], ) -> ListObject["SourceTransaction"]: """ @@ -651,7 +652,7 @@ def _cls_list_source_transactions( @overload @staticmethod def list_source_transactions( - source: str, **params: Unpack["SourceListSourceTransactionsParams"] + source: str, /, **params: Unpack["SourceListSourceTransactionsParams"] ) -> ListObject["SourceTransaction"]: """ List source transactions for a given source. @@ -689,6 +690,7 @@ def list_source_transactions( # pyright: ignore[reportGeneralTypeIssues] async def _cls_list_source_transactions_async( cls, source: str, + /, **params: Unpack["SourceListSourceTransactionsParams"], ) -> ListObject["SourceTransaction"]: """ @@ -708,7 +710,7 @@ async def _cls_list_source_transactions_async( @overload @staticmethod async def list_source_transactions_async( - source: str, **params: Unpack["SourceListSourceTransactionsParams"] + source: str, /, **params: Unpack["SourceListSourceTransactionsParams"] ) -> ListObject["SourceTransaction"]: """ List source transactions for a given source. @@ -804,7 +806,7 @@ async def retrieve_async( @classmethod def _cls_verify( - cls, source: str, **params: Unpack["SourceVerifyParams"] + cls, source: str, /, **params: Unpack["SourceVerifyParams"] ) -> "Source": """ Verify a given source. @@ -823,7 +825,7 @@ def _cls_verify( @overload @staticmethod def verify( - source: str, **params: Unpack["SourceVerifyParams"] + source: str, /, **params: Unpack["SourceVerifyParams"] ) -> "Source": """ Verify a given source. @@ -857,7 +859,7 @@ def verify( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_verify_async( - cls, source: str, **params: Unpack["SourceVerifyParams"] + cls, source: str, /, **params: Unpack["SourceVerifyParams"] ) -> "Source": """ Verify a given source. @@ -876,7 +878,7 @@ async def _cls_verify_async( @overload @staticmethod async def verify_async( - source: str, **params: Unpack["SourceVerifyParams"] + source: str, /, **params: Unpack["SourceVerifyParams"] ) -> "Source": """ Verify a given source. diff --git a/stripe/_source_service.py b/stripe/_source_service.py index 849f2e742..7f7de39e9 100644 --- a/stripe/_source_service.py +++ b/stripe/_source_service.py @@ -54,6 +54,7 @@ def detach( self, customer: str, id: str, + /, params: Optional["SourceDetachParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -78,6 +79,7 @@ async def detach_async( self, customer: str, id: str, + /, params: Optional["SourceDetachParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Union[Account, BankAccount, Card, Source]": @@ -101,6 +103,7 @@ async def detach_async( def retrieve( self, source: str, + /, params: Optional["SourceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Source": @@ -121,6 +124,7 @@ def retrieve( async def retrieve_async( self, source: str, + /, params: Optional["SourceRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Source": @@ -141,6 +145,7 @@ async def retrieve_async( def update( self, source: str, + /, params: Optional["SourceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Source": @@ -163,6 +168,7 @@ def update( async def update_async( self, source: str, + /, params: Optional["SourceUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Source": @@ -223,6 +229,7 @@ async def create_async( def verify( self, source: str, + /, params: "SourceVerifyParams", options: Optional["RequestOptions"] = None, ) -> "Source": @@ -245,6 +252,7 @@ def verify( async def verify_async( self, source: str, + /, params: "SourceVerifyParams", options: Optional["RequestOptions"] = None, ) -> "Source": diff --git a/stripe/_source_transaction_service.py b/stripe/_source_transaction_service.py index b40e91503..c86b48bb3 100644 --- a/stripe/_source_transaction_service.py +++ b/stripe/_source_transaction_service.py @@ -18,6 +18,7 @@ class SourceTransactionService(StripeService): def list( self, source: str, + /, params: Optional["SourceTransactionListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[SourceTransaction]": @@ -40,6 +41,7 @@ def list( async def list_async( self, source: str, + /, params: Optional["SourceTransactionListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[SourceTransaction]": diff --git a/stripe/_subscription.py b/stripe/_subscription.py index 839181733..cfdeaeefb 100644 --- a/stripe/_subscription.py +++ b/stripe/_subscription.py @@ -1003,6 +1003,7 @@ class EndBehavior(StripeObject): def _cls_cancel( cls, subscription_exposed_id: str, + /, **params: Unpack["SubscriptionCancelParams"], ) -> "Subscription": """ @@ -1029,6 +1030,7 @@ def _cls_cancel( @staticmethod def cancel( subscription_exposed_id: str, + /, **params: Unpack["SubscriptionCancelParams"], ) -> "Subscription": """ @@ -1079,6 +1081,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] async def _cls_cancel_async( cls, subscription_exposed_id: str, + /, **params: Unpack["SubscriptionCancelParams"], ) -> "Subscription": """ @@ -1105,6 +1108,7 @@ async def _cls_cancel_async( @staticmethod async def cancel_async( subscription_exposed_id: str, + /, **params: Unpack["SubscriptionCancelParams"], ) -> "Subscription": """ @@ -1199,6 +1203,7 @@ async def create_async( def _cls_delete_discount( cls, subscription_exposed_id: str, + /, **params: Unpack["SubscriptionDeleteDiscountParams"], ) -> "Discount": """ @@ -1221,6 +1226,7 @@ def _cls_delete_discount( @staticmethod def delete_discount( subscription_exposed_id: str, + /, **params: Unpack["SubscriptionDeleteDiscountParams"], ) -> "Discount": """ @@ -1259,6 +1265,7 @@ def delete_discount( # pyright: ignore[reportGeneralTypeIssues] async def _cls_delete_discount_async( cls, subscription_exposed_id: str, + /, **params: Unpack["SubscriptionDeleteDiscountParams"], ) -> "Discount": """ @@ -1281,6 +1288,7 @@ async def _cls_delete_discount_async( @staticmethod async def delete_discount_async( subscription_exposed_id: str, + /, **params: Unpack["SubscriptionDeleteDiscountParams"], ) -> "Discount": """ @@ -1357,7 +1365,10 @@ async def list_async( @classmethod def _cls_migrate( - cls, subscription: str, **params: Unpack["SubscriptionMigrateParams"] + cls, + subscription: str, + /, + **params: Unpack["SubscriptionMigrateParams"], ) -> "Subscription": """ Upgrade the billing_mode of an existing subscription. @@ -1376,7 +1387,7 @@ def _cls_migrate( @overload @staticmethod def migrate( - subscription: str, **params: Unpack["SubscriptionMigrateParams"] + subscription: str, /, **params: Unpack["SubscriptionMigrateParams"] ) -> "Subscription": """ Upgrade the billing_mode of an existing subscription. @@ -1412,7 +1423,10 @@ def migrate( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_migrate_async( - cls, subscription: str, **params: Unpack["SubscriptionMigrateParams"] + cls, + subscription: str, + /, + **params: Unpack["SubscriptionMigrateParams"], ) -> "Subscription": """ Upgrade the billing_mode of an existing subscription. @@ -1431,7 +1445,7 @@ async def _cls_migrate_async( @overload @staticmethod async def migrate_async( - subscription: str, **params: Unpack["SubscriptionMigrateParams"] + subscription: str, /, **params: Unpack["SubscriptionMigrateParams"] ) -> "Subscription": """ Upgrade the billing_mode of an existing subscription. @@ -1541,7 +1555,7 @@ async def modify_async( @classmethod def _cls_resume( - cls, subscription: str, **params: Unpack["SubscriptionResumeParams"] + cls, subscription: str, /, **params: Unpack["SubscriptionResumeParams"] ) -> "Subscription": """ Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. Resume is only available for subscriptions that use charge_automatically collection. If Stripe doesn't generate a resumption invoice, the subscription becomes active immediately. When a resumption invoice is generated, Stripe finalizes it immediately. If the invoice is paid or marked uncollectible, the subscription becomes active. If the invoice is manually voided, the subscription stays paused. If there is no payment attempt within 23 hours, Stripe voids the invoice and the subscription stays paused. Learn more about [resuming subscriptions](https://docs.stripe.com/docs/billing/subscriptions/pause#resume-subscriptions). @@ -1560,7 +1574,7 @@ def _cls_resume( @overload @staticmethod def resume( - subscription: str, **params: Unpack["SubscriptionResumeParams"] + subscription: str, /, **params: Unpack["SubscriptionResumeParams"] ) -> "Subscription": """ Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. Resume is only available for subscriptions that use charge_automatically collection. If Stripe doesn't generate a resumption invoice, the subscription becomes active immediately. When a resumption invoice is generated, Stripe finalizes it immediately. If the invoice is paid or marked uncollectible, the subscription becomes active. If the invoice is manually voided, the subscription stays paused. If there is no payment attempt within 23 hours, Stripe voids the invoice and the subscription stays paused. Learn more about [resuming subscriptions](https://docs.stripe.com/docs/billing/subscriptions/pause#resume-subscriptions). @@ -1596,7 +1610,7 @@ def resume( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_resume_async( - cls, subscription: str, **params: Unpack["SubscriptionResumeParams"] + cls, subscription: str, /, **params: Unpack["SubscriptionResumeParams"] ) -> "Subscription": """ Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. Resume is only available for subscriptions that use charge_automatically collection. If Stripe doesn't generate a resumption invoice, the subscription becomes active immediately. When a resumption invoice is generated, Stripe finalizes it immediately. If the invoice is paid or marked uncollectible, the subscription becomes active. If the invoice is manually voided, the subscription stays paused. If there is no payment attempt within 23 hours, Stripe voids the invoice and the subscription stays paused. Learn more about [resuming subscriptions](https://docs.stripe.com/docs/billing/subscriptions/pause#resume-subscriptions). @@ -1615,7 +1629,7 @@ async def _cls_resume_async( @overload @staticmethod async def resume_async( - subscription: str, **params: Unpack["SubscriptionResumeParams"] + subscription: str, /, **params: Unpack["SubscriptionResumeParams"] ) -> "Subscription": """ Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. Resume is only available for subscriptions that use charge_automatically collection. If Stripe doesn't generate a resumption invoice, the subscription becomes active immediately. When a resumption invoice is generated, Stripe finalizes it immediately. If the invoice is paid or marked uncollectible, the subscription becomes active. If the invoice is manually voided, the subscription stays paused. If there is no payment attempt within 23 hours, Stripe voids the invoice and the subscription stays paused. Learn more about [resuming subscriptions](https://docs.stripe.com/docs/billing/subscriptions/pause#resume-subscriptions). diff --git a/stripe/_subscription_item_service.py b/stripe/_subscription_item_service.py index 304404337..0abcdcec8 100644 --- a/stripe/_subscription_item_service.py +++ b/stripe/_subscription_item_service.py @@ -30,6 +30,7 @@ class SubscriptionItemService(StripeService): def delete( self, item: str, + /, params: Optional["SubscriptionItemDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionItem": @@ -50,6 +51,7 @@ def delete( async def delete_async( self, item: str, + /, params: Optional["SubscriptionItemDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionItem": @@ -70,6 +72,7 @@ async def delete_async( def retrieve( self, item: str, + /, params: Optional["SubscriptionItemRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionItem": @@ -90,6 +93,7 @@ def retrieve( async def retrieve_async( self, item: str, + /, params: Optional["SubscriptionItemRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionItem": @@ -110,6 +114,7 @@ async def retrieve_async( def update( self, item: str, + /, params: Optional["SubscriptionItemUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionItem": @@ -130,6 +135,7 @@ def update( async def update_async( self, item: str, + /, params: Optional["SubscriptionItemUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionItem": diff --git a/stripe/_subscription_schedule.py b/stripe/_subscription_schedule.py index 28236fdb0..7b5d95441 100644 --- a/stripe/_subscription_schedule.py +++ b/stripe/_subscription_schedule.py @@ -651,6 +651,7 @@ class TransferData(StripeObject): def _cls_cancel( cls, schedule: str, + /, **params: Unpack["SubscriptionScheduleCancelParams"], ) -> "SubscriptionSchedule": """ @@ -670,7 +671,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - schedule: str, **params: Unpack["SubscriptionScheduleCancelParams"] + schedule: str, /, **params: Unpack["SubscriptionScheduleCancelParams"] ) -> "SubscriptionSchedule": """ Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active. @@ -708,6 +709,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] async def _cls_cancel_async( cls, schedule: str, + /, **params: Unpack["SubscriptionScheduleCancelParams"], ) -> "SubscriptionSchedule": """ @@ -727,7 +729,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - schedule: str, **params: Unpack["SubscriptionScheduleCancelParams"] + schedule: str, /, **params: Unpack["SubscriptionScheduleCancelParams"] ) -> "SubscriptionSchedule": """ Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active. @@ -871,6 +873,7 @@ async def modify_async( def _cls_release( cls, schedule: str, + /, **params: Unpack["SubscriptionScheduleReleaseParams"], ) -> "SubscriptionSchedule": """ @@ -890,7 +893,7 @@ def _cls_release( @overload @staticmethod def release( - schedule: str, **params: Unpack["SubscriptionScheduleReleaseParams"] + schedule: str, /, **params: Unpack["SubscriptionScheduleReleaseParams"] ) -> "SubscriptionSchedule": """ Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property. @@ -928,6 +931,7 @@ def release( # pyright: ignore[reportGeneralTypeIssues] async def _cls_release_async( cls, schedule: str, + /, **params: Unpack["SubscriptionScheduleReleaseParams"], ) -> "SubscriptionSchedule": """ @@ -947,7 +951,7 @@ async def _cls_release_async( @overload @staticmethod async def release_async( - schedule: str, **params: Unpack["SubscriptionScheduleReleaseParams"] + schedule: str, /, **params: Unpack["SubscriptionScheduleReleaseParams"] ) -> "SubscriptionSchedule": """ Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property. diff --git a/stripe/_subscription_schedule_service.py b/stripe/_subscription_schedule_service.py index ec9e74414..f76b6015f 100644 --- a/stripe/_subscription_schedule_service.py +++ b/stripe/_subscription_schedule_service.py @@ -109,6 +109,7 @@ async def create_async( def retrieve( self, schedule: str, + /, params: Optional["SubscriptionScheduleRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -131,6 +132,7 @@ def retrieve( async def retrieve_async( self, schedule: str, + /, params: Optional["SubscriptionScheduleRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -153,6 +155,7 @@ async def retrieve_async( def update( self, schedule: str, + /, params: Optional["SubscriptionScheduleUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -175,6 +178,7 @@ def update( async def update_async( self, schedule: str, + /, params: Optional["SubscriptionScheduleUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -197,6 +201,7 @@ async def update_async( def cancel( self, schedule: str, + /, params: Optional["SubscriptionScheduleCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -219,6 +224,7 @@ def cancel( async def cancel_async( self, schedule: str, + /, params: Optional["SubscriptionScheduleCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -241,6 +247,7 @@ async def cancel_async( def release( self, schedule: str, + /, params: Optional["SubscriptionScheduleReleaseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": @@ -263,6 +270,7 @@ def release( async def release_async( self, schedule: str, + /, params: Optional["SubscriptionScheduleReleaseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "SubscriptionSchedule": diff --git a/stripe/_subscription_service.py b/stripe/_subscription_service.py index d2dec8d9e..b47634e93 100644 --- a/stripe/_subscription_service.py +++ b/stripe/_subscription_service.py @@ -42,6 +42,7 @@ class SubscriptionService(StripeService): def cancel( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -70,6 +71,7 @@ def cancel( async def cancel_async( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -98,6 +100,7 @@ async def cancel_async( def retrieve( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -122,6 +125,7 @@ def retrieve( async def retrieve_async( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -146,6 +150,7 @@ async def retrieve_async( def update( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -190,6 +195,7 @@ def update( async def update_async( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -234,6 +240,7 @@ async def update_async( def delete_discount( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionDeleteDiscountParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Discount": @@ -258,6 +265,7 @@ def delete_discount( async def delete_discount_async( self, subscription_exposed_id: str, + /, params: Optional["SubscriptionDeleteDiscountParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Discount": @@ -414,6 +422,7 @@ async def search_async( def migrate( self, subscription: str, + /, params: "SubscriptionMigrateParams", options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -436,6 +445,7 @@ def migrate( async def migrate_async( self, subscription: str, + /, params: "SubscriptionMigrateParams", options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -458,6 +468,7 @@ async def migrate_async( def resume( self, subscription: str, + /, params: Optional["SubscriptionResumeParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": @@ -480,6 +491,7 @@ def resume( async def resume_async( self, subscription: str, + /, params: Optional["SubscriptionResumeParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Subscription": diff --git a/stripe/_tax_code_service.py b/stripe/_tax_code_service.py index ed5f2a54b..436a48f0b 100644 --- a/stripe/_tax_code_service.py +++ b/stripe/_tax_code_service.py @@ -55,6 +55,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["TaxCodeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxCode": @@ -75,6 +76,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["TaxCodeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxCode": diff --git a/stripe/_tax_id_service.py b/stripe/_tax_id_service.py index 8b3dbefcc..9325ccd54 100644 --- a/stripe/_tax_id_service.py +++ b/stripe/_tax_id_service.py @@ -19,6 +19,7 @@ class TaxIdService(StripeService): def delete( self, id: str, + /, params: Optional["TaxIdDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -39,6 +40,7 @@ def delete( async def delete_async( self, id: str, + /, params: Optional["TaxIdDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -59,6 +61,7 @@ async def delete_async( def retrieve( self, id: str, + /, params: Optional["TaxIdRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": @@ -79,6 +82,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["TaxIdRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxId": diff --git a/stripe/_tax_rate_service.py b/stripe/_tax_rate_service.py index 8645575d5..641f48ac9 100644 --- a/stripe/_tax_rate_service.py +++ b/stripe/_tax_rate_service.py @@ -95,6 +95,7 @@ async def create_async( def retrieve( self, tax_rate: str, + /, params: Optional["TaxRateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxRate": @@ -117,6 +118,7 @@ def retrieve( async def retrieve_async( self, tax_rate: str, + /, params: Optional["TaxRateRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxRate": @@ -139,6 +141,7 @@ async def retrieve_async( def update( self, tax_rate: str, + /, params: Optional["TaxRateUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxRate": @@ -161,6 +164,7 @@ def update( async def update_async( self, tax_rate: str, + /, params: Optional["TaxRateUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TaxRate": diff --git a/stripe/_token_service.py b/stripe/_token_service.py index a5cd81c28..ea024866b 100644 --- a/stripe/_token_service.py +++ b/stripe/_token_service.py @@ -16,6 +16,7 @@ class TokenService(StripeService): def retrieve( self, token: str, + /, params: Optional["TokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Token": @@ -36,6 +37,7 @@ def retrieve( async def retrieve_async( self, token: str, + /, params: Optional["TokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Token": diff --git a/stripe/_topup.py b/stripe/_topup.py index 296cd7d7f..1cbece59e 100644 --- a/stripe/_topup.py +++ b/stripe/_topup.py @@ -130,7 +130,7 @@ class UsBankAccount(StripeObject): @classmethod def _cls_cancel( - cls, topup: str, **params: Unpack["TopupCancelParams"] + cls, topup: str, /, **params: Unpack["TopupCancelParams"] ) -> "Topup": """ Cancels a top-up. Only pending top-ups can be canceled. @@ -146,7 +146,9 @@ def _cls_cancel( @overload @staticmethod - def cancel(topup: str, **params: Unpack["TopupCancelParams"]) -> "Topup": + def cancel( + topup: str, /, **params: Unpack["TopupCancelParams"] + ) -> "Topup": """ Cancels a top-up. Only pending top-ups can be canceled. """ @@ -179,7 +181,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, topup: str, **params: Unpack["TopupCancelParams"] + cls, topup: str, /, **params: Unpack["TopupCancelParams"] ) -> "Topup": """ Cancels a top-up. Only pending top-ups can be canceled. @@ -196,7 +198,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - topup: str, **params: Unpack["TopupCancelParams"] + topup: str, /, **params: Unpack["TopupCancelParams"] ) -> "Topup": """ Cancels a top-up. Only pending top-ups can be canceled. diff --git a/stripe/_topup_service.py b/stripe/_topup_service.py index 0f8b849fa..652cb0207 100644 --- a/stripe/_topup_service.py +++ b/stripe/_topup_service.py @@ -96,6 +96,7 @@ async def create_async( def retrieve( self, topup: str, + /, params: Optional["TopupRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Topup": @@ -116,6 +117,7 @@ def retrieve( async def retrieve_async( self, topup: str, + /, params: Optional["TopupRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Topup": @@ -136,6 +138,7 @@ async def retrieve_async( def update( self, topup: str, + /, params: Optional["TopupUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Topup": @@ -156,6 +159,7 @@ def update( async def update_async( self, topup: str, + /, params: Optional["TopupUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Topup": @@ -176,6 +180,7 @@ async def update_async( def cancel( self, topup: str, + /, params: Optional["TopupCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Topup": @@ -196,6 +201,7 @@ def cancel( async def cancel_async( self, topup: str, + /, params: Optional["TopupCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Topup": diff --git a/stripe/_transfer.py b/stripe/_transfer.py index 5d9bfd668..c746222ba 100644 --- a/stripe/_transfer.py +++ b/stripe/_transfer.py @@ -255,7 +255,7 @@ async def retrieve_async( @classmethod def list_reversals( - cls, id: str, **params: Unpack["TransferListReversalsParams"] + cls, id: str, /, **params: Unpack["TransferListReversalsParams"] ) -> ListObject["Reversal"]: """ You can see a list of the reversals belonging to a specific transfer. Note that the 10 most recent reversals are always available by default on the transfer object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional reversals. @@ -271,7 +271,7 @@ def list_reversals( @classmethod async def list_reversals_async( - cls, id: str, **params: Unpack["TransferListReversalsParams"] + cls, id: str, /, **params: Unpack["TransferListReversalsParams"] ) -> ListObject["Reversal"]: """ You can see a list of the reversals belonging to a specific transfer. Note that the 10 most recent reversals are always available by default on the transfer object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional reversals. @@ -287,7 +287,7 @@ async def list_reversals_async( @classmethod def create_reversal( - cls, id: str, **params: Unpack["TransferCreateReversalParams"] + cls, id: str, /, **params: Unpack["TransferCreateReversalParams"] ) -> "Reversal": """ When you create a new reversal, you must specify a transfer to create it on. @@ -307,7 +307,7 @@ def create_reversal( @classmethod async def create_reversal_async( - cls, id: str, **params: Unpack["TransferCreateReversalParams"] + cls, id: str, /, **params: Unpack["TransferCreateReversalParams"] ) -> "Reversal": """ When you create a new reversal, you must specify a transfer to create it on. @@ -330,6 +330,7 @@ def retrieve_reversal( cls, transfer: str, id: str, + /, **params: Unpack["TransferRetrieveReversalParams"], ) -> "Reversal": """ @@ -351,6 +352,7 @@ async def retrieve_reversal_async( cls, transfer: str, id: str, + /, **params: Unpack["TransferRetrieveReversalParams"], ) -> "Reversal": """ @@ -372,6 +374,7 @@ def modify_reversal( cls, transfer: str, id: str, + /, **params: Unpack["TransferModifyReversalParams"], ) -> "Reversal": """ @@ -395,6 +398,7 @@ async def modify_reversal_async( cls, transfer: str, id: str, + /, **params: Unpack["TransferModifyReversalParams"], ) -> "Reversal": """ diff --git a/stripe/_transfer_reversal_service.py b/stripe/_transfer_reversal_service.py index 0d74e0684..e25f76cf0 100644 --- a/stripe/_transfer_reversal_service.py +++ b/stripe/_transfer_reversal_service.py @@ -27,6 +27,7 @@ class TransferReversalService(StripeService): def list( self, id: str, + /, params: Optional["TransferReversalListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Reversal]": @@ -47,6 +48,7 @@ def list( async def list_async( self, id: str, + /, params: Optional["TransferReversalListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[Reversal]": @@ -67,6 +69,7 @@ async def list_async( def create( self, id: str, + /, params: Optional["TransferReversalCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reversal": @@ -91,6 +94,7 @@ def create( async def create_async( self, id: str, + /, params: Optional["TransferReversalCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reversal": @@ -116,6 +120,7 @@ def retrieve( self, transfer: str, id: str, + /, params: Optional["TransferReversalRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reversal": @@ -140,6 +145,7 @@ async def retrieve_async( self, transfer: str, id: str, + /, params: Optional["TransferReversalRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reversal": @@ -164,6 +170,7 @@ def update( self, transfer: str, id: str, + /, params: Optional["TransferReversalUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reversal": @@ -190,6 +197,7 @@ async def update_async( self, transfer: str, id: str, + /, params: Optional["TransferReversalUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reversal": diff --git a/stripe/_transfer_service.py b/stripe/_transfer_service.py index 4a32fb4f8..281f12470 100644 --- a/stripe/_transfer_service.py +++ b/stripe/_transfer_service.py @@ -125,6 +125,7 @@ async def create_async( def retrieve( self, transfer: str, + /, params: Optional["TransferRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transfer": @@ -147,6 +148,7 @@ def retrieve( async def retrieve_async( self, transfer: str, + /, params: Optional["TransferRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transfer": @@ -169,6 +171,7 @@ async def retrieve_async( def update( self, transfer: str, + /, params: Optional["TransferUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transfer": @@ -193,6 +196,7 @@ def update( async def update_async( self, transfer: str, + /, params: Optional["TransferUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transfer": diff --git a/stripe/_webhook_endpoint_service.py b/stripe/_webhook_endpoint_service.py index 22c517185..e54453a90 100644 --- a/stripe/_webhook_endpoint_service.py +++ b/stripe/_webhook_endpoint_service.py @@ -30,6 +30,7 @@ class WebhookEndpointService(StripeService): def delete( self, webhook_endpoint: str, + /, params: Optional["WebhookEndpointDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "WebhookEndpoint": @@ -52,6 +53,7 @@ def delete( async def delete_async( self, webhook_endpoint: str, + /, params: Optional["WebhookEndpointDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "WebhookEndpoint": @@ -74,6 +76,7 @@ async def delete_async( def retrieve( self, webhook_endpoint: str, + /, params: Optional["WebhookEndpointRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "WebhookEndpoint": @@ -96,6 +99,7 @@ def retrieve( async def retrieve_async( self, webhook_endpoint: str, + /, params: Optional["WebhookEndpointRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "WebhookEndpoint": @@ -118,6 +122,7 @@ async def retrieve_async( def update( self, webhook_endpoint: str, + /, params: Optional["WebhookEndpointUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "WebhookEndpoint": @@ -140,6 +145,7 @@ def update( async def update_async( self, webhook_endpoint: str, + /, params: Optional["WebhookEndpointUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "WebhookEndpoint": diff --git a/stripe/billing/_alert.py b/stripe/billing/_alert.py index c123e4ee2..7ea28cb4e 100644 --- a/stripe/billing/_alert.py +++ b/stripe/billing/_alert.py @@ -90,7 +90,7 @@ class Filter(StripeObject): @classmethod def _cls_activate( - cls, id: str, **params: Unpack["AlertActivateParams"] + cls, id: str, /, **params: Unpack["AlertActivateParams"] ) -> "Alert": """ Reactivates this alert, allowing it to trigger again. @@ -106,7 +106,9 @@ def _cls_activate( @overload @staticmethod - def activate(id: str, **params: Unpack["AlertActivateParams"]) -> "Alert": + def activate( + id: str, /, **params: Unpack["AlertActivateParams"] + ) -> "Alert": """ Reactivates this alert, allowing it to trigger again. """ @@ -139,7 +141,7 @@ def activate( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_activate_async( - cls, id: str, **params: Unpack["AlertActivateParams"] + cls, id: str, /, **params: Unpack["AlertActivateParams"] ) -> "Alert": """ Reactivates this alert, allowing it to trigger again. @@ -156,7 +158,7 @@ async def _cls_activate_async( @overload @staticmethod async def activate_async( - id: str, **params: Unpack["AlertActivateParams"] + id: str, /, **params: Unpack["AlertActivateParams"] ) -> "Alert": """ Reactivates this alert, allowing it to trigger again. @@ -192,7 +194,7 @@ async def activate_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_archive( - cls, id: str, **params: Unpack["AlertArchiveParams"] + cls, id: str, /, **params: Unpack["AlertArchiveParams"] ) -> "Alert": """ Archives this alert, removing it from the list view and APIs. This is non-reversible. @@ -208,7 +210,7 @@ def _cls_archive( @overload @staticmethod - def archive(id: str, **params: Unpack["AlertArchiveParams"]) -> "Alert": + def archive(id: str, /, **params: Unpack["AlertArchiveParams"]) -> "Alert": """ Archives this alert, removing it from the list view and APIs. This is non-reversible. """ @@ -241,7 +243,7 @@ def archive( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_archive_async( - cls, id: str, **params: Unpack["AlertArchiveParams"] + cls, id: str, /, **params: Unpack["AlertArchiveParams"] ) -> "Alert": """ Archives this alert, removing it from the list view and APIs. This is non-reversible. @@ -258,7 +260,7 @@ async def _cls_archive_async( @overload @staticmethod async def archive_async( - id: str, **params: Unpack["AlertArchiveParams"] + id: str, /, **params: Unpack["AlertArchiveParams"] ) -> "Alert": """ Archives this alert, removing it from the list view and APIs. This is non-reversible. @@ -324,7 +326,7 @@ async def create_async( @classmethod def _cls_deactivate( - cls, id: str, **params: Unpack["AlertDeactivateParams"] + cls, id: str, /, **params: Unpack["AlertDeactivateParams"] ) -> "Alert": """ Deactivates this alert, preventing it from triggering. @@ -343,7 +345,7 @@ def _cls_deactivate( @overload @staticmethod def deactivate( - id: str, **params: Unpack["AlertDeactivateParams"] + id: str, /, **params: Unpack["AlertDeactivateParams"] ) -> "Alert": """ Deactivates this alert, preventing it from triggering. @@ -377,7 +379,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_deactivate_async( - cls, id: str, **params: Unpack["AlertDeactivateParams"] + cls, id: str, /, **params: Unpack["AlertDeactivateParams"] ) -> "Alert": """ Deactivates this alert, preventing it from triggering. @@ -396,7 +398,7 @@ async def _cls_deactivate_async( @overload @staticmethod async def deactivate_async( - id: str, **params: Unpack["AlertDeactivateParams"] + id: str, /, **params: Unpack["AlertDeactivateParams"] ) -> "Alert": """ Deactivates this alert, preventing it from triggering. diff --git a/stripe/billing/_alert_service.py b/stripe/billing/_alert_service.py index 88840dc2d..5a683dc73 100644 --- a/stripe/billing/_alert_service.py +++ b/stripe/billing/_alert_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["AlertRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -123,6 +124,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["AlertRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -143,6 +145,7 @@ async def retrieve_async( def activate( self, id: str, + /, params: Optional["AlertActivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -163,6 +166,7 @@ def activate( async def activate_async( self, id: str, + /, params: Optional["AlertActivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -183,6 +187,7 @@ async def activate_async( def archive( self, id: str, + /, params: Optional["AlertArchiveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -203,6 +208,7 @@ def archive( async def archive_async( self, id: str, + /, params: Optional["AlertArchiveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -223,6 +229,7 @@ async def archive_async( def deactivate( self, id: str, + /, params: Optional["AlertDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": @@ -245,6 +252,7 @@ def deactivate( async def deactivate_async( self, id: str, + /, params: Optional["AlertDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Alert": diff --git a/stripe/billing/_credit_balance_transaction_service.py b/stripe/billing/_credit_balance_transaction_service.py index 52f511b49..5e36f3430 100644 --- a/stripe/billing/_credit_balance_transaction_service.py +++ b/stripe/billing/_credit_balance_transaction_service.py @@ -61,6 +61,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["CreditBalanceTransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditBalanceTransaction": @@ -83,6 +84,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["CreditBalanceTransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditBalanceTransaction": diff --git a/stripe/billing/_credit_grant.py b/stripe/billing/_credit_grant.py index 7795584ed..31d5bcf01 100644 --- a/stripe/billing/_credit_grant.py +++ b/stripe/billing/_credit_grant.py @@ -187,7 +187,7 @@ async def create_async( @classmethod def _cls_expire( - cls, id: str, **params: Unpack["CreditGrantExpireParams"] + cls, id: str, /, **params: Unpack["CreditGrantExpireParams"] ) -> "CreditGrant": """ Expires a credit grant. @@ -206,7 +206,7 @@ def _cls_expire( @overload @staticmethod def expire( - id: str, **params: Unpack["CreditGrantExpireParams"] + id: str, /, **params: Unpack["CreditGrantExpireParams"] ) -> "CreditGrant": """ Expires a credit grant. @@ -242,7 +242,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_expire_async( - cls, id: str, **params: Unpack["CreditGrantExpireParams"] + cls, id: str, /, **params: Unpack["CreditGrantExpireParams"] ) -> "CreditGrant": """ Expires a credit grant. @@ -261,7 +261,7 @@ async def _cls_expire_async( @overload @staticmethod async def expire_async( - id: str, **params: Unpack["CreditGrantExpireParams"] + id: str, /, **params: Unpack["CreditGrantExpireParams"] ) -> "CreditGrant": """ Expires a credit grant. @@ -393,7 +393,7 @@ async def retrieve_async( @classmethod def _cls_void_grant( - cls, id: str, **params: Unpack["CreditGrantVoidGrantParams"] + cls, id: str, /, **params: Unpack["CreditGrantVoidGrantParams"] ) -> "CreditGrant": """ Voids a credit grant. @@ -412,7 +412,7 @@ def _cls_void_grant( @overload @staticmethod def void_grant( - id: str, **params: Unpack["CreditGrantVoidGrantParams"] + id: str, /, **params: Unpack["CreditGrantVoidGrantParams"] ) -> "CreditGrant": """ Voids a credit grant. @@ -448,7 +448,7 @@ def void_grant( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_void_grant_async( - cls, id: str, **params: Unpack["CreditGrantVoidGrantParams"] + cls, id: str, /, **params: Unpack["CreditGrantVoidGrantParams"] ) -> "CreditGrant": """ Voids a credit grant. @@ -467,7 +467,7 @@ async def _cls_void_grant_async( @overload @staticmethod async def void_grant_async( - id: str, **params: Unpack["CreditGrantVoidGrantParams"] + id: str, /, **params: Unpack["CreditGrantVoidGrantParams"] ) -> "CreditGrant": """ Voids a credit grant. diff --git a/stripe/billing/_credit_grant_service.py b/stripe/billing/_credit_grant_service.py index 047cf0f57..4a84f4b0e 100644 --- a/stripe/billing/_credit_grant_service.py +++ b/stripe/billing/_credit_grant_service.py @@ -109,6 +109,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["CreditGrantRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -129,6 +130,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["CreditGrantRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -149,6 +151,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["CreditGrantUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -169,6 +172,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["CreditGrantUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -189,6 +193,7 @@ async def update_async( def expire( self, id: str, + /, params: Optional["CreditGrantExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -211,6 +216,7 @@ def expire( async def expire_async( self, id: str, + /, params: Optional["CreditGrantExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -233,6 +239,7 @@ async def expire_async( def void_grant( self, id: str, + /, params: Optional["CreditGrantVoidGrantParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": @@ -255,6 +262,7 @@ def void_grant( async def void_grant_async( self, id: str, + /, params: Optional["CreditGrantVoidGrantParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditGrant": diff --git a/stripe/billing/_feedback_option.py b/stripe/billing/_feedback_option.py index c1b1da92c..2080ad9ec 100644 --- a/stripe/billing/_feedback_option.py +++ b/stripe/billing/_feedback_option.py @@ -102,7 +102,7 @@ async def create_async( @classmethod def _cls_deactivate( - cls, id: str, **params: Unpack["FeedbackOptionDeactivateParams"] + cls, id: str, /, **params: Unpack["FeedbackOptionDeactivateParams"] ) -> "FeedbackOption": """ Deactivates a feedback option. Deactivated feedback options cannot be used in portal configurations. @@ -121,7 +121,7 @@ def _cls_deactivate( @overload @staticmethod def deactivate( - id: str, **params: Unpack["FeedbackOptionDeactivateParams"] + id: str, /, **params: Unpack["FeedbackOptionDeactivateParams"] ) -> "FeedbackOption": """ Deactivates a feedback option. Deactivated feedback options cannot be used in portal configurations. @@ -157,7 +157,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_deactivate_async( - cls, id: str, **params: Unpack["FeedbackOptionDeactivateParams"] + cls, id: str, /, **params: Unpack["FeedbackOptionDeactivateParams"] ) -> "FeedbackOption": """ Deactivates a feedback option. Deactivated feedback options cannot be used in portal configurations. @@ -176,7 +176,7 @@ async def _cls_deactivate_async( @overload @staticmethod async def deactivate_async( - id: str, **params: Unpack["FeedbackOptionDeactivateParams"] + id: str, /, **params: Unpack["FeedbackOptionDeactivateParams"] ) -> "FeedbackOption": """ Deactivates a feedback option. Deactivated feedback options cannot be used in portal configurations. diff --git a/stripe/billing/_feedback_option_service.py b/stripe/billing/_feedback_option_service.py index e8560ac3e..6280e97b3 100644 --- a/stripe/billing/_feedback_option_service.py +++ b/stripe/billing/_feedback_option_service.py @@ -106,6 +106,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["FeedbackOptionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FeedbackOption": @@ -126,6 +127,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["FeedbackOptionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FeedbackOption": @@ -146,6 +148,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["FeedbackOptionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FeedbackOption": @@ -166,6 +169,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["FeedbackOptionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FeedbackOption": @@ -186,6 +190,7 @@ async def update_async( def deactivate( self, id: str, + /, params: Optional["FeedbackOptionDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FeedbackOption": @@ -208,6 +213,7 @@ def deactivate( async def deactivate_async( self, id: str, + /, params: Optional["FeedbackOptionDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FeedbackOption": diff --git a/stripe/billing/_meter.py b/stripe/billing/_meter.py index 4f27637b2..1ccd6b06c 100644 --- a/stripe/billing/_meter.py +++ b/stripe/billing/_meter.py @@ -144,7 +144,7 @@ async def create_async( @classmethod def _cls_deactivate( - cls, id: str, **params: Unpack["MeterDeactivateParams"] + cls, id: str, /, **params: Unpack["MeterDeactivateParams"] ) -> "Meter": """ When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price. @@ -163,7 +163,7 @@ def _cls_deactivate( @overload @staticmethod def deactivate( - id: str, **params: Unpack["MeterDeactivateParams"] + id: str, /, **params: Unpack["MeterDeactivateParams"] ) -> "Meter": """ When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price. @@ -197,7 +197,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_deactivate_async( - cls, id: str, **params: Unpack["MeterDeactivateParams"] + cls, id: str, /, **params: Unpack["MeterDeactivateParams"] ) -> "Meter": """ When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price. @@ -216,7 +216,7 @@ async def _cls_deactivate_async( @overload @staticmethod async def deactivate_async( - id: str, **params: Unpack["MeterDeactivateParams"] + id: str, /, **params: Unpack["MeterDeactivateParams"] ) -> "Meter": """ When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price. @@ -322,7 +322,7 @@ async def modify_async( @classmethod def _cls_reactivate( - cls, id: str, **params: Unpack["MeterReactivateParams"] + cls, id: str, /, **params: Unpack["MeterReactivateParams"] ) -> "Meter": """ When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price. @@ -341,7 +341,7 @@ def _cls_reactivate( @overload @staticmethod def reactivate( - id: str, **params: Unpack["MeterReactivateParams"] + id: str, /, **params: Unpack["MeterReactivateParams"] ) -> "Meter": """ When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price. @@ -375,7 +375,7 @@ def reactivate( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_reactivate_async( - cls, id: str, **params: Unpack["MeterReactivateParams"] + cls, id: str, /, **params: Unpack["MeterReactivateParams"] ) -> "Meter": """ When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price. @@ -394,7 +394,7 @@ async def _cls_reactivate_async( @overload @staticmethod async def reactivate_async( - id: str, **params: Unpack["MeterReactivateParams"] + id: str, /, **params: Unpack["MeterReactivateParams"] ) -> "Meter": """ When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price. @@ -452,7 +452,7 @@ async def retrieve_async( @classmethod def list_event_summaries( - cls, id: str, **params: Unpack["MeterListEventSummariesParams"] + cls, id: str, /, **params: Unpack["MeterListEventSummariesParams"] ) -> ListObject["MeterEventSummary"]: """ Retrieve a list of billing meter event summaries. @@ -470,7 +470,7 @@ def list_event_summaries( @classmethod async def list_event_summaries_async( - cls, id: str, **params: Unpack["MeterListEventSummariesParams"] + cls, id: str, /, **params: Unpack["MeterListEventSummariesParams"] ) -> ListObject["MeterEventSummary"]: """ Retrieve a list of billing meter event summaries. diff --git a/stripe/billing/_meter_event_summary_service.py b/stripe/billing/_meter_event_summary_service.py index 3cc196d0e..b12857c03 100644 --- a/stripe/billing/_meter_event_summary_service.py +++ b/stripe/billing/_meter_event_summary_service.py @@ -18,6 +18,7 @@ class MeterEventSummaryService(StripeService): def list( self, id: str, + /, params: "MeterEventSummaryListParams", options: Optional["RequestOptions"] = None, ) -> "ListObject[MeterEventSummary]": @@ -40,6 +41,7 @@ def list( async def list_async( self, id: str, + /, params: "MeterEventSummaryListParams", options: Optional["RequestOptions"] = None, ) -> "ListObject[MeterEventSummary]": diff --git a/stripe/billing/_meter_service.py b/stripe/billing/_meter_service.py index 018b4ff73..7ac2efc5d 100644 --- a/stripe/billing/_meter_service.py +++ b/stripe/billing/_meter_service.py @@ -135,6 +135,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["MeterRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -155,6 +156,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["MeterRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -175,6 +177,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["MeterUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -195,6 +198,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["MeterUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -215,6 +219,7 @@ async def update_async( def deactivate( self, id: str, + /, params: Optional["MeterDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -237,6 +242,7 @@ def deactivate( async def deactivate_async( self, id: str, + /, params: Optional["MeterDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -259,6 +265,7 @@ async def deactivate_async( def reactivate( self, id: str, + /, params: Optional["MeterReactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": @@ -281,6 +288,7 @@ def reactivate( async def reactivate_async( self, id: str, + /, params: Optional["MeterReactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Meter": diff --git a/stripe/billing_portal/_configuration_service.py b/stripe/billing_portal/_configuration_service.py index ba9084e70..84f33f6cd 100644 --- a/stripe/billing_portal/_configuration_service.py +++ b/stripe/billing_portal/_configuration_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, configuration: str, + /, params: Optional["ConfigurationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, configuration: str, + /, params: Optional["ConfigurationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -147,6 +149,7 @@ async def retrieve_async( def update( self, configuration: str, + /, params: Optional["ConfigurationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -169,6 +172,7 @@ def update( async def update_async( self, configuration: str, + /, params: Optional["ConfigurationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": diff --git a/stripe/checkout/_session.py b/stripe/checkout/_session.py index eeda495c4..848c65d8c 100644 --- a/stripe/checkout/_session.py +++ b/stripe/checkout/_session.py @@ -872,7 +872,7 @@ class AfterpayClearpay(StripeObject): """ class Alipay(StripeObject): - setup_future_usage: Optional[Literal["none"]] + setup_future_usage: Optional[Union[Literal["none"], str]] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. @@ -1817,7 +1817,7 @@ class WechatPay(StripeObject): """ The client type that the end customer will pay from """ - setup_future_usage: Optional[Literal["none"]] + setup_future_usage: Optional[Union[Literal["none"], str]] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. @@ -2761,7 +2761,7 @@ async def create_async( @classmethod def _cls_expire( - cls, session: str, **params: Unpack["SessionExpireParams"] + cls, session: str, /, **params: Unpack["SessionExpireParams"] ) -> "Session": """ A Checkout Session can be expired when it is in one of these statuses: open @@ -2782,7 +2782,7 @@ def _cls_expire( @overload @staticmethod def expire( - session: str, **params: Unpack["SessionExpireParams"] + session: str, /, **params: Unpack["SessionExpireParams"] ) -> "Session": """ A Checkout Session can be expired when it is in one of these statuses: open @@ -2822,7 +2822,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_expire_async( - cls, session: str, **params: Unpack["SessionExpireParams"] + cls, session: str, /, **params: Unpack["SessionExpireParams"] ) -> "Session": """ A Checkout Session can be expired when it is in one of these statuses: open @@ -2843,7 +2843,7 @@ async def _cls_expire_async( @overload @staticmethod async def expire_async( - session: str, **params: Unpack["SessionExpireParams"] + session: str, /, **params: Unpack["SessionExpireParams"] ) -> "Session": """ A Checkout Session can be expired when it is in one of these statuses: open @@ -2925,7 +2925,7 @@ async def list_async( @classmethod def _cls_list_line_items( - cls, session: str, **params: Unpack["SessionListLineItemsParams"] + cls, session: str, /, **params: Unpack["SessionListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -2944,7 +2944,7 @@ def _cls_list_line_items( @overload @staticmethod def list_line_items( - session: str, **params: Unpack["SessionListLineItemsParams"] + session: str, /, **params: Unpack["SessionListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -2980,7 +2980,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_list_line_items_async( - cls, session: str, **params: Unpack["SessionListLineItemsParams"] + cls, session: str, /, **params: Unpack["SessionListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. @@ -2999,7 +2999,7 @@ async def _cls_list_line_items_async( @overload @staticmethod async def list_line_items_async( - session: str, **params: Unpack["SessionListLineItemsParams"] + session: str, /, **params: Unpack["SessionListLineItemsParams"] ) -> ListObject["LineItem"]: """ When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items. diff --git a/stripe/checkout/_session_line_item_service.py b/stripe/checkout/_session_line_item_service.py index e056ae2ba..4c2855fab 100644 --- a/stripe/checkout/_session_line_item_service.py +++ b/stripe/checkout/_session_line_item_service.py @@ -18,6 +18,7 @@ class SessionLineItemService(StripeService): def list( self, session: str, + /, params: Optional["SessionLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, session: str, + /, params: Optional["SessionLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[LineItem]": diff --git a/stripe/checkout/_session_service.py b/stripe/checkout/_session_service.py index db68e1b5f..96664e0af 100644 --- a/stripe/checkout/_session_service.py +++ b/stripe/checkout/_session_service.py @@ -136,6 +136,7 @@ async def create_async( def retrieve( self, session: str, + /, params: Optional["SessionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": @@ -158,6 +159,7 @@ def retrieve( async def retrieve_async( self, session: str, + /, params: Optional["SessionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": @@ -180,6 +182,7 @@ async def retrieve_async( def update( self, session: str, + /, params: Optional["SessionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": @@ -204,6 +207,7 @@ def update( async def update_async( self, session: str, + /, params: Optional["SessionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": @@ -228,6 +232,7 @@ async def update_async( def expire( self, session: str, + /, params: Optional["SessionExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": @@ -252,6 +257,7 @@ def expire( async def expire_async( self, session: str, + /, params: Optional["SessionExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": diff --git a/stripe/climate/_order.py b/stripe/climate/_order.py index 75c5bcc5a..b491769ca 100644 --- a/stripe/climate/_order.py +++ b/stripe/climate/_order.py @@ -181,7 +181,7 @@ class Location(StripeObject): @classmethod def _cls_cancel( - cls, order: str, **params: Unpack["OrderCancelParams"] + cls, order: str, /, **params: Unpack["OrderCancelParams"] ) -> "Order": """ Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the @@ -202,7 +202,9 @@ def _cls_cancel( @overload @staticmethod - def cancel(order: str, **params: Unpack["OrderCancelParams"]) -> "Order": + def cancel( + order: str, /, **params: Unpack["OrderCancelParams"] + ) -> "Order": """ Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier @@ -244,7 +246,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, order: str, **params: Unpack["OrderCancelParams"] + cls, order: str, /, **params: Unpack["OrderCancelParams"] ) -> "Order": """ Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the @@ -266,7 +268,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - order: str, **params: Unpack["OrderCancelParams"] + order: str, /, **params: Unpack["OrderCancelParams"] ) -> "Order": """ Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the diff --git a/stripe/climate/_order_service.py b/stripe/climate/_order_service.py index 0eb3b4859..719c13ad0 100644 --- a/stripe/climate/_order_service.py +++ b/stripe/climate/_order_service.py @@ -102,6 +102,7 @@ async def create_async( def retrieve( self, order: str, + /, params: Optional["OrderRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Order": @@ -122,6 +123,7 @@ def retrieve( async def retrieve_async( self, order: str, + /, params: Optional["OrderRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Order": @@ -142,6 +144,7 @@ async def retrieve_async( def update( self, order: str, + /, params: Optional["OrderUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Order": @@ -162,6 +165,7 @@ def update( async def update_async( self, order: str, + /, params: Optional["OrderUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Order": @@ -182,6 +186,7 @@ async def update_async( def cancel( self, order: str, + /, params: Optional["OrderCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Order": @@ -207,6 +212,7 @@ def cancel( async def cancel_async( self, order: str, + /, params: Optional["OrderCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Order": diff --git a/stripe/climate/_product_service.py b/stripe/climate/_product_service.py index d58cd419b..fe261feb8 100644 --- a/stripe/climate/_product_service.py +++ b/stripe/climate/_product_service.py @@ -57,6 +57,7 @@ async def list_async( def retrieve( self, product: str, + /, params: Optional["ProductRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": @@ -79,6 +80,7 @@ def retrieve( async def retrieve_async( self, product: str, + /, params: Optional["ProductRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Product": diff --git a/stripe/climate/_supplier_service.py b/stripe/climate/_supplier_service.py index f31a10f93..dc4598b90 100644 --- a/stripe/climate/_supplier_service.py +++ b/stripe/climate/_supplier_service.py @@ -57,6 +57,7 @@ async def list_async( def retrieve( self, supplier: str, + /, params: Optional["SupplierRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Supplier": @@ -79,6 +80,7 @@ def retrieve( async def retrieve_async( self, supplier: str, + /, params: Optional["SupplierRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Supplier": diff --git a/stripe/entitlements/_active_entitlement_service.py b/stripe/entitlements/_active_entitlement_service.py index db359907c..67f407459 100644 --- a/stripe/entitlements/_active_entitlement_service.py +++ b/stripe/entitlements/_active_entitlement_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["ActiveEntitlementRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ActiveEntitlement": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["ActiveEntitlementRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ActiveEntitlement": diff --git a/stripe/entitlements/_feature_service.py b/stripe/entitlements/_feature_service.py index 6844a337e..dfbe7304f 100644 --- a/stripe/entitlements/_feature_service.py +++ b/stripe/entitlements/_feature_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["FeatureRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Feature": @@ -123,6 +124,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["FeatureRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Feature": @@ -143,6 +145,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["FeatureUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Feature": @@ -163,6 +166,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["FeatureUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Feature": diff --git a/stripe/events/_v2_core_account_including_configuration_customer_capability_status_updated_event.py b/stripe/events/_v2_core_account_including_configuration_customer_capability_status_updated_event.py index e15b8704b..ebb479694 100644 --- a/stripe/events/_v2_core_account_including_configuration_customer_capability_status_updated_event.py +++ b/stripe/events/_v2_core_account_including_configuration_customer_capability_status_updated_event.py @@ -5,7 +5,7 @@ from stripe._stripe_response import StripeResponse from stripe._util import get_api_mode from stripe.v2.core._event import Event, EventNotification, RelatedObject -from typing import Any, Dict, Optional, cast +from typing import Any, Dict, Optional, Union, cast from typing_extensions import Literal, TYPE_CHECKING, override if TYPE_CHECKING: @@ -98,7 +98,7 @@ class V2CoreAccountIncludingConfigurationCustomerCapabilityStatusUpdatedEvent( class V2CoreAccountIncludingConfigurationCustomerCapabilityStatusUpdatedEventData( StripeObject, ): - updated_capability: Literal["automatic_indirect_tax"] + updated_capability: Union[Literal["automatic_indirect_tax"], str] """ Open Enum. The capability which had its status updated. """ diff --git a/stripe/financial_connections/_account.py b/stripe/financial_connections/_account.py index 8345cef82..56f7908c7 100644 --- a/stripe/financial_connections/_account.py +++ b/stripe/financial_connections/_account.py @@ -310,7 +310,7 @@ class TransactionRefresh(StripeObject): @classmethod def _cls_disconnect( - cls, account: str, **params: Unpack["AccountDisconnectParams"] + cls, account: str, /, **params: Unpack["AccountDisconnectParams"] ) -> "Account": """ Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions). @@ -329,7 +329,7 @@ def _cls_disconnect( @overload @staticmethod def disconnect( - account: str, **params: Unpack["AccountDisconnectParams"] + account: str, /, **params: Unpack["AccountDisconnectParams"] ) -> "Account": """ Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions). @@ -365,7 +365,7 @@ def disconnect( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_disconnect_async( - cls, account: str, **params: Unpack["AccountDisconnectParams"] + cls, account: str, /, **params: Unpack["AccountDisconnectParams"] ) -> "Account": """ Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions). @@ -384,7 +384,7 @@ async def _cls_disconnect_async( @overload @staticmethod async def disconnect_async( - account: str, **params: Unpack["AccountDisconnectParams"] + account: str, /, **params: Unpack["AccountDisconnectParams"] ) -> "Account": """ Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions). @@ -460,7 +460,7 @@ async def list_async( @classmethod def _cls_list_owners( - cls, account: str, **params: Unpack["AccountListOwnersParams"] + cls, account: str, /, **params: Unpack["AccountListOwnersParams"] ) -> ListObject["AccountOwner"]: """ Lists all owners for a given Account @@ -479,7 +479,7 @@ def _cls_list_owners( @overload @staticmethod def list_owners( - account: str, **params: Unpack["AccountListOwnersParams"] + account: str, /, **params: Unpack["AccountListOwnersParams"] ) -> ListObject["AccountOwner"]: """ Lists all owners for a given Account @@ -515,7 +515,7 @@ def list_owners( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_list_owners_async( - cls, account: str, **params: Unpack["AccountListOwnersParams"] + cls, account: str, /, **params: Unpack["AccountListOwnersParams"] ) -> ListObject["AccountOwner"]: """ Lists all owners for a given Account @@ -534,7 +534,7 @@ async def _cls_list_owners_async( @overload @staticmethod async def list_owners_async( - account: str, **params: Unpack["AccountListOwnersParams"] + account: str, /, **params: Unpack["AccountListOwnersParams"] ) -> ListObject["AccountOwner"]: """ Lists all owners for a given Account @@ -570,7 +570,7 @@ async def list_owners_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_refresh_account( - cls, account: str, **params: Unpack["AccountRefreshAccountParams"] + cls, account: str, /, **params: Unpack["AccountRefreshAccountParams"] ) -> "Account": """ Refreshes the data associated with a Financial Connections Account. @@ -589,7 +589,7 @@ def _cls_refresh_account( @overload @staticmethod def refresh_account( - account: str, **params: Unpack["AccountRefreshAccountParams"] + account: str, /, **params: Unpack["AccountRefreshAccountParams"] ) -> "Account": """ Refreshes the data associated with a Financial Connections Account. @@ -625,7 +625,7 @@ def refresh_account( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_refresh_account_async( - cls, account: str, **params: Unpack["AccountRefreshAccountParams"] + cls, account: str, /, **params: Unpack["AccountRefreshAccountParams"] ) -> "Account": """ Refreshes the data associated with a Financial Connections Account. @@ -644,7 +644,7 @@ async def _cls_refresh_account_async( @overload @staticmethod async def refresh_account_async( - account: str, **params: Unpack["AccountRefreshAccountParams"] + account: str, /, **params: Unpack["AccountRefreshAccountParams"] ) -> "Account": """ Refreshes the data associated with a Financial Connections Account. @@ -702,7 +702,7 @@ async def retrieve_async( @classmethod def _cls_subscribe( - cls, account: str, **params: Unpack["AccountSubscribeParams"] + cls, account: str, /, **params: Unpack["AccountSubscribeParams"] ) -> "Account": """ Subscribes to periodic refreshes of data associated with a Financial Connections Account. When the account status is active, data is typically refreshed once a day. @@ -721,7 +721,7 @@ def _cls_subscribe( @overload @staticmethod def subscribe( - account: str, **params: Unpack["AccountSubscribeParams"] + account: str, /, **params: Unpack["AccountSubscribeParams"] ) -> "Account": """ Subscribes to periodic refreshes of data associated with a Financial Connections Account. When the account status is active, data is typically refreshed once a day. @@ -757,7 +757,7 @@ def subscribe( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_subscribe_async( - cls, account: str, **params: Unpack["AccountSubscribeParams"] + cls, account: str, /, **params: Unpack["AccountSubscribeParams"] ) -> "Account": """ Subscribes to periodic refreshes of data associated with a Financial Connections Account. When the account status is active, data is typically refreshed once a day. @@ -776,7 +776,7 @@ async def _cls_subscribe_async( @overload @staticmethod async def subscribe_async( - account: str, **params: Unpack["AccountSubscribeParams"] + account: str, /, **params: Unpack["AccountSubscribeParams"] ) -> "Account": """ Subscribes to periodic refreshes of data associated with a Financial Connections Account. When the account status is active, data is typically refreshed once a day. @@ -812,7 +812,7 @@ async def subscribe_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_unsubscribe( - cls, account: str, **params: Unpack["AccountUnsubscribeParams"] + cls, account: str, /, **params: Unpack["AccountUnsubscribeParams"] ) -> "Account": """ Unsubscribes from periodic refreshes of data associated with a Financial Connections Account. @@ -831,7 +831,7 @@ def _cls_unsubscribe( @overload @staticmethod def unsubscribe( - account: str, **params: Unpack["AccountUnsubscribeParams"] + account: str, /, **params: Unpack["AccountUnsubscribeParams"] ) -> "Account": """ Unsubscribes from periodic refreshes of data associated with a Financial Connections Account. @@ -867,7 +867,7 @@ def unsubscribe( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_unsubscribe_async( - cls, account: str, **params: Unpack["AccountUnsubscribeParams"] + cls, account: str, /, **params: Unpack["AccountUnsubscribeParams"] ) -> "Account": """ Unsubscribes from periodic refreshes of data associated with a Financial Connections Account. @@ -886,7 +886,7 @@ async def _cls_unsubscribe_async( @overload @staticmethod async def unsubscribe_async( - account: str, **params: Unpack["AccountUnsubscribeParams"] + account: str, /, **params: Unpack["AccountUnsubscribeParams"] ) -> "Account": """ Unsubscribes from periodic refreshes of data associated with a Financial Connections Account. diff --git a/stripe/financial_connections/_account_owner_service.py b/stripe/financial_connections/_account_owner_service.py index fa2851260..382799eb7 100644 --- a/stripe/financial_connections/_account_owner_service.py +++ b/stripe/financial_connections/_account_owner_service.py @@ -18,6 +18,7 @@ class AccountOwnerService(StripeService): def list( self, account: str, + /, params: "AccountOwnerListParams", options: Optional["RequestOptions"] = None, ) -> "ListObject[AccountOwner]": @@ -40,6 +41,7 @@ def list( async def list_async( self, account: str, + /, params: "AccountOwnerListParams", options: Optional["RequestOptions"] = None, ) -> "ListObject[AccountOwner]": diff --git a/stripe/financial_connections/_account_service.py b/stripe/financial_connections/_account_service.py index a036dc406..9cbef84eb 100644 --- a/stripe/financial_connections/_account_service.py +++ b/stripe/financial_connections/_account_service.py @@ -103,6 +103,7 @@ async def list_async( def retrieve( self, account: str, + /, params: Optional["AccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, account: str, + /, params: Optional["AccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -147,6 +149,7 @@ async def retrieve_async( def disconnect( self, account: str, + /, params: Optional["AccountDisconnectParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -169,6 +172,7 @@ def disconnect( async def disconnect_async( self, account: str, + /, params: Optional["AccountDisconnectParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -191,6 +195,7 @@ async def disconnect_async( def refresh( self, account: str, + /, params: "AccountRefreshParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -213,6 +218,7 @@ def refresh( async def refresh_async( self, account: str, + /, params: "AccountRefreshParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -235,6 +241,7 @@ async def refresh_async( def subscribe( self, account: str, + /, params: "AccountSubscribeParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -257,6 +264,7 @@ def subscribe( async def subscribe_async( self, account: str, + /, params: "AccountSubscribeParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -279,6 +287,7 @@ async def subscribe_async( def unsubscribe( self, account: str, + /, params: "AccountUnsubscribeParams", options: Optional["RequestOptions"] = None, ) -> "Account": @@ -301,6 +310,7 @@ def unsubscribe( async def unsubscribe_async( self, account: str, + /, params: "AccountUnsubscribeParams", options: Optional["RequestOptions"] = None, ) -> "Account": diff --git a/stripe/financial_connections/_session_service.py b/stripe/financial_connections/_session_service.py index ca7477e04..d288cebaf 100644 --- a/stripe/financial_connections/_session_service.py +++ b/stripe/financial_connections/_session_service.py @@ -20,6 +20,7 @@ class SessionService(StripeService): def retrieve( self, session: str, + /, params: Optional["SessionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": @@ -42,6 +43,7 @@ def retrieve( async def retrieve_async( self, session: str, + /, params: Optional["SessionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Session": diff --git a/stripe/financial_connections/_transaction_service.py b/stripe/financial_connections/_transaction_service.py index bf33c3b6f..c98ba8413 100644 --- a/stripe/financial_connections/_transaction_service.py +++ b/stripe/financial_connections/_transaction_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, transaction: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, transaction: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": diff --git a/stripe/forwarding/_request_service.py b/stripe/forwarding/_request_service.py index b52e6a3af..a1e894a3a 100644 --- a/stripe/forwarding/_request_service.py +++ b/stripe/forwarding/_request_service.py @@ -98,6 +98,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["RequestRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Request": @@ -118,6 +119,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["RequestRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Request": diff --git a/stripe/identity/_verification_report_service.py b/stripe/identity/_verification_report_service.py index 65b8b1631..6c44e40d2 100644 --- a/stripe/identity/_verification_report_service.py +++ b/stripe/identity/_verification_report_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, report: str, + /, params: Optional["VerificationReportRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationReport": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, report: str, + /, params: Optional["VerificationReportRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationReport": diff --git a/stripe/identity/_verification_session.py b/stripe/identity/_verification_session.py index acb8c2fde..a06a48508 100644 --- a/stripe/identity/_verification_session.py +++ b/stripe/identity/_verification_session.py @@ -352,7 +352,10 @@ class Dob(StripeObject): @classmethod def _cls_cancel( - cls, session: str, **params: Unpack["VerificationSessionCancelParams"] + cls, + session: str, + /, + **params: Unpack["VerificationSessionCancelParams"], ) -> "VerificationSession": """ A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work). @@ -373,7 +376,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - session: str, **params: Unpack["VerificationSessionCancelParams"] + session: str, /, **params: Unpack["VerificationSessionCancelParams"] ) -> "VerificationSession": """ A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work). @@ -415,7 +418,10 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, session: str, **params: Unpack["VerificationSessionCancelParams"] + cls, + session: str, + /, + **params: Unpack["VerificationSessionCancelParams"], ) -> "VerificationSession": """ A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work). @@ -436,7 +442,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - session: str, **params: Unpack["VerificationSessionCancelParams"] + session: str, /, **params: Unpack["VerificationSessionCancelParams"] ) -> "VerificationSession": """ A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work). @@ -602,7 +608,10 @@ async def modify_async( @classmethod def _cls_redact( - cls, session: str, **params: Unpack["VerificationSessionRedactParams"] + cls, + session: str, + /, + **params: Unpack["VerificationSessionRedactParams"], ) -> "VerificationSession": """ Redact a VerificationSession to remove all collected information from Stripe. This will redact @@ -639,7 +648,7 @@ def _cls_redact( @overload @staticmethod def redact( - session: str, **params: Unpack["VerificationSessionRedactParams"] + session: str, /, **params: Unpack["VerificationSessionRedactParams"] ) -> "VerificationSession": """ Redact a VerificationSession to remove all collected information from Stripe. This will redact @@ -729,7 +738,10 @@ def redact( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_redact_async( - cls, session: str, **params: Unpack["VerificationSessionRedactParams"] + cls, + session: str, + /, + **params: Unpack["VerificationSessionRedactParams"], ) -> "VerificationSession": """ Redact a VerificationSession to remove all collected information from Stripe. This will redact @@ -766,7 +778,7 @@ async def _cls_redact_async( @overload @staticmethod async def redact_async( - session: str, **params: Unpack["VerificationSessionRedactParams"] + session: str, /, **params: Unpack["VerificationSessionRedactParams"] ) -> "VerificationSession": """ Redact a VerificationSession to remove all collected information from Stripe. This will redact diff --git a/stripe/identity/_verification_session_service.py b/stripe/identity/_verification_session_service.py index 69aace00f..78c0af60d 100644 --- a/stripe/identity/_verification_session_service.py +++ b/stripe/identity/_verification_session_service.py @@ -121,6 +121,7 @@ async def create_async( def retrieve( self, session: str, + /, params: Optional["VerificationSessionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -146,6 +147,7 @@ def retrieve( async def retrieve_async( self, session: str, + /, params: Optional["VerificationSessionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -171,6 +173,7 @@ async def retrieve_async( def update( self, session: str, + /, params: Optional["VerificationSessionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -196,6 +199,7 @@ def update( async def update_async( self, session: str, + /, params: Optional["VerificationSessionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -221,6 +225,7 @@ async def update_async( def cancel( self, session: str, + /, params: Optional["VerificationSessionCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -245,6 +250,7 @@ def cancel( async def cancel_async( self, session: str, + /, params: Optional["VerificationSessionCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -269,6 +275,7 @@ async def cancel_async( def redact( self, session: str, + /, params: Optional["VerificationSessionRedactParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": @@ -309,6 +316,7 @@ def redact( async def redact_async( self, session: str, + /, params: Optional["VerificationSessionRedactParams"] = None, options: Optional["RequestOptions"] = None, ) -> "VerificationSession": diff --git a/stripe/issuing/_authorization.py b/stripe/issuing/_authorization.py index 29f8d81cf..fef5f9f66 100644 --- a/stripe/issuing/_authorization.py +++ b/stripe/issuing/_authorization.py @@ -653,7 +653,10 @@ class ThreeDSecure(StripeObject): @classmethod def _cls_approve( - cls, authorization: str, **params: Unpack["AuthorizationApproveParams"] + cls, + authorization: str, + /, + **params: Unpack["AuthorizationApproveParams"], ) -> "Authorization": """ [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -673,7 +676,7 @@ def _cls_approve( @overload @staticmethod def approve( - authorization: str, **params: Unpack["AuthorizationApproveParams"] + authorization: str, /, **params: Unpack["AuthorizationApproveParams"] ) -> "Authorization": """ [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -712,7 +715,10 @@ def approve( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_approve_async( - cls, authorization: str, **params: Unpack["AuthorizationApproveParams"] + cls, + authorization: str, + /, + **params: Unpack["AuthorizationApproveParams"], ) -> "Authorization": """ [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -732,7 +738,7 @@ async def _cls_approve_async( @overload @staticmethod async def approve_async( - authorization: str, **params: Unpack["AuthorizationApproveParams"] + authorization: str, /, **params: Unpack["AuthorizationApproveParams"] ) -> "Authorization": """ [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -771,7 +777,10 @@ async def approve_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_decline( - cls, authorization: str, **params: Unpack["AuthorizationDeclineParams"] + cls, + authorization: str, + /, + **params: Unpack["AuthorizationDeclineParams"], ) -> "Authorization": """ [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -791,7 +800,7 @@ def _cls_decline( @overload @staticmethod def decline( - authorization: str, **params: Unpack["AuthorizationDeclineParams"] + authorization: str, /, **params: Unpack["AuthorizationDeclineParams"] ) -> "Authorization": """ [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -830,7 +839,10 @@ def decline( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_decline_async( - cls, authorization: str, **params: Unpack["AuthorizationDeclineParams"] + cls, + authorization: str, + /, + **params: Unpack["AuthorizationDeclineParams"], ) -> "Authorization": """ [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -850,7 +862,7 @@ async def _cls_decline_async( @overload @staticmethod async def decline_async( - authorization: str, **params: Unpack["AuthorizationDeclineParams"] + authorization: str, /, **params: Unpack["AuthorizationDeclineParams"] ) -> "Authorization": """ [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow. @@ -990,6 +1002,7 @@ class TestHelpers(APIResourceTestHelpers["Authorization"]): def _cls_capture( cls, authorization: str, + /, **params: Unpack["AuthorizationCaptureParams"], ) -> "Authorization": """ @@ -1009,7 +1022,9 @@ def _cls_capture( @overload @staticmethod def capture( - authorization: str, **params: Unpack["AuthorizationCaptureParams"] + authorization: str, + /, + **params: Unpack["AuthorizationCaptureParams"], ) -> "Authorization": """ Capture a test-mode authorization. @@ -1049,6 +1064,7 @@ def capture( # pyright: ignore[reportGeneralTypeIssues] async def _cls_capture_async( cls, authorization: str, + /, **params: Unpack["AuthorizationCaptureParams"], ) -> "Authorization": """ @@ -1068,7 +1084,9 @@ async def _cls_capture_async( @overload @staticmethod async def capture_async( - authorization: str, **params: Unpack["AuthorizationCaptureParams"] + authorization: str, + /, + **params: Unpack["AuthorizationCaptureParams"], ) -> "Authorization": """ Capture a test-mode authorization. @@ -1140,6 +1158,7 @@ async def create_async( def _cls_expire( cls, authorization: str, + /, **params: Unpack["AuthorizationExpireParams"], ) -> "Authorization": """ @@ -1159,7 +1178,9 @@ def _cls_expire( @overload @staticmethod def expire( - authorization: str, **params: Unpack["AuthorizationExpireParams"] + authorization: str, + /, + **params: Unpack["AuthorizationExpireParams"], ) -> "Authorization": """ Expire a test-mode Authorization. @@ -1199,6 +1220,7 @@ def expire( # pyright: ignore[reportGeneralTypeIssues] async def _cls_expire_async( cls, authorization: str, + /, **params: Unpack["AuthorizationExpireParams"], ) -> "Authorization": """ @@ -1218,7 +1240,9 @@ async def _cls_expire_async( @overload @staticmethod async def expire_async( - authorization: str, **params: Unpack["AuthorizationExpireParams"] + authorization: str, + /, + **params: Unpack["AuthorizationExpireParams"], ) -> "Authorization": """ Expire a test-mode Authorization. @@ -1258,6 +1282,7 @@ async def expire_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_finalize_amount( cls, authorization: str, + /, **params: Unpack["AuthorizationFinalizeAmountParams"], ) -> "Authorization": """ @@ -1278,6 +1303,7 @@ def _cls_finalize_amount( @staticmethod def finalize_amount( authorization: str, + /, **params: Unpack["AuthorizationFinalizeAmountParams"], ) -> "Authorization": """ @@ -1318,6 +1344,7 @@ def finalize_amount( # pyright: ignore[reportGeneralTypeIssues] async def _cls_finalize_amount_async( cls, authorization: str, + /, **params: Unpack["AuthorizationFinalizeAmountParams"], ) -> "Authorization": """ @@ -1338,6 +1365,7 @@ async def _cls_finalize_amount_async( @staticmethod async def finalize_amount_async( authorization: str, + /, **params: Unpack["AuthorizationFinalizeAmountParams"], ) -> "Authorization": """ @@ -1378,6 +1406,7 @@ async def finalize_amount_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_increment( cls, authorization: str, + /, **params: Unpack["AuthorizationIncrementParams"], ) -> "Authorization": """ @@ -1398,6 +1427,7 @@ def _cls_increment( @staticmethod def increment( authorization: str, + /, **params: Unpack["AuthorizationIncrementParams"], ) -> "Authorization": """ @@ -1438,6 +1468,7 @@ def increment( # pyright: ignore[reportGeneralTypeIssues] async def _cls_increment_async( cls, authorization: str, + /, **params: Unpack["AuthorizationIncrementParams"], ) -> "Authorization": """ @@ -1458,6 +1489,7 @@ async def _cls_increment_async( @staticmethod async def increment_async( authorization: str, + /, **params: Unpack["AuthorizationIncrementParams"], ) -> "Authorization": """ @@ -1498,6 +1530,7 @@ async def increment_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_respond( cls, authorization: str, + /, **params: Unpack["AuthorizationRespondParams"], ) -> "Authorization": """ @@ -1517,7 +1550,9 @@ def _cls_respond( @overload @staticmethod def respond( - authorization: str, **params: Unpack["AuthorizationRespondParams"] + authorization: str, + /, + **params: Unpack["AuthorizationRespondParams"], ) -> "Authorization": """ Respond to a fraud challenge on a testmode Issuing authorization, simulating either a confirmation of fraud or a correction of legitimacy. @@ -1557,6 +1592,7 @@ def respond( # pyright: ignore[reportGeneralTypeIssues] async def _cls_respond_async( cls, authorization: str, + /, **params: Unpack["AuthorizationRespondParams"], ) -> "Authorization": """ @@ -1576,7 +1612,9 @@ async def _cls_respond_async( @overload @staticmethod async def respond_async( - authorization: str, **params: Unpack["AuthorizationRespondParams"] + authorization: str, + /, + **params: Unpack["AuthorizationRespondParams"], ) -> "Authorization": """ Respond to a fraud challenge on a testmode Issuing authorization, simulating either a confirmation of fraud or a correction of legitimacy. @@ -1616,6 +1654,7 @@ async def respond_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_reverse( cls, authorization: str, + /, **params: Unpack["AuthorizationReverseParams"], ) -> "Authorization": """ @@ -1635,7 +1674,9 @@ def _cls_reverse( @overload @staticmethod def reverse( - authorization: str, **params: Unpack["AuthorizationReverseParams"] + authorization: str, + /, + **params: Unpack["AuthorizationReverseParams"], ) -> "Authorization": """ Reverse a test-mode Authorization. @@ -1675,6 +1716,7 @@ def reverse( # pyright: ignore[reportGeneralTypeIssues] async def _cls_reverse_async( cls, authorization: str, + /, **params: Unpack["AuthorizationReverseParams"], ) -> "Authorization": """ @@ -1694,7 +1736,9 @@ async def _cls_reverse_async( @overload @staticmethod async def reverse_async( - authorization: str, **params: Unpack["AuthorizationReverseParams"] + authorization: str, + /, + **params: Unpack["AuthorizationReverseParams"], ) -> "Authorization": """ Reverse a test-mode Authorization. diff --git a/stripe/issuing/_authorization_service.py b/stripe/issuing/_authorization_service.py index 0e2c82d56..afac45a81 100644 --- a/stripe/issuing/_authorization_service.py +++ b/stripe/issuing/_authorization_service.py @@ -68,6 +68,7 @@ async def list_async( def retrieve( self, authorization: str, + /, params: Optional["AuthorizationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -90,6 +91,7 @@ def retrieve( async def retrieve_async( self, authorization: str, + /, params: Optional["AuthorizationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -112,6 +114,7 @@ async def retrieve_async( def update( self, authorization: str, + /, params: Optional["AuthorizationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -134,6 +137,7 @@ def update( async def update_async( self, authorization: str, + /, params: Optional["AuthorizationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -156,6 +160,7 @@ async def update_async( def approve( self, authorization: str, + /, params: Optional["AuthorizationApproveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -179,6 +184,7 @@ def approve( async def approve_async( self, authorization: str, + /, params: Optional["AuthorizationApproveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -202,6 +208,7 @@ async def approve_async( def decline( self, authorization: str, + /, params: Optional["AuthorizationDeclineParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -225,6 +232,7 @@ def decline( async def decline_async( self, authorization: str, + /, params: Optional["AuthorizationDeclineParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": diff --git a/stripe/issuing/_card.py b/stripe/issuing/_card.py index a154dd85c..c77bf629e 100644 --- a/stripe/issuing/_card.py +++ b/stripe/issuing/_card.py @@ -1496,7 +1496,7 @@ class TestHelpers(APIResourceTestHelpers["Card"]): @classmethod def _cls_deliver_card( - cls, card: str, **params: Unpack["CardDeliverCardParams"] + cls, card: str, /, **params: Unpack["CardDeliverCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to delivered. @@ -1515,7 +1515,7 @@ def _cls_deliver_card( @overload @staticmethod def deliver_card( - card: str, **params: Unpack["CardDeliverCardParams"] + card: str, /, **params: Unpack["CardDeliverCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to delivered. @@ -1551,7 +1551,7 @@ def deliver_card( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_deliver_card_async( - cls, card: str, **params: Unpack["CardDeliverCardParams"] + cls, card: str, /, **params: Unpack["CardDeliverCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to delivered. @@ -1570,7 +1570,7 @@ async def _cls_deliver_card_async( @overload @staticmethod async def deliver_card_async( - card: str, **params: Unpack["CardDeliverCardParams"] + card: str, /, **params: Unpack["CardDeliverCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to delivered. @@ -1606,7 +1606,7 @@ async def deliver_card_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_fail_card( - cls, card: str, **params: Unpack["CardFailCardParams"] + cls, card: str, /, **params: Unpack["CardFailCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to failure. @@ -1625,7 +1625,7 @@ def _cls_fail_card( @overload @staticmethod def fail_card( - card: str, **params: Unpack["CardFailCardParams"] + card: str, /, **params: Unpack["CardFailCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to failure. @@ -1659,7 +1659,7 @@ def fail_card( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_fail_card_async( - cls, card: str, **params: Unpack["CardFailCardParams"] + cls, card: str, /, **params: Unpack["CardFailCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to failure. @@ -1678,7 +1678,7 @@ async def _cls_fail_card_async( @overload @staticmethod async def fail_card_async( - card: str, **params: Unpack["CardFailCardParams"] + card: str, /, **params: Unpack["CardFailCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to failure. @@ -1714,7 +1714,7 @@ async def fail_card_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_return_card( - cls, card: str, **params: Unpack["CardReturnCardParams"] + cls, card: str, /, **params: Unpack["CardReturnCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to returned. @@ -1733,7 +1733,7 @@ def _cls_return_card( @overload @staticmethod def return_card( - card: str, **params: Unpack["CardReturnCardParams"] + card: str, /, **params: Unpack["CardReturnCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to returned. @@ -1769,7 +1769,7 @@ def return_card( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_return_card_async( - cls, card: str, **params: Unpack["CardReturnCardParams"] + cls, card: str, /, **params: Unpack["CardReturnCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to returned. @@ -1788,7 +1788,7 @@ async def _cls_return_card_async( @overload @staticmethod async def return_card_async( - card: str, **params: Unpack["CardReturnCardParams"] + card: str, /, **params: Unpack["CardReturnCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to returned. @@ -1824,7 +1824,7 @@ async def return_card_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_ship_card( - cls, card: str, **params: Unpack["CardShipCardParams"] + cls, card: str, /, **params: Unpack["CardShipCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to shipped. @@ -1843,7 +1843,7 @@ def _cls_ship_card( @overload @staticmethod def ship_card( - card: str, **params: Unpack["CardShipCardParams"] + card: str, /, **params: Unpack["CardShipCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to shipped. @@ -1877,7 +1877,7 @@ def ship_card( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_ship_card_async( - cls, card: str, **params: Unpack["CardShipCardParams"] + cls, card: str, /, **params: Unpack["CardShipCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to shipped. @@ -1896,7 +1896,7 @@ async def _cls_ship_card_async( @overload @staticmethod async def ship_card_async( - card: str, **params: Unpack["CardShipCardParams"] + card: str, /, **params: Unpack["CardShipCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to shipped. @@ -1932,7 +1932,7 @@ async def ship_card_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_submit_card( - cls, card: str, **params: Unpack["CardSubmitCardParams"] + cls, card: str, /, **params: Unpack["CardSubmitCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to submitted. This method requires Stripe Version ‘2024-09-30.acacia' or later. @@ -1951,7 +1951,7 @@ def _cls_submit_card( @overload @staticmethod def submit_card( - card: str, **params: Unpack["CardSubmitCardParams"] + card: str, /, **params: Unpack["CardSubmitCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to submitted. This method requires Stripe Version ‘2024-09-30.acacia' or later. @@ -1987,7 +1987,7 @@ def submit_card( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_submit_card_async( - cls, card: str, **params: Unpack["CardSubmitCardParams"] + cls, card: str, /, **params: Unpack["CardSubmitCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to submitted. This method requires Stripe Version ‘2024-09-30.acacia' or later. @@ -2006,7 +2006,7 @@ async def _cls_submit_card_async( @overload @staticmethod async def submit_card_async( - card: str, **params: Unpack["CardSubmitCardParams"] + card: str, /, **params: Unpack["CardSubmitCardParams"] ) -> "Card": """ Updates the shipping status of the specified Issuing Card object to submitted. This method requires Stripe Version ‘2024-09-30.acacia' or later. diff --git a/stripe/issuing/_card_service.py b/stripe/issuing/_card_service.py index 215290129..e00a25512 100644 --- a/stripe/issuing/_card_service.py +++ b/stripe/issuing/_card_service.py @@ -95,6 +95,7 @@ async def create_async( def retrieve( self, card: str, + /, params: Optional["CardRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -115,6 +116,7 @@ def retrieve( async def retrieve_async( self, card: str, + /, params: Optional["CardRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -135,6 +137,7 @@ async def retrieve_async( def update( self, card: str, + /, params: Optional["CardUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -155,6 +158,7 @@ def update( async def update_async( self, card: str, + /, params: Optional["CardUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": diff --git a/stripe/issuing/_cardholder_service.py b/stripe/issuing/_cardholder_service.py index 54affd264..8e9f98933 100644 --- a/stripe/issuing/_cardholder_service.py +++ b/stripe/issuing/_cardholder_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, cardholder: str, + /, params: Optional["CardholderRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Cardholder": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, cardholder: str, + /, params: Optional["CardholderRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Cardholder": @@ -147,6 +149,7 @@ async def retrieve_async( def update( self, cardholder: str, + /, params: Optional["CardholderUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Cardholder": @@ -169,6 +172,7 @@ def update( async def update_async( self, cardholder: str, + /, params: Optional["CardholderUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Cardholder": diff --git a/stripe/issuing/_dispute.py b/stripe/issuing/_dispute.py index d2fc04ff4..b76d48d7b 100644 --- a/stripe/issuing/_dispute.py +++ b/stripe/issuing/_dispute.py @@ -480,7 +480,7 @@ async def retrieve_async( @classmethod def _cls_submit( - cls, dispute: str, **params: Unpack["DisputeSubmitParams"] + cls, dispute: str, /, **params: Unpack["DisputeSubmitParams"] ) -> "Dispute": """ Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence). @@ -499,7 +499,7 @@ def _cls_submit( @overload @staticmethod def submit( - dispute: str, **params: Unpack["DisputeSubmitParams"] + dispute: str, /, **params: Unpack["DisputeSubmitParams"] ) -> "Dispute": """ Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence). @@ -533,7 +533,7 @@ def submit( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_submit_async( - cls, dispute: str, **params: Unpack["DisputeSubmitParams"] + cls, dispute: str, /, **params: Unpack["DisputeSubmitParams"] ) -> "Dispute": """ Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence). @@ -552,7 +552,7 @@ async def _cls_submit_async( @overload @staticmethod async def submit_async( - dispute: str, **params: Unpack["DisputeSubmitParams"] + dispute: str, /, **params: Unpack["DisputeSubmitParams"] ) -> "Dispute": """ Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence). diff --git a/stripe/issuing/_dispute_service.py b/stripe/issuing/_dispute_service.py index 2631bd197..498cd7415 100644 --- a/stripe/issuing/_dispute_service.py +++ b/stripe/issuing/_dispute_service.py @@ -104,6 +104,7 @@ async def create_async( def retrieve( self, dispute: str, + /, params: Optional["DisputeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -126,6 +127,7 @@ def retrieve( async def retrieve_async( self, dispute: str, + /, params: Optional["DisputeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -148,6 +150,7 @@ async def retrieve_async( def update( self, dispute: str, + /, params: Optional["DisputeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -170,6 +173,7 @@ def update( async def update_async( self, dispute: str, + /, params: Optional["DisputeUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -192,6 +196,7 @@ async def update_async( def submit( self, dispute: str, + /, params: Optional["DisputeSubmitParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": @@ -214,6 +219,7 @@ def submit( async def submit_async( self, dispute: str, + /, params: Optional["DisputeSubmitParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Dispute": diff --git a/stripe/issuing/_personalization_design.py b/stripe/issuing/_personalization_design.py index cc45c428a..1b82b1246 100644 --- a/stripe/issuing/_personalization_design.py +++ b/stripe/issuing/_personalization_design.py @@ -301,6 +301,7 @@ class TestHelpers(APIResourceTestHelpers["PersonalizationDesign"]): def _cls_activate( cls, personalization_design: str, + /, **params: Unpack["PersonalizationDesignActivateParams"], ) -> "PersonalizationDesign": """ @@ -323,6 +324,7 @@ def _cls_activate( @staticmethod def activate( personalization_design: str, + /, **params: Unpack["PersonalizationDesignActivateParams"], ) -> "PersonalizationDesign": """ @@ -363,6 +365,7 @@ def activate( # pyright: ignore[reportGeneralTypeIssues] async def _cls_activate_async( cls, personalization_design: str, + /, **params: Unpack["PersonalizationDesignActivateParams"], ) -> "PersonalizationDesign": """ @@ -385,6 +388,7 @@ async def _cls_activate_async( @staticmethod async def activate_async( personalization_design: str, + /, **params: Unpack["PersonalizationDesignActivateParams"], ) -> "PersonalizationDesign": """ @@ -425,6 +429,7 @@ async def activate_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_deactivate( cls, personalization_design: str, + /, **params: Unpack["PersonalizationDesignDeactivateParams"], ) -> "PersonalizationDesign": """ @@ -447,6 +452,7 @@ def _cls_deactivate( @staticmethod def deactivate( personalization_design: str, + /, **params: Unpack["PersonalizationDesignDeactivateParams"], ) -> "PersonalizationDesign": """ @@ -487,6 +493,7 @@ def deactivate( # pyright: ignore[reportGeneralTypeIssues] async def _cls_deactivate_async( cls, personalization_design: str, + /, **params: Unpack["PersonalizationDesignDeactivateParams"], ) -> "PersonalizationDesign": """ @@ -509,6 +516,7 @@ async def _cls_deactivate_async( @staticmethod async def deactivate_async( personalization_design: str, + /, **params: Unpack["PersonalizationDesignDeactivateParams"], ) -> "PersonalizationDesign": """ @@ -549,6 +557,7 @@ async def deactivate_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_reject( cls, personalization_design: str, + /, **params: Unpack["PersonalizationDesignRejectParams"], ) -> "PersonalizationDesign": """ @@ -571,6 +580,7 @@ def _cls_reject( @staticmethod def reject( personalization_design: str, + /, **params: Unpack["PersonalizationDesignRejectParams"], ) -> "PersonalizationDesign": """ @@ -611,6 +621,7 @@ def reject( # pyright: ignore[reportGeneralTypeIssues] async def _cls_reject_async( cls, personalization_design: str, + /, **params: Unpack["PersonalizationDesignRejectParams"], ) -> "PersonalizationDesign": """ @@ -633,6 +644,7 @@ async def _cls_reject_async( @staticmethod async def reject_async( personalization_design: str, + /, **params: Unpack["PersonalizationDesignRejectParams"], ) -> "PersonalizationDesign": """ diff --git a/stripe/issuing/_personalization_design_service.py b/stripe/issuing/_personalization_design_service.py index 0738bf406..285b11c59 100644 --- a/stripe/issuing/_personalization_design_service.py +++ b/stripe/issuing/_personalization_design_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, personalization_design: str, + /, params: Optional["PersonalizationDesignRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, personalization_design: str, + /, params: Optional["PersonalizationDesignRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -147,6 +149,7 @@ async def retrieve_async( def update( self, personalization_design: str, + /, params: Optional["PersonalizationDesignUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -169,6 +172,7 @@ def update( async def update_async( self, personalization_design: str, + /, params: Optional["PersonalizationDesignUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": diff --git a/stripe/issuing/_physical_bundle_service.py b/stripe/issuing/_physical_bundle_service.py index d3cba2006..3b338da3e 100644 --- a/stripe/issuing/_physical_bundle_service.py +++ b/stripe/issuing/_physical_bundle_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, physical_bundle: str, + /, params: Optional["PhysicalBundleRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PhysicalBundle": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, physical_bundle: str, + /, params: Optional["PhysicalBundleRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PhysicalBundle": diff --git a/stripe/issuing/_token_service.py b/stripe/issuing/_token_service.py index 8146af5c3..d78a54920 100644 --- a/stripe/issuing/_token_service.py +++ b/stripe/issuing/_token_service.py @@ -58,6 +58,7 @@ async def list_async( def retrieve( self, token: str, + /, params: Optional["TokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Token": @@ -78,6 +79,7 @@ def retrieve( async def retrieve_async( self, token: str, + /, params: Optional["TokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Token": @@ -98,6 +100,7 @@ async def retrieve_async( def update( self, token: str, + /, params: "TokenUpdateParams", options: Optional["RequestOptions"] = None, ) -> "Token": @@ -118,6 +121,7 @@ def update( async def update_async( self, token: str, + /, params: "TokenUpdateParams", options: Optional["RequestOptions"] = None, ) -> "Token": diff --git a/stripe/issuing/_transaction.py b/stripe/issuing/_transaction.py index f1a850317..52afb4a37 100644 --- a/stripe/issuing/_transaction.py +++ b/stripe/issuing/_transaction.py @@ -618,7 +618,10 @@ async def create_unlinked_refund_async( @classmethod def _cls_refund( - cls, transaction: str, **params: Unpack["TransactionRefundParams"] + cls, + transaction: str, + /, + **params: Unpack["TransactionRefundParams"], ) -> "Transaction": """ Refund a test-mode Transaction. @@ -637,7 +640,7 @@ def _cls_refund( @overload @staticmethod def refund( - transaction: str, **params: Unpack["TransactionRefundParams"] + transaction: str, /, **params: Unpack["TransactionRefundParams"] ) -> "Transaction": """ Refund a test-mode Transaction. @@ -673,7 +676,10 @@ def refund( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_refund_async( - cls, transaction: str, **params: Unpack["TransactionRefundParams"] + cls, + transaction: str, + /, + **params: Unpack["TransactionRefundParams"], ) -> "Transaction": """ Refund a test-mode Transaction. @@ -692,7 +698,7 @@ async def _cls_refund_async( @overload @staticmethod async def refund_async( - transaction: str, **params: Unpack["TransactionRefundParams"] + transaction: str, /, **params: Unpack["TransactionRefundParams"] ) -> "Transaction": """ Refund a test-mode Transaction. diff --git a/stripe/issuing/_transaction_service.py b/stripe/issuing/_transaction_service.py index 8c888266c..33e35d5a6 100644 --- a/stripe/issuing/_transaction_service.py +++ b/stripe/issuing/_transaction_service.py @@ -62,6 +62,7 @@ async def list_async( def retrieve( self, transaction: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -84,6 +85,7 @@ def retrieve( async def retrieve_async( self, transaction: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -106,6 +108,7 @@ async def retrieve_async( def update( self, transaction: str, + /, params: Optional["TransactionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -128,6 +131,7 @@ def update( async def update_async( self, transaction: str, + /, params: Optional["TransactionUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": diff --git a/stripe/params/_payment_intent_confirm_params.py b/stripe/params/_payment_intent_confirm_params.py index 34ad18d3a..205d04608 100644 --- a/stripe/params/_payment_intent_confirm_params.py +++ b/stripe/params/_payment_intent_confirm_params.py @@ -3365,7 +3365,7 @@ class PaymentIntentConfirmParamsPaymentMethodOptionsWechatPay(TypedDict): """ The client type that the end customer will pay from """ - setup_future_usage: NotRequired[Literal["none"]] + setup_future_usage: NotRequired["Literal['none']|str"] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. diff --git a/stripe/params/_payment_intent_create_params.py b/stripe/params/_payment_intent_create_params.py index 551cc20aa..d01c33822 100644 --- a/stripe/params/_payment_intent_create_params.py +++ b/stripe/params/_payment_intent_create_params.py @@ -3494,7 +3494,7 @@ class PaymentIntentCreateParamsPaymentMethodOptionsWechatPay(TypedDict): """ The client type that the end customer will pay from """ - setup_future_usage: NotRequired[Literal["none"]] + setup_future_usage: NotRequired["Literal['none']|str"] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. diff --git a/stripe/params/_payment_intent_modify_params.py b/stripe/params/_payment_intent_modify_params.py index a245fb194..c9e793236 100644 --- a/stripe/params/_payment_intent_modify_params.py +++ b/stripe/params/_payment_intent_modify_params.py @@ -3326,7 +3326,7 @@ class PaymentIntentModifyParamsPaymentMethodOptionsWechatPay(TypedDict): """ The client type that the end customer will pay from """ - setup_future_usage: NotRequired[Literal["none"]] + setup_future_usage: NotRequired["Literal['none']|str"] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. diff --git a/stripe/params/_payment_intent_update_params.py b/stripe/params/_payment_intent_update_params.py index cd3c5cf6e..ee8e3693d 100644 --- a/stripe/params/_payment_intent_update_params.py +++ b/stripe/params/_payment_intent_update_params.py @@ -3325,7 +3325,7 @@ class PaymentIntentUpdateParamsPaymentMethodOptionsWechatPay(TypedDict): """ The client type that the end customer will pay from """ - setup_future_usage: NotRequired[Literal["none"]] + setup_future_usage: NotRequired["Literal['none']|str"] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. diff --git a/stripe/params/checkout/_session_create_params.py b/stripe/params/checkout/_session_create_params.py index bb1904127..1d54e48f7 100644 --- a/stripe/params/checkout/_session_create_params.py +++ b/stripe/params/checkout/_session_create_params.py @@ -1477,7 +1477,7 @@ class SessionCreateParamsPaymentMethodOptionsAfterpayClearpay(TypedDict): class SessionCreateParamsPaymentMethodOptionsAlipay(TypedDict): - setup_future_usage: NotRequired[Literal["none"]] + setup_future_usage: NotRequired["Literal['none']|str"] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. @@ -2508,7 +2508,7 @@ class SessionCreateParamsPaymentMethodOptionsWechatPay(TypedDict): """ The client type that the end customer will pay from """ - setup_future_usage: NotRequired[Literal["none"]] + setup_future_usage: NotRequired["Literal['none']|str"] """ Indicates that you intend to make future payments with this PaymentIntent's payment method. diff --git a/stripe/params/tax/_registration_create_params.py b/stripe/params/tax/_registration_create_params.py index 54501d240..aaee80a77 100644 --- a/stripe/params/tax/_registration_create_params.py +++ b/stripe/params/tax/_registration_create_params.py @@ -2060,7 +2060,7 @@ class RegistrationCreateParamsCountryOptionsSrStandard(TypedDict): class RegistrationCreateParamsCountryOptionsTh(TypedDict): - type: Literal["simplified"] + type: Union[Literal["simplified"], str] """ Type of registration to be created in `country`. """ diff --git a/stripe/params/v2/billing/_meter_event_adjustment_create_params.py b/stripe/params/v2/billing/_meter_event_adjustment_create_params.py index b39cc81f2..2de4e99d4 100644 --- a/stripe/params/v2/billing/_meter_event_adjustment_create_params.py +++ b/stripe/params/v2/billing/_meter_event_adjustment_create_params.py @@ -1,5 +1,6 @@ # -*- coding: utf-8 -*- # File generated from our OpenAPI spec +from typing import Union from typing_extensions import Literal, TypedDict @@ -12,7 +13,7 @@ class MeterEventAdjustmentCreateParams(TypedDict): """ The name of the meter event. Corresponds with the `event_name` field on a meter. """ - type: Literal["cancel"] + type: Union[Literal["cancel"], str] """ Specifies the type of cancellation. Currently supports canceling a single event. """ diff --git a/stripe/params/v2/core/_account_create_params.py b/stripe/params/v2/core/_account_create_params.py index 2b3a9ed70..e15f9ad42 100644 --- a/stripe/params/v2/core/_account_create_params.py +++ b/stripe/params/v2/core/_account_create_params.py @@ -1719,7 +1719,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsBankAccountOwnershipVer """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1732,7 +1732,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsCompanyLicense( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1745,7 +1745,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsCompanyMemorandumOfAsso """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1758,7 +1758,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsCompanyMinisterialDecre """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1771,7 +1771,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsCompanyRegistrationVeri """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1784,7 +1784,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsCompanyTaxIdVerificatio """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1797,7 +1797,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsPrimaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -1823,7 +1823,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsProofOfAddress( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1842,7 +1842,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsProofOfRegistration( """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1870,7 +1870,7 @@ class AccountCreateParamsIdentityBusinessDetailsDocumentsProofOfUltimateBenefici """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2374,7 +2374,7 @@ class AccountCreateParamsIdentityIndividualDocumentsCompanyAuthorization( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2385,7 +2385,7 @@ class AccountCreateParamsIdentityIndividualDocumentsPassport(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2398,7 +2398,7 @@ class AccountCreateParamsIdentityIndividualDocumentsPrimaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -2424,7 +2424,7 @@ class AccountCreateParamsIdentityIndividualDocumentsSecondaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -2448,7 +2448,7 @@ class AccountCreateParamsIdentityIndividualDocumentsVisa(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/params/v2/core/_account_token_create_params.py b/stripe/params/v2/core/_account_token_create_params.py index 35b792af6..b7fc2b86c 100644 --- a/stripe/params/v2/core/_account_token_create_params.py +++ b/stripe/params/v2/core/_account_token_create_params.py @@ -377,7 +377,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsBankAccountOwnersh """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -390,7 +390,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsCompanyLicense( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -403,7 +403,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsCompanyMemorandumO """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -416,7 +416,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsCompanyMinisterial """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -429,7 +429,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsCompanyRegistratio """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -442,7 +442,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsCompanyTaxIdVerifi """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -455,7 +455,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsPrimaryVerificatio """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -481,7 +481,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsProofOfAddress( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -500,7 +500,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsProofOfRegistratio """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -528,7 +528,7 @@ class AccountTokenCreateParamsIdentityBusinessDetailsDocumentsProofOfUltimateBen """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1048,7 +1048,7 @@ class AccountTokenCreateParamsIdentityIndividualDocumentsCompanyAuthorization( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1059,7 +1059,7 @@ class AccountTokenCreateParamsIdentityIndividualDocumentsPassport(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1072,7 +1072,7 @@ class AccountTokenCreateParamsIdentityIndividualDocumentsPrimaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -1098,7 +1098,7 @@ class AccountTokenCreateParamsIdentityIndividualDocumentsSecondaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -1122,7 +1122,7 @@ class AccountTokenCreateParamsIdentityIndividualDocumentsVisa(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/params/v2/core/_account_update_params.py b/stripe/params/v2/core/_account_update_params.py index 7d0c4b91e..81d7c8dc6 100644 --- a/stripe/params/v2/core/_account_update_params.py +++ b/stripe/params/v2/core/_account_update_params.py @@ -1787,7 +1787,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsBankAccountOwnershipVer """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1800,7 +1800,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsCompanyLicense( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1813,7 +1813,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsCompanyMemorandumOfAsso """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1826,7 +1826,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsCompanyMinisterialDecre """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1839,7 +1839,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsCompanyRegistrationVeri """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1852,7 +1852,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsCompanyTaxIdVerificatio """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1865,7 +1865,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsPrimaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -1891,7 +1891,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsProofOfAddress( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1910,7 +1910,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsProofOfRegistration( """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -1938,7 +1938,7 @@ class AccountUpdateParamsIdentityBusinessDetailsDocumentsProofOfUltimateBenefici """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2444,7 +2444,7 @@ class AccountUpdateParamsIdentityIndividualDocumentsCompanyAuthorization( """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2455,7 +2455,7 @@ class AccountUpdateParamsIdentityIndividualDocumentsPassport(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2468,7 +2468,7 @@ class AccountUpdateParamsIdentityIndividualDocumentsPrimaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -2494,7 +2494,7 @@ class AccountUpdateParamsIdentityIndividualDocumentsSecondaryVerification( """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -2518,7 +2518,7 @@ class AccountUpdateParamsIdentityIndividualDocumentsVisa(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/params/v2/core/_event_destination_list_params.py b/stripe/params/v2/core/_event_destination_list_params.py index c0320468a..d0cd324a3 100644 --- a/stripe/params/v2/core/_event_destination_list_params.py +++ b/stripe/params/v2/core/_event_destination_list_params.py @@ -1,11 +1,11 @@ # -*- coding: utf-8 -*- # File generated from our OpenAPI spec -from typing import List +from typing import List, Union from typing_extensions import Literal, NotRequired, TypedDict class EventDestinationListParams(TypedDict): - include: NotRequired[List[Literal["webhook_endpoint.url"]]] + include: NotRequired[List[Union[Literal["webhook_endpoint.url"], str]]] """ Additional fields to include in the response. Currently supports `webhook_endpoint.url`. """ diff --git a/stripe/params/v2/core/_event_destination_retrieve_params.py b/stripe/params/v2/core/_event_destination_retrieve_params.py index d43606b1d..ad0200416 100644 --- a/stripe/params/v2/core/_event_destination_retrieve_params.py +++ b/stripe/params/v2/core/_event_destination_retrieve_params.py @@ -1,11 +1,11 @@ # -*- coding: utf-8 -*- # File generated from our OpenAPI spec -from typing import List +from typing import List, Union from typing_extensions import Literal, NotRequired, TypedDict class EventDestinationRetrieveParams(TypedDict): - include: NotRequired[List[Literal["webhook_endpoint.url"]]] + include: NotRequired[List[Union[Literal["webhook_endpoint.url"], str]]] """ Additional fields to include in the response. """ diff --git a/stripe/params/v2/core/_event_destination_update_params.py b/stripe/params/v2/core/_event_destination_update_params.py index bc0feb0b8..b9b59ba83 100644 --- a/stripe/params/v2/core/_event_destination_update_params.py +++ b/stripe/params/v2/core/_event_destination_update_params.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # File generated from our OpenAPI spec from stripe._stripe_object import UntypedStripeObject -from typing import Dict, List, Optional +from typing import Dict, List, Optional, Union from typing_extensions import Literal, NotRequired, TypedDict @@ -14,7 +14,7 @@ class EventDestinationUpdateParams(TypedDict): """ The list of events to enable for this endpoint. """ - include: NotRequired[List[Literal["webhook_endpoint.url"]]] + include: NotRequired[List[Union[Literal["webhook_endpoint.url"], str]]] """ Additional fields to include in the response. Currently supports `webhook_endpoint.url`. """ diff --git a/stripe/params/v2/core/accounts/_person_create_params.py b/stripe/params/v2/core/accounts/_person_create_params.py index 4e7b02531..74e36cf35 100644 --- a/stripe/params/v2/core/accounts/_person_create_params.py +++ b/stripe/params/v2/core/accounts/_person_create_params.py @@ -245,7 +245,7 @@ class PersonCreateParamsDocumentsCompanyAuthorization(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -256,7 +256,7 @@ class PersonCreateParamsDocumentsPassport(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -267,7 +267,7 @@ class PersonCreateParamsDocumentsPrimaryVerification(TypedDict): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -289,7 +289,7 @@ class PersonCreateParamsDocumentsSecondaryVerification(TypedDict): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -311,7 +311,7 @@ class PersonCreateParamsDocumentsVisa(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/params/v2/core/accounts/_person_token_create_params.py b/stripe/params/v2/core/accounts/_person_token_create_params.py index 15a321f83..3b1b8fc23 100644 --- a/stripe/params/v2/core/accounts/_person_token_create_params.py +++ b/stripe/params/v2/core/accounts/_person_token_create_params.py @@ -239,7 +239,7 @@ class PersonTokenCreateParamsDocumentsCompanyAuthorization(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -250,7 +250,7 @@ class PersonTokenCreateParamsDocumentsPassport(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -261,7 +261,7 @@ class PersonTokenCreateParamsDocumentsPrimaryVerification(TypedDict): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -285,7 +285,7 @@ class PersonTokenCreateParamsDocumentsSecondaryVerification(TypedDict): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -309,7 +309,7 @@ class PersonTokenCreateParamsDocumentsVisa(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/params/v2/core/accounts/_person_update_params.py b/stripe/params/v2/core/accounts/_person_update_params.py index ed45a4816..2318e45f2 100644 --- a/stripe/params/v2/core/accounts/_person_update_params.py +++ b/stripe/params/v2/core/accounts/_person_update_params.py @@ -247,7 +247,7 @@ class PersonUpdateParamsDocumentsCompanyAuthorization(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -258,7 +258,7 @@ class PersonUpdateParamsDocumentsPassport(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -269,7 +269,7 @@ class PersonUpdateParamsDocumentsPrimaryVerification(TypedDict): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -291,7 +291,7 @@ class PersonUpdateParamsDocumentsSecondaryVerification(TypedDict): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -313,7 +313,7 @@ class PersonUpdateParamsDocumentsVisa(TypedDict): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/radar/_early_fraud_warning_service.py b/stripe/radar/_early_fraud_warning_service.py index b5f909c04..6e97dbb48 100644 --- a/stripe/radar/_early_fraud_warning_service.py +++ b/stripe/radar/_early_fraud_warning_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, early_fraud_warning: str, + /, params: Optional["EarlyFraudWarningRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EarlyFraudWarning": @@ -83,6 +84,7 @@ def retrieve( async def retrieve_async( self, early_fraud_warning: str, + /, params: Optional["EarlyFraudWarningRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EarlyFraudWarning": diff --git a/stripe/radar/_value_list_item_service.py b/stripe/radar/_value_list_item_service.py index 306372726..4f79962d3 100644 --- a/stripe/radar/_value_list_item_service.py +++ b/stripe/radar/_value_list_item_service.py @@ -27,6 +27,7 @@ class ValueListItemService(StripeService): def delete( self, item: str, + /, params: Optional["ValueListItemDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueListItem": @@ -49,6 +50,7 @@ def delete( async def delete_async( self, item: str, + /, params: Optional["ValueListItemDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueListItem": @@ -71,6 +73,7 @@ async def delete_async( def retrieve( self, item: str, + /, params: Optional["ValueListItemRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueListItem": @@ -93,6 +96,7 @@ def retrieve( async def retrieve_async( self, item: str, + /, params: Optional["ValueListItemRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueListItem": diff --git a/stripe/radar/_value_list_service.py b/stripe/radar/_value_list_service.py index 637cb2cad..57b48cf56 100644 --- a/stripe/radar/_value_list_service.py +++ b/stripe/radar/_value_list_service.py @@ -28,6 +28,7 @@ class ValueListService(StripeService): def delete( self, value_list: str, + /, params: Optional["ValueListDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueList": @@ -50,6 +51,7 @@ def delete( async def delete_async( self, value_list: str, + /, params: Optional["ValueListDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueList": @@ -72,6 +74,7 @@ async def delete_async( def retrieve( self, value_list: str, + /, params: Optional["ValueListRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueList": @@ -94,6 +97,7 @@ def retrieve( async def retrieve_async( self, value_list: str, + /, params: Optional["ValueListRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueList": @@ -116,6 +120,7 @@ async def retrieve_async( def update( self, value_list: str, + /, params: Optional["ValueListUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueList": @@ -138,6 +143,7 @@ def update( async def update_async( self, value_list: str, + /, params: Optional["ValueListUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ValueList": diff --git a/stripe/reporting/_report_run_service.py b/stripe/reporting/_report_run_service.py index 40ab869b4..c16b8ee78 100644 --- a/stripe/reporting/_report_run_service.py +++ b/stripe/reporting/_report_run_service.py @@ -100,6 +100,7 @@ async def create_async( def retrieve( self, report_run: str, + /, params: Optional["ReportRunRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReportRun": @@ -122,6 +123,7 @@ def retrieve( async def retrieve_async( self, report_run: str, + /, params: Optional["ReportRunRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReportRun": diff --git a/stripe/reporting/_report_type_service.py b/stripe/reporting/_report_type_service.py index d3d93e13f..fc1f71717 100644 --- a/stripe/reporting/_report_type_service.py +++ b/stripe/reporting/_report_type_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, report_type: str, + /, params: Optional["ReportTypeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReportType": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, report_type: str, + /, params: Optional["ReportTypeRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReportType": diff --git a/stripe/sigma/_scheduled_query_run_service.py b/stripe/sigma/_scheduled_query_run_service.py index 33d81725e..77196be6a 100644 --- a/stripe/sigma/_scheduled_query_run_service.py +++ b/stripe/sigma/_scheduled_query_run_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, scheduled_query_run: str, + /, params: Optional["ScheduledQueryRunRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ScheduledQueryRun": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, scheduled_query_run: str, + /, params: Optional["ScheduledQueryRunRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ScheduledQueryRun": diff --git a/stripe/tax/_calculation.py b/stripe/tax/_calculation.py index 4d89418b9..6c31e3fdb 100644 --- a/stripe/tax/_calculation.py +++ b/stripe/tax/_calculation.py @@ -564,6 +564,7 @@ async def create_async( def _cls_list_line_items( cls, calculation: str, + /, **params: Unpack["CalculationListLineItemsParams"], ) -> ListObject["CalculationLineItem"]: """ @@ -583,7 +584,7 @@ def _cls_list_line_items( @overload @staticmethod def list_line_items( - calculation: str, **params: Unpack["CalculationListLineItemsParams"] + calculation: str, /, **params: Unpack["CalculationListLineItemsParams"] ) -> ListObject["CalculationLineItem"]: """ Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired. @@ -621,6 +622,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues] async def _cls_list_line_items_async( cls, calculation: str, + /, **params: Unpack["CalculationListLineItemsParams"], ) -> ListObject["CalculationLineItem"]: """ @@ -640,7 +642,7 @@ async def _cls_list_line_items_async( @overload @staticmethod async def list_line_items_async( - calculation: str, **params: Unpack["CalculationListLineItemsParams"] + calculation: str, /, **params: Unpack["CalculationListLineItemsParams"] ) -> ListObject["CalculationLineItem"]: """ Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired. diff --git a/stripe/tax/_calculation_line_item_service.py b/stripe/tax/_calculation_line_item_service.py index 48c946c49..26aa8a0ad 100644 --- a/stripe/tax/_calculation_line_item_service.py +++ b/stripe/tax/_calculation_line_item_service.py @@ -18,6 +18,7 @@ class CalculationLineItemService(StripeService): def list( self, calculation: str, + /, params: Optional["CalculationLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CalculationLineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, calculation: str, + /, params: Optional["CalculationLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[CalculationLineItem]": diff --git a/stripe/tax/_calculation_service.py b/stripe/tax/_calculation_service.py index cddd00669..4616b200a 100644 --- a/stripe/tax/_calculation_service.py +++ b/stripe/tax/_calculation_service.py @@ -52,6 +52,7 @@ def __getattr__(self, name): def retrieve( self, calculation: str, + /, params: Optional["CalculationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Calculation": @@ -74,6 +75,7 @@ def retrieve( async def retrieve_async( self, calculation: str, + /, params: Optional["CalculationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Calculation": diff --git a/stripe/tax/_registration.py b/stripe/tax/_registration.py index cb01a9d1b..48f8e20bc 100644 --- a/stripe/tax/_registration.py +++ b/stripe/tax/_registration.py @@ -1166,7 +1166,7 @@ class Sr(StripeObject): """ class Th(StripeObject): - type: Literal["simplified"] + type: Union[Literal["simplified"], str] """ Type of registration in `country`. """ diff --git a/stripe/tax/_registration_service.py b/stripe/tax/_registration_service.py index a85fd5759..8e8814f84 100644 --- a/stripe/tax/_registration_service.py +++ b/stripe/tax/_registration_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["RegistrationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Registration": @@ -123,6 +124,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["RegistrationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Registration": @@ -143,6 +145,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["RegistrationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Registration": @@ -165,6 +168,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["RegistrationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Registration": diff --git a/stripe/tax/_transaction.py b/stripe/tax/_transaction.py index 726d0d33c..0e56fd12d 100644 --- a/stripe/tax/_transaction.py +++ b/stripe/tax/_transaction.py @@ -509,6 +509,7 @@ async def create_reversal_async( def _cls_list_line_items( cls, transaction: str, + /, **params: Unpack["TransactionListLineItemsParams"], ) -> ListObject["TransactionLineItem"]: """ @@ -528,7 +529,7 @@ def _cls_list_line_items( @overload @staticmethod def list_line_items( - transaction: str, **params: Unpack["TransactionListLineItemsParams"] + transaction: str, /, **params: Unpack["TransactionListLineItemsParams"] ) -> ListObject["TransactionLineItem"]: """ Retrieves the line items of a committed standalone transaction as a collection. @@ -566,6 +567,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues] async def _cls_list_line_items_async( cls, transaction: str, + /, **params: Unpack["TransactionListLineItemsParams"], ) -> ListObject["TransactionLineItem"]: """ @@ -585,7 +587,7 @@ async def _cls_list_line_items_async( @overload @staticmethod async def list_line_items_async( - transaction: str, **params: Unpack["TransactionListLineItemsParams"] + transaction: str, /, **params: Unpack["TransactionListLineItemsParams"] ) -> ListObject["TransactionLineItem"]: """ Retrieves the line items of a committed standalone transaction as a collection. diff --git a/stripe/tax/_transaction_line_item_service.py b/stripe/tax/_transaction_line_item_service.py index 2393374b8..3190e6dac 100644 --- a/stripe/tax/_transaction_line_item_service.py +++ b/stripe/tax/_transaction_line_item_service.py @@ -18,6 +18,7 @@ class TransactionLineItemService(StripeService): def list( self, transaction: str, + /, params: Optional["TransactionLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[TransactionLineItem]": @@ -40,6 +41,7 @@ def list( async def list_async( self, transaction: str, + /, params: Optional["TransactionLineItemListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[TransactionLineItem]": diff --git a/stripe/tax/_transaction_service.py b/stripe/tax/_transaction_service.py index 83397d610..c89f3bc43 100644 --- a/stripe/tax/_transaction_service.py +++ b/stripe/tax/_transaction_service.py @@ -55,6 +55,7 @@ def __getattr__(self, name): def retrieve( self, transaction: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -77,6 +78,7 @@ def retrieve( async def retrieve_async( self, transaction: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": diff --git a/stripe/terminal/_configuration_service.py b/stripe/terminal/_configuration_service.py index 0d6f251ee..040a10834 100644 --- a/stripe/terminal/_configuration_service.py +++ b/stripe/terminal/_configuration_service.py @@ -30,6 +30,7 @@ class ConfigurationService(StripeService): def delete( self, configuration: str, + /, params: Optional["ConfigurationDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -52,6 +53,7 @@ def delete( async def delete_async( self, configuration: str, + /, params: Optional["ConfigurationDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -74,6 +76,7 @@ async def delete_async( def retrieve( self, configuration: str, + /, params: Optional["ConfigurationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -96,6 +99,7 @@ def retrieve( async def retrieve_async( self, configuration: str, + /, params: Optional["ConfigurationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -118,6 +122,7 @@ async def retrieve_async( def update( self, configuration: str, + /, params: Optional["ConfigurationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": @@ -140,6 +145,7 @@ def update( async def update_async( self, configuration: str, + /, params: Optional["ConfigurationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Configuration": diff --git a/stripe/terminal/_location_service.py b/stripe/terminal/_location_service.py index 9c0aaf36d..05589040e 100644 --- a/stripe/terminal/_location_service.py +++ b/stripe/terminal/_location_service.py @@ -28,6 +28,7 @@ class LocationService(StripeService): def delete( self, location: str, + /, params: Optional["LocationDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Location": @@ -50,6 +51,7 @@ def delete( async def delete_async( self, location: str, + /, params: Optional["LocationDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Location": @@ -72,6 +74,7 @@ async def delete_async( def retrieve( self, location: str, + /, params: Optional["LocationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Location": @@ -94,6 +97,7 @@ def retrieve( async def retrieve_async( self, location: str, + /, params: Optional["LocationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Location": @@ -116,6 +120,7 @@ async def retrieve_async( def update( self, location: str, + /, params: Optional["LocationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Location": @@ -138,6 +143,7 @@ def update( async def update_async( self, location: str, + /, params: Optional["LocationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Location": diff --git a/stripe/terminal/_reader.py b/stripe/terminal/_reader.py index ff383ac78..72234e458 100644 --- a/stripe/terminal/_reader.py +++ b/stripe/terminal/_reader.py @@ -965,7 +965,7 @@ class LineItem(StripeObject): @classmethod def _cls_cancel_action( - cls, reader: str, **params: Unpack["ReaderCancelActionParams"] + cls, reader: str, /, **params: Unpack["ReaderCancelActionParams"] ) -> "Reader": """ Cancels the current reader action. See [Programmatic Cancellation](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven#programmatic-cancellation) for more details. @@ -984,7 +984,7 @@ def _cls_cancel_action( @overload @staticmethod def cancel_action( - reader: str, **params: Unpack["ReaderCancelActionParams"] + reader: str, /, **params: Unpack["ReaderCancelActionParams"] ) -> "Reader": """ Cancels the current reader action. See [Programmatic Cancellation](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven#programmatic-cancellation) for more details. @@ -1020,7 +1020,7 @@ def cancel_action( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_action_async( - cls, reader: str, **params: Unpack["ReaderCancelActionParams"] + cls, reader: str, /, **params: Unpack["ReaderCancelActionParams"] ) -> "Reader": """ Cancels the current reader action. See [Programmatic Cancellation](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven#programmatic-cancellation) for more details. @@ -1039,7 +1039,7 @@ async def _cls_cancel_action_async( @overload @staticmethod async def cancel_action_async( - reader: str, **params: Unpack["ReaderCancelActionParams"] + reader: str, /, **params: Unpack["ReaderCancelActionParams"] ) -> "Reader": """ Cancels the current reader action. See [Programmatic Cancellation](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven#programmatic-cancellation) for more details. @@ -1075,7 +1075,7 @@ async def cancel_action_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_collect_inputs( - cls, reader: str, **params: Unpack["ReaderCollectInputsParams"] + cls, reader: str, /, **params: Unpack["ReaderCollectInputsParams"] ) -> "Reader": """ Initiates an [input collection flow](https://docs.stripe.com/docs/terminal/features/collect-inputs) on a Reader to display input forms and collect information from your customers. @@ -1094,7 +1094,7 @@ def _cls_collect_inputs( @overload @staticmethod def collect_inputs( - reader: str, **params: Unpack["ReaderCollectInputsParams"] + reader: str, /, **params: Unpack["ReaderCollectInputsParams"] ) -> "Reader": """ Initiates an [input collection flow](https://docs.stripe.com/docs/terminal/features/collect-inputs) on a Reader to display input forms and collect information from your customers. @@ -1130,7 +1130,7 @@ def collect_inputs( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_collect_inputs_async( - cls, reader: str, **params: Unpack["ReaderCollectInputsParams"] + cls, reader: str, /, **params: Unpack["ReaderCollectInputsParams"] ) -> "Reader": """ Initiates an [input collection flow](https://docs.stripe.com/docs/terminal/features/collect-inputs) on a Reader to display input forms and collect information from your customers. @@ -1149,7 +1149,7 @@ async def _cls_collect_inputs_async( @overload @staticmethod async def collect_inputs_async( - reader: str, **params: Unpack["ReaderCollectInputsParams"] + reader: str, /, **params: Unpack["ReaderCollectInputsParams"] ) -> "Reader": """ Initiates an [input collection flow](https://docs.stripe.com/docs/terminal/features/collect-inputs) on a Reader to display input forms and collect information from your customers. @@ -1185,7 +1185,10 @@ async def collect_inputs_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_collect_payment_method( - cls, reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"] + cls, + reader: str, + /, + **params: Unpack["ReaderCollectPaymentMethodParams"], ) -> "Reader": """ Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation. See [Collecting a Payment method](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#collect-a-paymentmethod) for more details. @@ -1204,7 +1207,7 @@ def _cls_collect_payment_method( @overload @staticmethod def collect_payment_method( - reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"] + reader: str, /, **params: Unpack["ReaderCollectPaymentMethodParams"] ) -> "Reader": """ Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation. See [Collecting a Payment method](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#collect-a-paymentmethod) for more details. @@ -1240,7 +1243,10 @@ def collect_payment_method( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_collect_payment_method_async( - cls, reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"] + cls, + reader: str, + /, + **params: Unpack["ReaderCollectPaymentMethodParams"], ) -> "Reader": """ Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation. See [Collecting a Payment method](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#collect-a-paymentmethod) for more details. @@ -1259,7 +1265,7 @@ async def _cls_collect_payment_method_async( @overload @staticmethod async def collect_payment_method_async( - reader: str, **params: Unpack["ReaderCollectPaymentMethodParams"] + reader: str, /, **params: Unpack["ReaderCollectPaymentMethodParams"] ) -> "Reader": """ Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation. See [Collecting a Payment method](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#collect-a-paymentmethod) for more details. @@ -1295,7 +1301,10 @@ async def collect_payment_method_async( # pyright: ignore[reportGeneralTypeIssu @classmethod def _cls_confirm_payment_intent( - cls, reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"] + cls, + reader: str, + /, + **params: Unpack["ReaderConfirmPaymentIntentParams"], ) -> "Reader": """ Finalizes a payment on a Reader. See [Confirming a Payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#confirm-the-paymentintent) for more details. @@ -1314,7 +1323,7 @@ def _cls_confirm_payment_intent( @overload @staticmethod def confirm_payment_intent( - reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"] + reader: str, /, **params: Unpack["ReaderConfirmPaymentIntentParams"] ) -> "Reader": """ Finalizes a payment on a Reader. See [Confirming a Payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#confirm-the-paymentintent) for more details. @@ -1350,7 +1359,10 @@ def confirm_payment_intent( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_confirm_payment_intent_async( - cls, reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"] + cls, + reader: str, + /, + **params: Unpack["ReaderConfirmPaymentIntentParams"], ) -> "Reader": """ Finalizes a payment on a Reader. See [Confirming a Payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#confirm-the-paymentintent) for more details. @@ -1369,7 +1381,7 @@ async def _cls_confirm_payment_intent_async( @overload @staticmethod async def confirm_payment_intent_async( - reader: str, **params: Unpack["ReaderConfirmPaymentIntentParams"] + reader: str, /, **params: Unpack["ReaderConfirmPaymentIntentParams"] ) -> "Reader": """ Finalizes a payment on a Reader. See [Confirming a Payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=inspect#confirm-the-paymentintent) for more details. @@ -1603,7 +1615,10 @@ async def modify_async( @classmethod def _cls_process_payment_intent( - cls, reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"] + cls, + reader: str, + /, + **params: Unpack["ReaderProcessPaymentIntentParams"], ) -> "Reader": """ Initiates a payment flow on a Reader. See [process the payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=immediately#process-payment) for more details. @@ -1622,7 +1637,7 @@ def _cls_process_payment_intent( @overload @staticmethod def process_payment_intent( - reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"] + reader: str, /, **params: Unpack["ReaderProcessPaymentIntentParams"] ) -> "Reader": """ Initiates a payment flow on a Reader. See [process the payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=immediately#process-payment) for more details. @@ -1658,7 +1673,10 @@ def process_payment_intent( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_process_payment_intent_async( - cls, reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"] + cls, + reader: str, + /, + **params: Unpack["ReaderProcessPaymentIntentParams"], ) -> "Reader": """ Initiates a payment flow on a Reader. See [process the payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=immediately#process-payment) for more details. @@ -1677,7 +1695,7 @@ async def _cls_process_payment_intent_async( @overload @staticmethod async def process_payment_intent_async( - reader: str, **params: Unpack["ReaderProcessPaymentIntentParams"] + reader: str, /, **params: Unpack["ReaderProcessPaymentIntentParams"] ) -> "Reader": """ Initiates a payment flow on a Reader. See [process the payment](https://docs.stripe.com/docs/terminal/payments/collect-card-payment?terminal-sdk-platform=server-driven&process=immediately#process-payment) for more details. @@ -1713,7 +1731,7 @@ async def process_payment_intent_async( # pyright: ignore[reportGeneralTypeIssu @classmethod def _cls_process_setup_intent( - cls, reader: str, **params: Unpack["ReaderProcessSetupIntentParams"] + cls, reader: str, /, **params: Unpack["ReaderProcessSetupIntentParams"] ) -> "Reader": """ Initiates a SetupIntent flow on a Reader. See [Save directly without charging](https://docs.stripe.com/docs/terminal/features/saving-payment-details/save-directly) for more details. @@ -1732,7 +1750,7 @@ def _cls_process_setup_intent( @overload @staticmethod def process_setup_intent( - reader: str, **params: Unpack["ReaderProcessSetupIntentParams"] + reader: str, /, **params: Unpack["ReaderProcessSetupIntentParams"] ) -> "Reader": """ Initiates a SetupIntent flow on a Reader. See [Save directly without charging](https://docs.stripe.com/docs/terminal/features/saving-payment-details/save-directly) for more details. @@ -1768,7 +1786,7 @@ def process_setup_intent( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_process_setup_intent_async( - cls, reader: str, **params: Unpack["ReaderProcessSetupIntentParams"] + cls, reader: str, /, **params: Unpack["ReaderProcessSetupIntentParams"] ) -> "Reader": """ Initiates a SetupIntent flow on a Reader. See [Save directly without charging](https://docs.stripe.com/docs/terminal/features/saving-payment-details/save-directly) for more details. @@ -1787,7 +1805,7 @@ async def _cls_process_setup_intent_async( @overload @staticmethod async def process_setup_intent_async( - reader: str, **params: Unpack["ReaderProcessSetupIntentParams"] + reader: str, /, **params: Unpack["ReaderProcessSetupIntentParams"] ) -> "Reader": """ Initiates a SetupIntent flow on a Reader. See [Save directly without charging](https://docs.stripe.com/docs/terminal/features/saving-payment-details/save-directly) for more details. @@ -1823,7 +1841,7 @@ async def process_setup_intent_async( # pyright: ignore[reportGeneralTypeIssues @classmethod def _cls_refund_payment( - cls, reader: str, **params: Unpack["ReaderRefundPaymentParams"] + cls, reader: str, /, **params: Unpack["ReaderRefundPaymentParams"] ) -> "Reader": """ Initiates an in-person refund on a Reader. See [Refund an Interac Payment](https://docs.stripe.com/docs/terminal/payments/regional?integration-country=CA#refund-an-interac-payment) for more details. @@ -1842,7 +1860,7 @@ def _cls_refund_payment( @overload @staticmethod def refund_payment( - reader: str, **params: Unpack["ReaderRefundPaymentParams"] + reader: str, /, **params: Unpack["ReaderRefundPaymentParams"] ) -> "Reader": """ Initiates an in-person refund on a Reader. See [Refund an Interac Payment](https://docs.stripe.com/docs/terminal/payments/regional?integration-country=CA#refund-an-interac-payment) for more details. @@ -1878,7 +1896,7 @@ def refund_payment( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_refund_payment_async( - cls, reader: str, **params: Unpack["ReaderRefundPaymentParams"] + cls, reader: str, /, **params: Unpack["ReaderRefundPaymentParams"] ) -> "Reader": """ Initiates an in-person refund on a Reader. See [Refund an Interac Payment](https://docs.stripe.com/docs/terminal/payments/regional?integration-country=CA#refund-an-interac-payment) for more details. @@ -1897,7 +1915,7 @@ async def _cls_refund_payment_async( @overload @staticmethod async def refund_payment_async( - reader: str, **params: Unpack["ReaderRefundPaymentParams"] + reader: str, /, **params: Unpack["ReaderRefundPaymentParams"] ) -> "Reader": """ Initiates an in-person refund on a Reader. See [Refund an Interac Payment](https://docs.stripe.com/docs/terminal/payments/regional?integration-country=CA#refund-an-interac-payment) for more details. @@ -1955,7 +1973,7 @@ async def retrieve_async( @classmethod def _cls_set_reader_display( - cls, reader: str, **params: Unpack["ReaderSetReaderDisplayParams"] + cls, reader: str, /, **params: Unpack["ReaderSetReaderDisplayParams"] ) -> "Reader": """ Sets the reader display to show [cart details](https://docs.stripe.com/docs/terminal/features/display). @@ -1974,7 +1992,7 @@ def _cls_set_reader_display( @overload @staticmethod def set_reader_display( - reader: str, **params: Unpack["ReaderSetReaderDisplayParams"] + reader: str, /, **params: Unpack["ReaderSetReaderDisplayParams"] ) -> "Reader": """ Sets the reader display to show [cart details](https://docs.stripe.com/docs/terminal/features/display). @@ -2010,7 +2028,7 @@ def set_reader_display( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_set_reader_display_async( - cls, reader: str, **params: Unpack["ReaderSetReaderDisplayParams"] + cls, reader: str, /, **params: Unpack["ReaderSetReaderDisplayParams"] ) -> "Reader": """ Sets the reader display to show [cart details](https://docs.stripe.com/docs/terminal/features/display). @@ -2029,7 +2047,7 @@ async def _cls_set_reader_display_async( @overload @staticmethod async def set_reader_display_async( - reader: str, **params: Unpack["ReaderSetReaderDisplayParams"] + reader: str, /, **params: Unpack["ReaderSetReaderDisplayParams"] ) -> "Reader": """ Sets the reader display to show [cart details](https://docs.stripe.com/docs/terminal/features/display). @@ -2070,6 +2088,7 @@ class TestHelpers(APIResourceTestHelpers["Reader"]): def _cls_present_payment_method( cls, reader: str, + /, **params: Unpack["ReaderPresentPaymentMethodParams"], ) -> "Reader": """ @@ -2089,7 +2108,9 @@ def _cls_present_payment_method( @overload @staticmethod def present_payment_method( - reader: str, **params: Unpack["ReaderPresentPaymentMethodParams"] + reader: str, + /, + **params: Unpack["ReaderPresentPaymentMethodParams"], ) -> "Reader": """ Presents a payment method on a simulated reader. Can be used to simulate accepting a payment, saving a card or refunding a transaction. @@ -2127,6 +2148,7 @@ def present_payment_method( # pyright: ignore[reportGeneralTypeIssues] async def _cls_present_payment_method_async( cls, reader: str, + /, **params: Unpack["ReaderPresentPaymentMethodParams"], ) -> "Reader": """ @@ -2146,7 +2168,9 @@ async def _cls_present_payment_method_async( @overload @staticmethod async def present_payment_method_async( - reader: str, **params: Unpack["ReaderPresentPaymentMethodParams"] + reader: str, + /, + **params: Unpack["ReaderPresentPaymentMethodParams"], ) -> "Reader": """ Presents a payment method on a simulated reader. Can be used to simulate accepting a payment, saving a card or refunding a transaction. @@ -2184,6 +2208,7 @@ async def present_payment_method_async( # pyright: ignore[reportGeneralTypeIssu def _cls_succeed_input_collection( cls, reader: str, + /, **params: Unpack["ReaderSucceedInputCollectionParams"], ) -> "Reader": """ @@ -2203,7 +2228,9 @@ def _cls_succeed_input_collection( @overload @staticmethod def succeed_input_collection( - reader: str, **params: Unpack["ReaderSucceedInputCollectionParams"] + reader: str, + /, + **params: Unpack["ReaderSucceedInputCollectionParams"], ) -> "Reader": """ Use this endpoint to trigger a successful input collection on a simulated reader. @@ -2241,6 +2268,7 @@ def succeed_input_collection( # pyright: ignore[reportGeneralTypeIssues] async def _cls_succeed_input_collection_async( cls, reader: str, + /, **params: Unpack["ReaderSucceedInputCollectionParams"], ) -> "Reader": """ @@ -2260,7 +2288,9 @@ async def _cls_succeed_input_collection_async( @overload @staticmethod async def succeed_input_collection_async( - reader: str, **params: Unpack["ReaderSucceedInputCollectionParams"] + reader: str, + /, + **params: Unpack["ReaderSucceedInputCollectionParams"], ) -> "Reader": """ Use this endpoint to trigger a successful input collection on a simulated reader. @@ -2298,6 +2328,7 @@ async def succeed_input_collection_async( # pyright: ignore[reportGeneralTypeIs def _cls_timeout_input_collection( cls, reader: str, + /, **params: Unpack["ReaderTimeoutInputCollectionParams"], ) -> "Reader": """ @@ -2317,7 +2348,9 @@ def _cls_timeout_input_collection( @overload @staticmethod def timeout_input_collection( - reader: str, **params: Unpack["ReaderTimeoutInputCollectionParams"] + reader: str, + /, + **params: Unpack["ReaderTimeoutInputCollectionParams"], ) -> "Reader": """ Use this endpoint to complete an input collection with a timeout error on a simulated reader. @@ -2355,6 +2388,7 @@ def timeout_input_collection( # pyright: ignore[reportGeneralTypeIssues] async def _cls_timeout_input_collection_async( cls, reader: str, + /, **params: Unpack["ReaderTimeoutInputCollectionParams"], ) -> "Reader": """ @@ -2374,7 +2408,9 @@ async def _cls_timeout_input_collection_async( @overload @staticmethod async def timeout_input_collection_async( - reader: str, **params: Unpack["ReaderTimeoutInputCollectionParams"] + reader: str, + /, + **params: Unpack["ReaderTimeoutInputCollectionParams"], ) -> "Reader": """ Use this endpoint to complete an input collection with a timeout error on a simulated reader. diff --git a/stripe/terminal/_reader_service.py b/stripe/terminal/_reader_service.py index 8cb36a77f..29c3a1ae3 100644 --- a/stripe/terminal/_reader_service.py +++ b/stripe/terminal/_reader_service.py @@ -46,6 +46,7 @@ class ReaderService(StripeService): def delete( self, reader: str, + /, params: Optional["ReaderDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -68,6 +69,7 @@ def delete( async def delete_async( self, reader: str, + /, params: Optional["ReaderDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -90,6 +92,7 @@ async def delete_async( def retrieve( self, reader: str, + /, params: Optional["ReaderRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -112,6 +115,7 @@ def retrieve( async def retrieve_async( self, reader: str, + /, params: Optional["ReaderRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -134,6 +138,7 @@ async def retrieve_async( def update( self, reader: str, + /, params: Optional["ReaderUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -156,6 +161,7 @@ def update( async def update_async( self, reader: str, + /, params: Optional["ReaderUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -254,6 +260,7 @@ async def create_async( def cancel_action( self, reader: str, + /, params: Optional["ReaderCancelActionParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -276,6 +283,7 @@ def cancel_action( async def cancel_action_async( self, reader: str, + /, params: Optional["ReaderCancelActionParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -298,6 +306,7 @@ async def cancel_action_async( def collect_inputs( self, reader: str, + /, params: "ReaderCollectInputsParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -320,6 +329,7 @@ def collect_inputs( async def collect_inputs_async( self, reader: str, + /, params: "ReaderCollectInputsParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -342,6 +352,7 @@ async def collect_inputs_async( def collect_payment_method( self, reader: str, + /, params: "ReaderCollectPaymentMethodParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -364,6 +375,7 @@ def collect_payment_method( async def collect_payment_method_async( self, reader: str, + /, params: "ReaderCollectPaymentMethodParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -386,6 +398,7 @@ async def collect_payment_method_async( def confirm_payment_intent( self, reader: str, + /, params: "ReaderConfirmPaymentIntentParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -408,6 +421,7 @@ def confirm_payment_intent( async def confirm_payment_intent_async( self, reader: str, + /, params: "ReaderConfirmPaymentIntentParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -430,6 +444,7 @@ async def confirm_payment_intent_async( def process_payment_intent( self, reader: str, + /, params: "ReaderProcessPaymentIntentParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -452,6 +467,7 @@ def process_payment_intent( async def process_payment_intent_async( self, reader: str, + /, params: "ReaderProcessPaymentIntentParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -474,6 +490,7 @@ async def process_payment_intent_async( def process_setup_intent( self, reader: str, + /, params: "ReaderProcessSetupIntentParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -496,6 +513,7 @@ def process_setup_intent( async def process_setup_intent_async( self, reader: str, + /, params: "ReaderProcessSetupIntentParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -518,6 +536,7 @@ async def process_setup_intent_async( def refund_payment( self, reader: str, + /, params: Optional["ReaderRefundPaymentParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -540,6 +559,7 @@ def refund_payment( async def refund_payment_async( self, reader: str, + /, params: Optional["ReaderRefundPaymentParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -562,6 +582,7 @@ async def refund_payment_async( def set_reader_display( self, reader: str, + /, params: "ReaderSetReaderDisplayParams", options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -584,6 +605,7 @@ def set_reader_display( async def set_reader_display_async( self, reader: str, + /, params: "ReaderSetReaderDisplayParams", options: Optional["RequestOptions"] = None, ) -> "Reader": diff --git a/stripe/test_helpers/_customer_service.py b/stripe/test_helpers/_customer_service.py index a9da41ccd..e6b651ff3 100644 --- a/stripe/test_helpers/_customer_service.py +++ b/stripe/test_helpers/_customer_service.py @@ -19,6 +19,7 @@ class CustomerService(StripeService): def fund_cash_balance( self, customer: str, + /, params: "CustomerFundCashBalanceParams", options: Optional["RequestOptions"] = None, ) -> "CustomerCashBalanceTransaction": @@ -41,6 +42,7 @@ def fund_cash_balance( async def fund_cash_balance_async( self, customer: str, + /, params: "CustomerFundCashBalanceParams", options: Optional["RequestOptions"] = None, ) -> "CustomerCashBalanceTransaction": diff --git a/stripe/test_helpers/_refund_service.py b/stripe/test_helpers/_refund_service.py index 92969f298..893194706 100644 --- a/stripe/test_helpers/_refund_service.py +++ b/stripe/test_helpers/_refund_service.py @@ -17,6 +17,7 @@ class RefundService(StripeService): def expire( self, refund: str, + /, params: Optional["RefundExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": @@ -39,6 +40,7 @@ def expire( async def expire_async( self, refund: str, + /, params: Optional["RefundExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Refund": diff --git a/stripe/test_helpers/_test_clock.py b/stripe/test_helpers/_test_clock.py index e0aa91ed9..5cfc58f8f 100644 --- a/stripe/test_helpers/_test_clock.py +++ b/stripe/test_helpers/_test_clock.py @@ -92,7 +92,7 @@ class Advancing(StripeObject): @classmethod def _cls_advance( - cls, test_clock: str, **params: Unpack["TestClockAdvanceParams"] + cls, test_clock: str, /, **params: Unpack["TestClockAdvanceParams"] ) -> "TestClock": """ Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready. @@ -111,7 +111,7 @@ def _cls_advance( @overload @staticmethod def advance( - test_clock: str, **params: Unpack["TestClockAdvanceParams"] + test_clock: str, /, **params: Unpack["TestClockAdvanceParams"] ) -> "TestClock": """ Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready. @@ -147,7 +147,7 @@ def advance( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_advance_async( - cls, test_clock: str, **params: Unpack["TestClockAdvanceParams"] + cls, test_clock: str, /, **params: Unpack["TestClockAdvanceParams"] ) -> "TestClock": """ Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready. @@ -166,7 +166,7 @@ async def _cls_advance_async( @overload @staticmethod async def advance_async( - test_clock: str, **params: Unpack["TestClockAdvanceParams"] + test_clock: str, /, **params: Unpack["TestClockAdvanceParams"] ) -> "TestClock": """ Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready. diff --git a/stripe/test_helpers/_test_clock_service.py b/stripe/test_helpers/_test_clock_service.py index 07f5af6f4..99b2ea2b2 100644 --- a/stripe/test_helpers/_test_clock_service.py +++ b/stripe/test_helpers/_test_clock_service.py @@ -30,6 +30,7 @@ class TestClockService(StripeService): def delete( self, test_clock: str, + /, params: Optional["TestClockDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TestClock": @@ -52,6 +53,7 @@ def delete( async def delete_async( self, test_clock: str, + /, params: Optional["TestClockDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TestClock": @@ -74,6 +76,7 @@ async def delete_async( def retrieve( self, test_clock: str, + /, params: Optional["TestClockRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TestClock": @@ -96,6 +99,7 @@ def retrieve( async def retrieve_async( self, test_clock: str, + /, params: Optional["TestClockRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TestClock": @@ -194,6 +198,7 @@ async def create_async( def advance( self, test_clock: str, + /, params: "TestClockAdvanceParams", options: Optional["RequestOptions"] = None, ) -> "TestClock": @@ -216,6 +221,7 @@ def advance( async def advance_async( self, test_clock: str, + /, params: "TestClockAdvanceParams", options: Optional["RequestOptions"] = None, ) -> "TestClock": diff --git a/stripe/test_helpers/issuing/_authorization_service.py b/stripe/test_helpers/issuing/_authorization_service.py index df546d3f9..23f40f7c9 100644 --- a/stripe/test_helpers/issuing/_authorization_service.py +++ b/stripe/test_helpers/issuing/_authorization_service.py @@ -73,6 +73,7 @@ async def create_async( def capture( self, authorization: str, + /, params: Optional["AuthorizationCaptureParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -95,6 +96,7 @@ def capture( async def capture_async( self, authorization: str, + /, params: Optional["AuthorizationCaptureParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -117,6 +119,7 @@ async def capture_async( def expire( self, authorization: str, + /, params: Optional["AuthorizationExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -139,6 +142,7 @@ def expire( async def expire_async( self, authorization: str, + /, params: Optional["AuthorizationExpireParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -161,6 +165,7 @@ async def expire_async( def finalize_amount( self, authorization: str, + /, params: "AuthorizationFinalizeAmountParams", options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -183,6 +188,7 @@ def finalize_amount( async def finalize_amount_async( self, authorization: str, + /, params: "AuthorizationFinalizeAmountParams", options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -205,6 +211,7 @@ async def finalize_amount_async( def respond( self, authorization: str, + /, params: "AuthorizationRespondParams", options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -227,6 +234,7 @@ def respond( async def respond_async( self, authorization: str, + /, params: "AuthorizationRespondParams", options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -249,6 +257,7 @@ async def respond_async( def increment( self, authorization: str, + /, params: "AuthorizationIncrementParams", options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -271,6 +280,7 @@ def increment( async def increment_async( self, authorization: str, + /, params: "AuthorizationIncrementParams", options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -293,6 +303,7 @@ async def increment_async( def reverse( self, authorization: str, + /, params: Optional["AuthorizationReverseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": @@ -315,6 +326,7 @@ def reverse( async def reverse_async( self, authorization: str, + /, params: Optional["AuthorizationReverseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Authorization": diff --git a/stripe/test_helpers/issuing/_card_service.py b/stripe/test_helpers/issuing/_card_service.py index 8aaf8937b..ad0e1a573 100644 --- a/stripe/test_helpers/issuing/_card_service.py +++ b/stripe/test_helpers/issuing/_card_service.py @@ -29,6 +29,7 @@ class CardService(StripeService): def deliver_card( self, card: str, + /, params: Optional["CardDeliverCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -51,6 +52,7 @@ def deliver_card( async def deliver_card_async( self, card: str, + /, params: Optional["CardDeliverCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -73,6 +75,7 @@ async def deliver_card_async( def fail_card( self, card: str, + /, params: Optional["CardFailCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -95,6 +98,7 @@ def fail_card( async def fail_card_async( self, card: str, + /, params: Optional["CardFailCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -117,6 +121,7 @@ async def fail_card_async( def return_card( self, card: str, + /, params: Optional["CardReturnCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -139,6 +144,7 @@ def return_card( async def return_card_async( self, card: str, + /, params: Optional["CardReturnCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -161,6 +167,7 @@ async def return_card_async( def ship_card( self, card: str, + /, params: Optional["CardShipCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -183,6 +190,7 @@ def ship_card( async def ship_card_async( self, card: str, + /, params: Optional["CardShipCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -205,6 +213,7 @@ async def ship_card_async( def submit_card( self, card: str, + /, params: Optional["CardSubmitCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": @@ -227,6 +236,7 @@ def submit_card( async def submit_card_async( self, card: str, + /, params: Optional["CardSubmitCardParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Card": diff --git a/stripe/test_helpers/issuing/_personalization_design_service.py b/stripe/test_helpers/issuing/_personalization_design_service.py index 4079e8352..ca6adc3d7 100644 --- a/stripe/test_helpers/issuing/_personalization_design_service.py +++ b/stripe/test_helpers/issuing/_personalization_design_service.py @@ -23,6 +23,7 @@ class PersonalizationDesignService(StripeService): def activate( self, personalization_design: str, + /, params: Optional["PersonalizationDesignActivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -45,6 +46,7 @@ def activate( async def activate_async( self, personalization_design: str, + /, params: Optional["PersonalizationDesignActivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -67,6 +69,7 @@ async def activate_async( def deactivate( self, personalization_design: str, + /, params: Optional["PersonalizationDesignDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -89,6 +92,7 @@ def deactivate( async def deactivate_async( self, personalization_design: str, + /, params: Optional["PersonalizationDesignDeactivateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -111,6 +115,7 @@ async def deactivate_async( def reject( self, personalization_design: str, + /, params: "PersonalizationDesignRejectParams", options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": @@ -133,6 +138,7 @@ def reject( async def reject_async( self, personalization_design: str, + /, params: "PersonalizationDesignRejectParams", options: Optional["RequestOptions"] = None, ) -> "PersonalizationDesign": diff --git a/stripe/test_helpers/issuing/_transaction_service.py b/stripe/test_helpers/issuing/_transaction_service.py index fcd28302d..f2c60fa63 100644 --- a/stripe/test_helpers/issuing/_transaction_service.py +++ b/stripe/test_helpers/issuing/_transaction_service.py @@ -23,6 +23,7 @@ class TransactionService(StripeService): def refund( self, transaction: str, + /, params: Optional["TransactionRefundParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -45,6 +46,7 @@ def refund( async def refund_async( self, transaction: str, + /, params: Optional["TransactionRefundParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": diff --git a/stripe/test_helpers/terminal/_reader_service.py b/stripe/test_helpers/terminal/_reader_service.py index 307b8d19a..57d6aa575 100644 --- a/stripe/test_helpers/terminal/_reader_service.py +++ b/stripe/test_helpers/terminal/_reader_service.py @@ -23,6 +23,7 @@ class ReaderService(StripeService): def present_payment_method( self, reader: str, + /, params: Optional["ReaderPresentPaymentMethodParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -45,6 +46,7 @@ def present_payment_method( async def present_payment_method_async( self, reader: str, + /, params: Optional["ReaderPresentPaymentMethodParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -67,6 +69,7 @@ async def present_payment_method_async( def succeed_input_collection( self, reader: str, + /, params: Optional["ReaderSucceedInputCollectionParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -89,6 +92,7 @@ def succeed_input_collection( async def succeed_input_collection_async( self, reader: str, + /, params: Optional["ReaderSucceedInputCollectionParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -111,6 +115,7 @@ async def succeed_input_collection_async( def timeout_input_collection( self, reader: str, + /, params: Optional["ReaderTimeoutInputCollectionParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": @@ -133,6 +138,7 @@ def timeout_input_collection( async def timeout_input_collection_async( self, reader: str, + /, params: Optional["ReaderTimeoutInputCollectionParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Reader": diff --git a/stripe/test_helpers/treasury/_inbound_transfer_service.py b/stripe/test_helpers/treasury/_inbound_transfer_service.py index c37255e54..13402c931 100644 --- a/stripe/test_helpers/treasury/_inbound_transfer_service.py +++ b/stripe/test_helpers/treasury/_inbound_transfer_service.py @@ -23,6 +23,7 @@ class InboundTransferService(StripeService): def fail( self, id: str, + /, params: Optional["InboundTransferFailParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -45,6 +46,7 @@ def fail( async def fail_async( self, id: str, + /, params: Optional["InboundTransferFailParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -67,6 +69,7 @@ async def fail_async( def return_inbound_transfer( self, id: str, + /, params: Optional["InboundTransferReturnInboundTransferParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -89,6 +92,7 @@ def return_inbound_transfer( async def return_inbound_transfer_async( self, id: str, + /, params: Optional["InboundTransferReturnInboundTransferParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -111,6 +115,7 @@ async def return_inbound_transfer_async( def succeed( self, id: str, + /, params: Optional["InboundTransferSucceedParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -133,6 +138,7 @@ def succeed( async def succeed_async( self, id: str, + /, params: Optional["InboundTransferSucceedParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": diff --git a/stripe/test_helpers/treasury/_outbound_payment_service.py b/stripe/test_helpers/treasury/_outbound_payment_service.py index 42aff8495..e3c187e54 100644 --- a/stripe/test_helpers/treasury/_outbound_payment_service.py +++ b/stripe/test_helpers/treasury/_outbound_payment_service.py @@ -26,6 +26,7 @@ class OutboundPaymentService(StripeService): def update( self, id: str, + /, params: "OutboundPaymentUpdateParams", options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -48,6 +49,7 @@ def update( async def update_async( self, id: str, + /, params: "OutboundPaymentUpdateParams", options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -70,6 +72,7 @@ async def update_async( def fail( self, id: str, + /, params: Optional["OutboundPaymentFailParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -92,6 +95,7 @@ def fail( async def fail_async( self, id: str, + /, params: Optional["OutboundPaymentFailParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -114,6 +118,7 @@ async def fail_async( def post( self, id: str, + /, params: Optional["OutboundPaymentPostParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -136,6 +141,7 @@ def post( async def post_async( self, id: str, + /, params: Optional["OutboundPaymentPostParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -158,6 +164,7 @@ async def post_async( def return_outbound_payment( self, id: str, + /, params: Optional["OutboundPaymentReturnOutboundPaymentParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -180,6 +187,7 @@ def return_outbound_payment( async def return_outbound_payment_async( self, id: str, + /, params: Optional["OutboundPaymentReturnOutboundPaymentParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": diff --git a/stripe/test_helpers/treasury/_outbound_transfer_service.py b/stripe/test_helpers/treasury/_outbound_transfer_service.py index 68ffe4fba..eca1872cd 100644 --- a/stripe/test_helpers/treasury/_outbound_transfer_service.py +++ b/stripe/test_helpers/treasury/_outbound_transfer_service.py @@ -26,6 +26,7 @@ class OutboundTransferService(StripeService): def update( self, outbound_transfer: str, + /, params: "OutboundTransferUpdateParams", options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -48,6 +49,7 @@ def update( async def update_async( self, outbound_transfer: str, + /, params: "OutboundTransferUpdateParams", options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -70,6 +72,7 @@ async def update_async( def fail( self, outbound_transfer: str, + /, params: Optional["OutboundTransferFailParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -92,6 +95,7 @@ def fail( async def fail_async( self, outbound_transfer: str, + /, params: Optional["OutboundTransferFailParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -114,6 +118,7 @@ async def fail_async( def post( self, outbound_transfer: str, + /, params: Optional["OutboundTransferPostParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -136,6 +141,7 @@ def post( async def post_async( self, outbound_transfer: str, + /, params: Optional["OutboundTransferPostParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -158,6 +164,7 @@ async def post_async( def return_outbound_transfer( self, outbound_transfer: str, + /, params: Optional[ "OutboundTransferReturnOutboundTransferParams" ] = None, @@ -182,6 +189,7 @@ def return_outbound_transfer( async def return_outbound_transfer_async( self, outbound_transfer: str, + /, params: Optional[ "OutboundTransferReturnOutboundTransferParams" ] = None, diff --git a/stripe/treasury/_credit_reversal_service.py b/stripe/treasury/_credit_reversal_service.py index 1d4407f97..3b0942d6b 100644 --- a/stripe/treasury/_credit_reversal_service.py +++ b/stripe/treasury/_credit_reversal_service.py @@ -100,6 +100,7 @@ async def create_async( def retrieve( self, credit_reversal: str, + /, params: Optional["CreditReversalRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditReversal": @@ -122,6 +123,7 @@ def retrieve( async def retrieve_async( self, credit_reversal: str, + /, params: Optional["CreditReversalRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "CreditReversal": diff --git a/stripe/treasury/_debit_reversal_service.py b/stripe/treasury/_debit_reversal_service.py index f39dd5435..e14134eef 100644 --- a/stripe/treasury/_debit_reversal_service.py +++ b/stripe/treasury/_debit_reversal_service.py @@ -100,6 +100,7 @@ async def create_async( def retrieve( self, debit_reversal: str, + /, params: Optional["DebitReversalRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "DebitReversal": @@ -122,6 +123,7 @@ def retrieve( async def retrieve_async( self, debit_reversal: str, + /, params: Optional["DebitReversalRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "DebitReversal": diff --git a/stripe/treasury/_financial_account.py b/stripe/treasury/_financial_account.py index fbc26f3b5..b139ad7ae 100644 --- a/stripe/treasury/_financial_account.py +++ b/stripe/treasury/_financial_account.py @@ -264,6 +264,7 @@ class Closed(StripeObject): def _cls_close( cls, financial_account: str, + /, **params: Unpack["FinancialAccountCloseParams"], ) -> "FinancialAccount": """ @@ -283,7 +284,9 @@ def _cls_close( @overload @staticmethod def close( - financial_account: str, **params: Unpack["FinancialAccountCloseParams"] + financial_account: str, + /, + **params: Unpack["FinancialAccountCloseParams"], ) -> "FinancialAccount": """ Closes a FinancialAccount. A FinancialAccount can only be closed if it has a zero balance, has no pending InboundTransfers, and has canceled all attached Issuing cards. @@ -321,6 +324,7 @@ def close( # pyright: ignore[reportGeneralTypeIssues] async def _cls_close_async( cls, financial_account: str, + /, **params: Unpack["FinancialAccountCloseParams"], ) -> "FinancialAccount": """ @@ -340,7 +344,9 @@ async def _cls_close_async( @overload @staticmethod async def close_async( - financial_account: str, **params: Unpack["FinancialAccountCloseParams"] + financial_account: str, + /, + **params: Unpack["FinancialAccountCloseParams"], ) -> "FinancialAccount": """ Closes a FinancialAccount. A FinancialAccount can only be closed if it has a zero balance, has no pending InboundTransfers, and has canceled all attached Issuing cards. @@ -506,6 +512,7 @@ async def retrieve_async( def _cls_retrieve_features( cls, financial_account: str, + /, **params: Unpack["FinancialAccountRetrieveFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -526,6 +533,7 @@ def _cls_retrieve_features( @staticmethod def retrieve_features( financial_account: str, + /, **params: Unpack["FinancialAccountRetrieveFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -564,6 +572,7 @@ def retrieve_features( # pyright: ignore[reportGeneralTypeIssues] async def _cls_retrieve_features_async( cls, financial_account: str, + /, **params: Unpack["FinancialAccountRetrieveFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -584,6 +593,7 @@ async def _cls_retrieve_features_async( @staticmethod async def retrieve_features_async( financial_account: str, + /, **params: Unpack["FinancialAccountRetrieveFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -622,6 +632,7 @@ async def retrieve_features_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_update_features( cls, financial_account: str, + /, **params: Unpack["FinancialAccountUpdateFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -642,6 +653,7 @@ def _cls_update_features( @staticmethod def update_features( financial_account: str, + /, **params: Unpack["FinancialAccountUpdateFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -680,6 +692,7 @@ def update_features( # pyright: ignore[reportGeneralTypeIssues] async def _cls_update_features_async( cls, financial_account: str, + /, **params: Unpack["FinancialAccountUpdateFeaturesParams"], ) -> "FinancialAccountFeatures": """ @@ -700,6 +713,7 @@ async def _cls_update_features_async( @staticmethod async def update_features_async( financial_account: str, + /, **params: Unpack["FinancialAccountUpdateFeaturesParams"], ) -> "FinancialAccountFeatures": """ diff --git a/stripe/treasury/_financial_account_features_service.py b/stripe/treasury/_financial_account_features_service.py index b89cec2d7..f526ea9c0 100644 --- a/stripe/treasury/_financial_account_features_service.py +++ b/stripe/treasury/_financial_account_features_service.py @@ -22,6 +22,7 @@ class FinancialAccountFeaturesService(StripeService): def update( self, financial_account: str, + /, params: Optional["FinancialAccountFeaturesUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccountFeatures": @@ -44,6 +45,7 @@ def update( async def update_async( self, financial_account: str, + /, params: Optional["FinancialAccountFeaturesUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccountFeatures": @@ -66,6 +68,7 @@ async def update_async( def retrieve( self, financial_account: str, + /, params: Optional["FinancialAccountFeaturesRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccountFeatures": @@ -88,6 +91,7 @@ def retrieve( async def retrieve_async( self, financial_account: str, + /, params: Optional["FinancialAccountFeaturesRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccountFeatures": diff --git a/stripe/treasury/_financial_account_service.py b/stripe/treasury/_financial_account_service.py index 269b67ec4..9f3542c6f 100644 --- a/stripe/treasury/_financial_account_service.py +++ b/stripe/treasury/_financial_account_service.py @@ -138,6 +138,7 @@ async def create_async( def retrieve( self, financial_account: str, + /, params: Optional["FinancialAccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccount": @@ -160,6 +161,7 @@ def retrieve( async def retrieve_async( self, financial_account: str, + /, params: Optional["FinancialAccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccount": @@ -182,6 +184,7 @@ async def retrieve_async( def update( self, financial_account: str, + /, params: Optional["FinancialAccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccount": @@ -204,6 +207,7 @@ def update( async def update_async( self, financial_account: str, + /, params: Optional["FinancialAccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccount": @@ -226,6 +230,7 @@ async def update_async( def close( self, financial_account: str, + /, params: Optional["FinancialAccountCloseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccount": @@ -248,6 +253,7 @@ def close( async def close_async( self, financial_account: str, + /, params: Optional["FinancialAccountCloseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "FinancialAccount": diff --git a/stripe/treasury/_inbound_transfer.py b/stripe/treasury/_inbound_transfer.py index 1c3b31675..5dde10b18 100644 --- a/stripe/treasury/_inbound_transfer.py +++ b/stripe/treasury/_inbound_transfer.py @@ -260,6 +260,7 @@ class StatusTransitions(StripeObject): def _cls_cancel( cls, inbound_transfer: str, + /, **params: Unpack["InboundTransferCancelParams"], ) -> "InboundTransfer": """ @@ -279,7 +280,9 @@ def _cls_cancel( @overload @staticmethod def cancel( - inbound_transfer: str, **params: Unpack["InboundTransferCancelParams"] + inbound_transfer: str, + /, + **params: Unpack["InboundTransferCancelParams"], ) -> "InboundTransfer": """ Cancels an InboundTransfer. @@ -317,6 +320,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] async def _cls_cancel_async( cls, inbound_transfer: str, + /, **params: Unpack["InboundTransferCancelParams"], ) -> "InboundTransfer": """ @@ -336,7 +340,9 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - inbound_transfer: str, **params: Unpack["InboundTransferCancelParams"] + inbound_transfer: str, + /, + **params: Unpack["InboundTransferCancelParams"], ) -> "InboundTransfer": """ Cancels an InboundTransfer. @@ -469,7 +475,7 @@ class TestHelpers(APIResourceTestHelpers["InboundTransfer"]): @classmethod def _cls_fail( - cls, id: str, **params: Unpack["InboundTransferFailParams"] + cls, id: str, /, **params: Unpack["InboundTransferFailParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state. @@ -488,7 +494,7 @@ def _cls_fail( @overload @staticmethod def fail( - id: str, **params: Unpack["InboundTransferFailParams"] + id: str, /, **params: Unpack["InboundTransferFailParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state. @@ -524,7 +530,7 @@ def fail( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_fail_async( - cls, id: str, **params: Unpack["InboundTransferFailParams"] + cls, id: str, /, **params: Unpack["InboundTransferFailParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state. @@ -543,7 +549,7 @@ async def _cls_fail_async( @overload @staticmethod async def fail_async( - id: str, **params: Unpack["InboundTransferFailParams"] + id: str, /, **params: Unpack["InboundTransferFailParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state. @@ -581,6 +587,7 @@ async def fail_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_return_inbound_transfer( cls, id: str, + /, **params: Unpack["InboundTransferReturnInboundTransferParams"], ) -> "InboundTransfer": """ @@ -601,6 +608,7 @@ def _cls_return_inbound_transfer( @staticmethod def return_inbound_transfer( id: str, + /, **params: Unpack["InboundTransferReturnInboundTransferParams"], ) -> "InboundTransfer": """ @@ -641,6 +649,7 @@ def return_inbound_transfer( # pyright: ignore[reportGeneralTypeIssues] async def _cls_return_inbound_transfer_async( cls, id: str, + /, **params: Unpack["InboundTransferReturnInboundTransferParams"], ) -> "InboundTransfer": """ @@ -661,6 +670,7 @@ async def _cls_return_inbound_transfer_async( @staticmethod async def return_inbound_transfer_async( id: str, + /, **params: Unpack["InboundTransferReturnInboundTransferParams"], ) -> "InboundTransfer": """ @@ -699,7 +709,7 @@ async def return_inbound_transfer_async( # pyright: ignore[reportGeneralTypeIss @classmethod def _cls_succeed( - cls, id: str, **params: Unpack["InboundTransferSucceedParams"] + cls, id: str, /, **params: Unpack["InboundTransferSucceedParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state. @@ -718,7 +728,7 @@ def _cls_succeed( @overload @staticmethod def succeed( - id: str, **params: Unpack["InboundTransferSucceedParams"] + id: str, /, **params: Unpack["InboundTransferSucceedParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state. @@ -754,7 +764,7 @@ def succeed( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_succeed_async( - cls, id: str, **params: Unpack["InboundTransferSucceedParams"] + cls, id: str, /, **params: Unpack["InboundTransferSucceedParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state. @@ -773,7 +783,7 @@ async def _cls_succeed_async( @overload @staticmethod async def succeed_async( - id: str, **params: Unpack["InboundTransferSucceedParams"] + id: str, /, **params: Unpack["InboundTransferSucceedParams"] ) -> "InboundTransfer": """ Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state. diff --git a/stripe/treasury/_inbound_transfer_service.py b/stripe/treasury/_inbound_transfer_service.py index 7ce66d3e5..91a68a098 100644 --- a/stripe/treasury/_inbound_transfer_service.py +++ b/stripe/treasury/_inbound_transfer_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["InboundTransferRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["InboundTransferRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -147,6 +149,7 @@ async def retrieve_async( def cancel( self, inbound_transfer: str, + /, params: Optional["InboundTransferCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": @@ -169,6 +172,7 @@ def cancel( async def cancel_async( self, inbound_transfer: str, + /, params: Optional["InboundTransferCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "InboundTransfer": diff --git a/stripe/treasury/_outbound_payment.py b/stripe/treasury/_outbound_payment.py index 04b13de61..2e7320cc0 100644 --- a/stripe/treasury/_outbound_payment.py +++ b/stripe/treasury/_outbound_payment.py @@ -326,7 +326,7 @@ class UsDomesticWire(StripeObject): @classmethod def _cls_cancel( - cls, id: str, **params: Unpack["OutboundPaymentCancelParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentCancelParams"] ) -> "OutboundPayment": """ Cancel an OutboundPayment. @@ -345,7 +345,7 @@ def _cls_cancel( @overload @staticmethod def cancel( - id: str, **params: Unpack["OutboundPaymentCancelParams"] + id: str, /, **params: Unpack["OutboundPaymentCancelParams"] ) -> "OutboundPayment": """ Cancel an OutboundPayment. @@ -381,7 +381,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_cancel_async( - cls, id: str, **params: Unpack["OutboundPaymentCancelParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentCancelParams"] ) -> "OutboundPayment": """ Cancel an OutboundPayment. @@ -400,7 +400,7 @@ async def _cls_cancel_async( @overload @staticmethod async def cancel_async( - id: str, **params: Unpack["OutboundPaymentCancelParams"] + id: str, /, **params: Unpack["OutboundPaymentCancelParams"] ) -> "OutboundPayment": """ Cancel an OutboundPayment. @@ -533,7 +533,7 @@ class TestHelpers(APIResourceTestHelpers["OutboundPayment"]): @classmethod def _cls_fail( - cls, id: str, **params: Unpack["OutboundPaymentFailParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentFailParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state. @@ -552,7 +552,7 @@ def _cls_fail( @overload @staticmethod def fail( - id: str, **params: Unpack["OutboundPaymentFailParams"] + id: str, /, **params: Unpack["OutboundPaymentFailParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state. @@ -588,7 +588,7 @@ def fail( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_fail_async( - cls, id: str, **params: Unpack["OutboundPaymentFailParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentFailParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state. @@ -607,7 +607,7 @@ async def _cls_fail_async( @overload @staticmethod async def fail_async( - id: str, **params: Unpack["OutboundPaymentFailParams"] + id: str, /, **params: Unpack["OutboundPaymentFailParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state. @@ -643,7 +643,7 @@ async def fail_async( # pyright: ignore[reportGeneralTypeIssues] @classmethod def _cls_post( - cls, id: str, **params: Unpack["OutboundPaymentPostParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentPostParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state. @@ -662,7 +662,7 @@ def _cls_post( @overload @staticmethod def post( - id: str, **params: Unpack["OutboundPaymentPostParams"] + id: str, /, **params: Unpack["OutboundPaymentPostParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state. @@ -698,7 +698,7 @@ def post( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_post_async( - cls, id: str, **params: Unpack["OutboundPaymentPostParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentPostParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state. @@ -717,7 +717,7 @@ async def _cls_post_async( @overload @staticmethod async def post_async( - id: str, **params: Unpack["OutboundPaymentPostParams"] + id: str, /, **params: Unpack["OutboundPaymentPostParams"] ) -> "OutboundPayment": """ Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state. @@ -755,6 +755,7 @@ async def post_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_return_outbound_payment( cls, id: str, + /, **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"], ) -> "OutboundPayment": """ @@ -775,6 +776,7 @@ def _cls_return_outbound_payment( @staticmethod def return_outbound_payment( id: str, + /, **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"], ) -> "OutboundPayment": """ @@ -815,6 +817,7 @@ def return_outbound_payment( # pyright: ignore[reportGeneralTypeIssues] async def _cls_return_outbound_payment_async( cls, id: str, + /, **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"], ) -> "OutboundPayment": """ @@ -835,6 +838,7 @@ async def _cls_return_outbound_payment_async( @staticmethod async def return_outbound_payment_async( id: str, + /, **params: Unpack["OutboundPaymentReturnOutboundPaymentParams"], ) -> "OutboundPayment": """ @@ -873,7 +877,7 @@ async def return_outbound_payment_async( # pyright: ignore[reportGeneralTypeIss @classmethod def _cls_update( - cls, id: str, **params: Unpack["OutboundPaymentUpdateParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentUpdateParams"] ) -> "OutboundPayment": """ Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states. @@ -892,7 +896,7 @@ def _cls_update( @overload @staticmethod def update( - id: str, **params: Unpack["OutboundPaymentUpdateParams"] + id: str, /, **params: Unpack["OutboundPaymentUpdateParams"] ) -> "OutboundPayment": """ Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states. @@ -928,7 +932,7 @@ def update( # pyright: ignore[reportGeneralTypeIssues] @classmethod async def _cls_update_async( - cls, id: str, **params: Unpack["OutboundPaymentUpdateParams"] + cls, id: str, /, **params: Unpack["OutboundPaymentUpdateParams"] ) -> "OutboundPayment": """ Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states. @@ -947,7 +951,7 @@ async def _cls_update_async( @overload @staticmethod async def update_async( - id: str, **params: Unpack["OutboundPaymentUpdateParams"] + id: str, /, **params: Unpack["OutboundPaymentUpdateParams"] ) -> "OutboundPayment": """ Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states. diff --git a/stripe/treasury/_outbound_payment_service.py b/stripe/treasury/_outbound_payment_service.py index 97a27c73a..9d7912efa 100644 --- a/stripe/treasury/_outbound_payment_service.py +++ b/stripe/treasury/_outbound_payment_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["OutboundPaymentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["OutboundPaymentRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -147,6 +149,7 @@ async def retrieve_async( def cancel( self, id: str, + /, params: Optional["OutboundPaymentCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": @@ -169,6 +172,7 @@ def cancel( async def cancel_async( self, id: str, + /, params: Optional["OutboundPaymentCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundPayment": diff --git a/stripe/treasury/_outbound_transfer.py b/stripe/treasury/_outbound_transfer.py index 06403cc4e..9920dbcea 100644 --- a/stripe/treasury/_outbound_transfer.py +++ b/stripe/treasury/_outbound_transfer.py @@ -305,6 +305,7 @@ class UsDomesticWire(StripeObject): def _cls_cancel( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferCancelParams"], ) -> "OutboundTransfer": """ @@ -325,6 +326,7 @@ def _cls_cancel( @staticmethod def cancel( outbound_transfer: str, + /, **params: Unpack["OutboundTransferCancelParams"], ) -> "OutboundTransfer": """ @@ -363,6 +365,7 @@ def cancel( # pyright: ignore[reportGeneralTypeIssues] async def _cls_cancel_async( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferCancelParams"], ) -> "OutboundTransfer": """ @@ -383,6 +386,7 @@ async def _cls_cancel_async( @staticmethod async def cancel_async( outbound_transfer: str, + /, **params: Unpack["OutboundTransferCancelParams"], ) -> "OutboundTransfer": """ @@ -518,6 +522,7 @@ class TestHelpers(APIResourceTestHelpers["OutboundTransfer"]): def _cls_fail( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferFailParams"], ) -> "OutboundTransfer": """ @@ -538,6 +543,7 @@ def _cls_fail( @staticmethod def fail( outbound_transfer: str, + /, **params: Unpack["OutboundTransferFailParams"], ) -> "OutboundTransfer": """ @@ -578,6 +584,7 @@ def fail( # pyright: ignore[reportGeneralTypeIssues] async def _cls_fail_async( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferFailParams"], ) -> "OutboundTransfer": """ @@ -598,6 +605,7 @@ async def _cls_fail_async( @staticmethod async def fail_async( outbound_transfer: str, + /, **params: Unpack["OutboundTransferFailParams"], ) -> "OutboundTransfer": """ @@ -638,6 +646,7 @@ async def fail_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_post( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferPostParams"], ) -> "OutboundTransfer": """ @@ -658,6 +667,7 @@ def _cls_post( @staticmethod def post( outbound_transfer: str, + /, **params: Unpack["OutboundTransferPostParams"], ) -> "OutboundTransfer": """ @@ -698,6 +708,7 @@ def post( # pyright: ignore[reportGeneralTypeIssues] async def _cls_post_async( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferPostParams"], ) -> "OutboundTransfer": """ @@ -718,6 +729,7 @@ async def _cls_post_async( @staticmethod async def post_async( outbound_transfer: str, + /, **params: Unpack["OutboundTransferPostParams"], ) -> "OutboundTransfer": """ @@ -758,6 +770,7 @@ async def post_async( # pyright: ignore[reportGeneralTypeIssues] def _cls_return_outbound_transfer( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferReturnOutboundTransferParams"], ) -> "OutboundTransfer": """ @@ -778,6 +791,7 @@ def _cls_return_outbound_transfer( @staticmethod def return_outbound_transfer( outbound_transfer: str, + /, **params: Unpack["OutboundTransferReturnOutboundTransferParams"], ) -> "OutboundTransfer": """ @@ -820,6 +834,7 @@ def return_outbound_transfer( # pyright: ignore[reportGeneralTypeIssues] async def _cls_return_outbound_transfer_async( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferReturnOutboundTransferParams"], ) -> "OutboundTransfer": """ @@ -840,6 +855,7 @@ async def _cls_return_outbound_transfer_async( @staticmethod async def return_outbound_transfer_async( outbound_transfer: str, + /, **params: Unpack["OutboundTransferReturnOutboundTransferParams"], ) -> "OutboundTransfer": """ @@ -882,6 +898,7 @@ async def return_outbound_transfer_async( # pyright: ignore[reportGeneralTypeIs def _cls_update( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferUpdateParams"], ) -> "OutboundTransfer": """ @@ -902,6 +919,7 @@ def _cls_update( @staticmethod def update( outbound_transfer: str, + /, **params: Unpack["OutboundTransferUpdateParams"], ) -> "OutboundTransfer": """ @@ -942,6 +960,7 @@ def update( # pyright: ignore[reportGeneralTypeIssues] async def _cls_update_async( cls, outbound_transfer: str, + /, **params: Unpack["OutboundTransferUpdateParams"], ) -> "OutboundTransfer": """ @@ -962,6 +981,7 @@ async def _cls_update_async( @staticmethod async def update_async( outbound_transfer: str, + /, **params: Unpack["OutboundTransferUpdateParams"], ) -> "OutboundTransfer": """ diff --git a/stripe/treasury/_outbound_transfer_service.py b/stripe/treasury/_outbound_transfer_service.py index b4783fb4b..87d77d1aa 100644 --- a/stripe/treasury/_outbound_transfer_service.py +++ b/stripe/treasury/_outbound_transfer_service.py @@ -103,6 +103,7 @@ async def create_async( def retrieve( self, outbound_transfer: str, + /, params: Optional["OutboundTransferRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -125,6 +126,7 @@ def retrieve( async def retrieve_async( self, outbound_transfer: str, + /, params: Optional["OutboundTransferRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -147,6 +149,7 @@ async def retrieve_async( def cancel( self, outbound_transfer: str, + /, params: Optional["OutboundTransferCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": @@ -169,6 +172,7 @@ def cancel( async def cancel_async( self, outbound_transfer: str, + /, params: Optional["OutboundTransferCancelParams"] = None, options: Optional["RequestOptions"] = None, ) -> "OutboundTransfer": diff --git a/stripe/treasury/_received_credit_service.py b/stripe/treasury/_received_credit_service.py index 06baf6013..cc88b686a 100644 --- a/stripe/treasury/_received_credit_service.py +++ b/stripe/treasury/_received_credit_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["ReceivedCreditRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReceivedCredit": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["ReceivedCreditRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReceivedCredit": diff --git a/stripe/treasury/_received_debit_service.py b/stripe/treasury/_received_debit_service.py index 678e51dbb..c2dc3df0b 100644 --- a/stripe/treasury/_received_debit_service.py +++ b/stripe/treasury/_received_debit_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["ReceivedDebitRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReceivedDebit": @@ -79,6 +80,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["ReceivedDebitRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ReceivedDebit": diff --git a/stripe/treasury/_transaction_entry_service.py b/stripe/treasury/_transaction_entry_service.py index 590fa1c06..2266c6d19 100644 --- a/stripe/treasury/_transaction_entry_service.py +++ b/stripe/treasury/_transaction_entry_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["TransactionEntryRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TransactionEntry": @@ -81,6 +82,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["TransactionEntryRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "TransactionEntry": diff --git a/stripe/treasury/_transaction_service.py b/stripe/treasury/_transaction_service.py index c43c50687..10ec3d2d2 100644 --- a/stripe/treasury/_transaction_service.py +++ b/stripe/treasury/_transaction_service.py @@ -59,6 +59,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": @@ -79,6 +80,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["TransactionRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Transaction": diff --git a/stripe/v2/billing/_meter_event_adjustment.py b/stripe/v2/billing/_meter_event_adjustment.py index 741df9078..1a74d9bc3 100644 --- a/stripe/v2/billing/_meter_event_adjustment.py +++ b/stripe/v2/billing/_meter_event_adjustment.py @@ -48,7 +48,7 @@ class Cancel(StripeObject): """ Open Enum. The meter event adjustment's status. """ - type: Literal["cancel"] + type: Union[Literal["cancel"], str] """ Open Enum. Specifies the type of cancellation. Currently supports canceling a single event. """ diff --git a/stripe/v2/commerce/product_catalog/_import_service.py b/stripe/v2/commerce/product_catalog/_import_service.py index cc5f28bcd..3e32a7f01 100644 --- a/stripe/v2/commerce/product_catalog/_import_service.py +++ b/stripe/v2/commerce/product_catalog/_import_service.py @@ -100,6 +100,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["ImportRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ProductCatalogImport": @@ -122,6 +123,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["ImportRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ProductCatalogImport": diff --git a/stripe/v2/core/_account.py b/stripe/v2/core/_account.py index 84fabf29f..df5978725 100644 --- a/stripe/v2/core/_account.py +++ b/stripe/v2/core/_account.py @@ -2981,7 +2981,7 @@ class BankAccountOwnershipVerification(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -2991,7 +2991,7 @@ class CompanyLicense(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3001,7 +3001,7 @@ class CompanyMemorandumOfAssociation(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3011,7 +3011,7 @@ class CompanyMinisterialDecree(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3021,7 +3021,7 @@ class CompanyRegistrationVerification(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3031,7 +3031,7 @@ class CompanyTaxIdVerification(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3051,7 +3051,7 @@ class FrontBack(StripeObject): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -3062,7 +3062,7 @@ class ProofOfAddress(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3082,7 +3082,7 @@ class Signer(StripeObject): """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3103,7 +3103,7 @@ class Signer(StripeObject): """ Person that is signing the document. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3634,7 +3634,7 @@ class CompanyAuthorization(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3644,7 +3644,7 @@ class Passport(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -3664,7 +3664,7 @@ class FrontBack(StripeObject): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -3685,7 +3685,7 @@ class FrontBack(StripeObject): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -3696,7 +3696,7 @@ class Visa(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/v2/core/_account_person.py b/stripe/v2/core/_account_person.py index f4f06045a..e1c4a1608 100644 --- a/stripe/v2/core/_account_person.py +++ b/stripe/v2/core/_account_person.py @@ -138,7 +138,7 @@ class CompanyAuthorization(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -148,7 +148,7 @@ class Passport(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ @@ -168,7 +168,7 @@ class FrontBack(StripeObject): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -189,7 +189,7 @@ class FrontBack(StripeObject): """ The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document. """ - type: Literal["front_back"] + type: Union[Literal["front_back"], str] """ The format of the verification document. Currently supports `front_back` only. """ @@ -200,7 +200,7 @@ class Visa(StripeObject): """ One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`. """ - type: Literal["files"] + type: Union[Literal["files"], str] """ The format of the document. Currently supports `files` only. """ diff --git a/stripe/v2/core/_account_service.py b/stripe/v2/core/_account_service.py index c10dd2364..6efe00e36 100644 --- a/stripe/v2/core/_account_service.py +++ b/stripe/v2/core/_account_service.py @@ -160,6 +160,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["AccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -180,6 +181,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["AccountRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -200,6 +202,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["AccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -231,6 +234,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["AccountUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -262,6 +266,7 @@ async def update_async( def close( self, id: str, + /, params: Optional["AccountCloseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": @@ -282,6 +287,7 @@ def close( async def close_async( self, id: str, + /, params: Optional["AccountCloseParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Account": diff --git a/stripe/v2/core/_account_token_service.py b/stripe/v2/core/_account_token_service.py index 1278bb729..33d82d2c2 100644 --- a/stripe/v2/core/_account_token_service.py +++ b/stripe/v2/core/_account_token_service.py @@ -89,6 +89,7 @@ async def create_async( def retrieve( self, id: str, + /, params: Optional["AccountTokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountToken": @@ -109,6 +110,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["AccountTokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountToken": diff --git a/stripe/v2/core/_event.py b/stripe/v2/core/_event.py index fb6ab6e09..634ddae2f 100644 --- a/stripe/v2/core/_event.py +++ b/stripe/v2/core/_event.py @@ -40,7 +40,7 @@ class Request(StripeObject): """ Information on the API request that instigated the event. """ - type: Literal["request"] + type: Union[Literal["request"], str] """ Event reason type. """ diff --git a/stripe/v2/core/_event_destination_service.py b/stripe/v2/core/_event_destination_service.py index a788a391d..7bac3937e 100644 --- a/stripe/v2/core/_event_destination_service.py +++ b/stripe/v2/core/_event_destination_service.py @@ -117,6 +117,7 @@ async def create_async( def delete( self, id: str, + /, params: Optional["EventDestinationDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "DeletedObject": @@ -137,6 +138,7 @@ def delete( async def delete_async( self, id: str, + /, params: Optional["EventDestinationDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "DeletedObject": @@ -157,6 +159,7 @@ async def delete_async( def retrieve( self, id: str, + /, params: Optional["EventDestinationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -177,6 +180,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["EventDestinationRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -197,6 +201,7 @@ async def retrieve_async( def update( self, id: str, + /, params: Optional["EventDestinationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -217,6 +222,7 @@ def update( async def update_async( self, id: str, + /, params: Optional["EventDestinationUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -237,6 +243,7 @@ async def update_async( def disable( self, id: str, + /, params: Optional["EventDestinationDisableParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -259,6 +266,7 @@ def disable( async def disable_async( self, id: str, + /, params: Optional["EventDestinationDisableParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -281,6 +289,7 @@ async def disable_async( def enable( self, id: str, + /, params: Optional["EventDestinationEnableParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -303,6 +312,7 @@ def enable( async def enable_async( self, id: str, + /, params: Optional["EventDestinationEnableParams"] = None, options: Optional["RequestOptions"] = None, ) -> "EventDestination": @@ -325,6 +335,7 @@ async def enable_async( def ping( self, id: str, + /, params: Optional["EventDestinationPingParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Event": @@ -347,6 +358,7 @@ def ping( async def ping_async( self, id: str, + /, params: Optional["EventDestinationPingParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Event": diff --git a/stripe/v2/core/_event_service.py b/stripe/v2/core/_event_service.py index 7033683af..a33ba4f0a 100644 --- a/stripe/v2/core/_event_service.py +++ b/stripe/v2/core/_event_service.py @@ -57,6 +57,7 @@ async def list_async( def retrieve( self, id: str, + /, params: Optional["EventRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Event": @@ -78,6 +79,7 @@ def retrieve( async def retrieve_async( self, id: str, + /, params: Optional["EventRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "Event": diff --git a/stripe/v2/core/accounts/_person_service.py b/stripe/v2/core/accounts/_person_service.py index 60bd385d1..c3c5d6c80 100644 --- a/stripe/v2/core/accounts/_person_service.py +++ b/stripe/v2/core/accounts/_person_service.py @@ -32,6 +32,7 @@ class PersonService(StripeService): def list( self, account_id: str, + /, params: Optional["PersonListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[AccountPerson]": @@ -54,6 +55,7 @@ def list( async def list_async( self, account_id: str, + /, params: Optional["PersonListParams"] = None, options: Optional["RequestOptions"] = None, ) -> "ListObject[AccountPerson]": @@ -76,6 +78,7 @@ async def list_async( def create( self, account_id: str, + /, params: Optional["PersonCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPerson": @@ -101,6 +104,7 @@ def create( async def create_async( self, account_id: str, + /, params: Optional["PersonCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPerson": @@ -127,6 +131,7 @@ def delete( self, account_id: str, id: str, + /, params: Optional["PersonDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "DeletedObject": @@ -151,6 +156,7 @@ async def delete_async( self, account_id: str, id: str, + /, params: Optional["PersonDeleteParams"] = None, options: Optional["RequestOptions"] = None, ) -> "DeletedObject": @@ -175,6 +181,7 @@ def retrieve( self, account_id: str, id: str, + /, params: Optional["PersonRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPerson": @@ -199,6 +206,7 @@ async def retrieve_async( self, account_id: str, id: str, + /, params: Optional["PersonRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPerson": @@ -223,6 +231,7 @@ def update( self, account_id: str, id: str, + /, params: Optional["PersonUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPerson": @@ -250,6 +259,7 @@ async def update_async( self, account_id: str, id: str, + /, params: Optional["PersonUpdateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPerson": diff --git a/stripe/v2/core/accounts/_person_token_service.py b/stripe/v2/core/accounts/_person_token_service.py index a9f6ca4b2..0a40fb628 100644 --- a/stripe/v2/core/accounts/_person_token_service.py +++ b/stripe/v2/core/accounts/_person_token_service.py @@ -21,6 +21,7 @@ class PersonTokenService(StripeService): def create( self, account_id: str, + /, params: Optional["PersonTokenCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPersonToken": @@ -47,6 +48,7 @@ def create( async def create_async( self, account_id: str, + /, params: Optional["PersonTokenCreateParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPersonToken": @@ -74,6 +76,7 @@ def retrieve( self, account_id: str, id: str, + /, params: Optional["PersonTokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPersonToken": @@ -98,6 +101,7 @@ async def retrieve_async( self, account_id: str, id: str, + /, params: Optional["PersonTokenRetrieveParams"] = None, options: Optional["RequestOptions"] = None, ) -> "AccountPersonToken":