Skip to content

Commit

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

* Update generated code for v1079

* Update generated code for v1081

* Update generated code for v1082

* Update generated code for v1083

---------

Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
  • Loading branch information
stripe-openapi[bot] committed Jun 17, 2024
1 parent 741844f commit 0eb15d6
Show file tree
Hide file tree
Showing 9 changed files with 45 additions and 18 deletions.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v1077
v1083
2 changes: 1 addition & 1 deletion stripe/_account.py
Original file line number Diff line number Diff line change
Expand Up @@ -3327,7 +3327,7 @@ class ModifyCapabilityParams(RequestOptions):
"""
To request a new capability for an account, pass true. There can be a delay before the requested capability becomes active. If the capability has any activation requirements, the response includes them in the `requirements` arrays.
If a capability isn't permanent, you can remove it from the account by passing false. Most capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
If a capability isn't permanent, you can remove it from the account by passing false. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
"""

class ModifyExternalAccountParams(RequestOptions):
Expand Down
2 changes: 1 addition & 1 deletion stripe/_account_capability_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class UpdateParams(TypedDict):
"""
To request a new capability for an account, pass true. There can be a delay before the requested capability becomes active. If the capability has any activation requirements, the response includes them in the `requirements` arrays.
If a capability isn't permanent, you can remove it from the account by passing false. Most capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
If a capability isn't permanent, you can remove it from the account by passing false. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
"""

def list(
Expand Down
16 changes: 15 additions & 1 deletion stripe/_payment_link.py
Original file line number Diff line number Diff line change
Expand Up @@ -789,6 +789,7 @@ class CreateParams(RequestOptions):
"klarna",
"konbini",
"link",
"mobilepay",
"oxxo",
"p24",
"paynow",
Expand Down Expand Up @@ -1667,7 +1668,7 @@ class ModifyParams(RequestOptions):
If you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
"""
payment_method_types: NotRequired[
"Literal['']|List[Literal['affirm', 'afterpay_clearpay', 'alipay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'oxxo', 'p24', 'paynow', 'paypal', 'pix', 'promptpay', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
"Literal['']|List[Literal['affirm', 'afterpay_clearpay', 'alipay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'mobilepay', 'oxxo', 'p24', 'paynow', 'paypal', 'pix', 'promptpay', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
]
"""
The list of payment method types that customers can use. Pass an empty string to enable dynamic payment methods that use your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
Expand All @@ -1690,6 +1691,12 @@ class ModifyParams(RequestOptions):
"""
When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
"""
tax_id_collection: NotRequired[
"PaymentLink.ModifyParamsTaxIdCollection"
]
"""
Controls tax ID collection during checkout.
"""

class ModifyParamsAfterCompletion(TypedDict):
hosted_confirmation: NotRequired[
Expand Down Expand Up @@ -2306,6 +2313,12 @@ class ModifyParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
"""

class ModifyParamsTaxIdCollection(TypedDict):
enabled: bool
"""
Set to `true` to enable tax ID collection.
"""

class RetrieveParams(RequestOptions):
expand: NotRequired[List[str]]
"""
Expand Down Expand Up @@ -2416,6 +2429,7 @@ class RetrieveParams(RequestOptions):
"klarna",
"konbini",
"link",
"mobilepay",
"oxxo",
"p24",
"paynow",
Expand Down
15 changes: 14 additions & 1 deletion stripe/_payment_link_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ class CreateParams(TypedDict):
"klarna",
"konbini",
"link",
"mobilepay",
"oxxo",
"p24",
"paynow",
Expand Down Expand Up @@ -1011,7 +1012,7 @@ class UpdateParams(TypedDict):
If you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
"""
payment_method_types: NotRequired[
"Literal['']|List[Literal['affirm', 'afterpay_clearpay', 'alipay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'oxxo', 'p24', 'paynow', 'paypal', 'pix', 'promptpay', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
"Literal['']|List[Literal['affirm', 'afterpay_clearpay', 'alipay', 'au_becs_debit', 'bacs_debit', 'bancontact', 'blik', 'boleto', 'card', 'cashapp', 'eps', 'fpx', 'giropay', 'grabpay', 'ideal', 'klarna', 'konbini', 'link', 'mobilepay', 'oxxo', 'p24', 'paynow', 'paypal', 'pix', 'promptpay', 'sepa_debit', 'sofort', 'swish', 'us_bank_account', 'wechat_pay']]"
]
"""
The list of payment method types that customers can use. Pass an empty string to enable dynamic payment methods that use your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
Expand All @@ -1034,6 +1035,12 @@ class UpdateParams(TypedDict):
"""
When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
"""
tax_id_collection: NotRequired[
"PaymentLinkService.UpdateParamsTaxIdCollection"
]
"""
Controls tax ID collection during checkout.
"""

class UpdateParamsAfterCompletion(TypedDict):
hosted_confirmation: NotRequired[
Expand Down Expand Up @@ -1656,6 +1663,12 @@ class UpdateParamsSubscriptionDataTrialSettingsEndBehavior(TypedDict):
Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
"""

class UpdateParamsTaxIdCollection(TypedDict):
enabled: bool
"""
Set to `true` to enable tax ID collection.
"""

def list(
self,
params: "PaymentLinkService.ListParams" = {},
Expand Down
16 changes: 8 additions & 8 deletions stripe/tax/_calculation.py
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,7 @@ def _cls_list_line_items(
**params: Unpack["Calculation.ListLineItemsParams"],
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
return cast(
ListObject["CalculationLineItem"],
Expand All @@ -764,7 +764,7 @@ def list_line_items(
calculation: str, **params: Unpack["Calculation.ListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
...

Expand All @@ -773,7 +773,7 @@ def list_line_items(
self, **params: Unpack["Calculation.ListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
...

Expand All @@ -782,7 +782,7 @@ def list_line_items( # pyright: ignore[reportGeneralTypeIssues]
self, **params: Unpack["Calculation.ListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
return cast(
ListObject["CalculationLineItem"],
Expand All @@ -802,7 +802,7 @@ async def _cls_list_line_items_async(
**params: Unpack["Calculation.ListLineItemsParams"],
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
return cast(
ListObject["CalculationLineItem"],
Expand All @@ -821,7 +821,7 @@ async def list_line_items_async(
calculation: str, **params: Unpack["Calculation.ListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
...

Expand All @@ -830,7 +830,7 @@ async def list_line_items_async(
self, **params: Unpack["Calculation.ListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
...

Expand All @@ -839,7 +839,7 @@ async def list_line_items_async( # pyright: ignore[reportGeneralTypeIssues]
self, **params: Unpack["Calculation.ListLineItemsParams"]
) -> ListObject["CalculationLineItem"]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
return cast(
ListObject["CalculationLineItem"],
Expand Down
4 changes: 2 additions & 2 deletions stripe/tax/_calculation_line_item_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def list(
options: RequestOptions = {},
) -> ListObject[CalculationLineItem]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
return cast(
ListObject[CalculationLineItem],
Expand All @@ -58,7 +58,7 @@ async def list_async(
options: RequestOptions = {},
) -> ListObject[CalculationLineItem]:
"""
Retrieves the line items of a persisted tax calculation as a collection.
Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
"""
return cast(
ListObject[CalculationLineItem],
Expand Down
4 changes: 2 additions & 2 deletions stripe/terminal/_connection_token.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@ class CreateParams(RequestOptions):
"""
location: NotRequired[str]
"""
The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://stripe.com/docs/terminal/fleet/locations#connection-tokens).
The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
"""

location: Optional[str]
"""
The id of the location that this connection token is scoped to. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://stripe.com/docs/terminal/fleet/locations#connection-tokens).
The id of the location that this connection token is scoped to. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
"""
object: Literal["terminal.connection_token"]
"""
Expand Down
2 changes: 1 addition & 1 deletion stripe/terminal/_connection_token_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class CreateParams(TypedDict):
"""
location: NotRequired[str]
"""
The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://stripe.com/docs/terminal/fleet/locations#connection-tokens).
The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
"""

def create(
Expand Down

0 comments on commit 0eb15d6

Please sign in to comment.