Skip to content

Commit

Permalink
Merge upstream and update generated code for v1081
Browse files Browse the repository at this point in the history
  • Loading branch information
stripe-openapi[bot] committed Jun 14, 2024
2 parents 4db167e + 741844f commit 81655fe
Show file tree
Hide file tree
Showing 10 changed files with 52 additions and 16 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
## 9.11.0 - 2024-06-13
* [#1342](https://github.com/stripe/stripe-python/pull/1342) Update generated code
* Add support for `multibanco_payments` on resource class `stripe.Account.Capabilities` and parameter class `stripe.Account.CreateParamsCapabilities`
* Add support for `twint_payments` on resource class `stripe.Account.Capabilities` and parameter class `stripe.Account.CreateParamsCapabilities`
* Add support for `twint` on resource classes `stripe.Charge.PaymentMethodDetails`, `stripe.ConfirmationToken.PaymentMethodPreview`, and `stripe.PaymentIntent.PaymentMethodOptions`, parameter classes `stripe.ConfirmationToken.CreateParamsPaymentMethodData`, `stripe.PaymentIntent.ConfirmParamsPaymentMethodData`, `stripe.PaymentIntent.ConfirmParamsPaymentMethodOptions`, `stripe.PaymentIntent.CreateParamsPaymentMethodData`, `stripe.PaymentIntent.CreateParamsPaymentMethodOptions`, `stripe.PaymentIntent.ModifyParamsPaymentMethodData`, `stripe.PaymentIntent.ModifyParamsPaymentMethodOptions`, `stripe.PaymentMethod.CreateParams`, `stripe.SetupIntent.ConfirmParamsPaymentMethodData`, `stripe.SetupIntent.CreateParamsPaymentMethodData`, and `stripe.SetupIntent.ModifyParamsPaymentMethodData`, and resource `stripe.PaymentMethod`
* Add support for `multibanco` on parameter classes `stripe.ConfirmationToken.CreateParamsPaymentMethodData`, `stripe.PaymentIntent.ConfirmParamsPaymentMethodData`, `stripe.PaymentIntent.ConfirmParamsPaymentMethodOptions`, `stripe.PaymentIntent.CreateParamsPaymentMethodData`, `stripe.PaymentIntent.CreateParamsPaymentMethodOptions`, `stripe.PaymentIntent.ModifyParamsPaymentMethodData`, `stripe.PaymentIntent.ModifyParamsPaymentMethodOptions`, `stripe.PaymentMethod.CreateParams`, `stripe.PaymentMethodConfiguration.CreateParams`, `stripe.PaymentMethodConfiguration.ModifyParams`, `stripe.SetupIntent.ConfirmParamsPaymentMethodData`, `stripe.SetupIntent.CreateParamsPaymentMethodData`, `stripe.SetupIntent.ModifyParamsPaymentMethodData`, and `stripe.checkout.Session.CreateParamsPaymentMethodOptions`, resource classes `stripe.ConfirmationToken.PaymentMethodPreview`, `stripe.PaymentIntent.PaymentMethodOptions`, `stripe.Refund.DestinationDetails`, and `stripe.checkout.Session.PaymentMethodOptions`, and resources `stripe.PaymentMethod` and `stripe.PaymentMethodConfiguration`
* Add support for `multibanco_display_details` on resource class `stripe.PaymentIntent.NextAction`
* Add support for `invoice_settings` on resource `stripe.Subscription`
* Add support for `de_stn` on enums `stripe.checkout.Session.CustomerDetails.TaxId.type`, `stripe.Customer.CreateParamsTaxIdDatum.type`, `stripe.Customer.CreateTaxIdParams.type`, `stripe.Invoice.CustomerTaxId.type`, `stripe.Invoice.CreatePreviewParamsCustomerDetailsTaxId.type`, `stripe.Invoice.UpcomingParamsCustomerDetailsTaxId.type`, `stripe.Invoice.UpcomingLinesParamsCustomerDetailsTaxId.type`, `stripe.tax.Calculation.CustomerDetails.TaxId.type`, `stripe.tax.Calculation.CreateParamsCustomerDetailsTaxId.type`, `stripe.tax.Transaction.CustomerDetails.TaxId.type`, `stripe.TaxId.type`, and `stripe.TaxId.CreateParams.type`
* Add support for `multibanco` on enums `stripe.checkout.Session.CreateParams.payment_method_types`, `stripe.ConfirmationToken.PaymentMethodPreview.type`, `stripe.ConfirmationToken.CreateParamsPaymentMethodData.type`, `stripe.Customer.ListPaymentMethodsParams.type`, `stripe.PaymentIntent.ConfirmParamsPaymentMethodData.type`, `stripe.PaymentIntent.CreateParamsPaymentMethodData.type`, `stripe.PaymentIntent.ModifyParamsPaymentMethodData.type`, `stripe.PaymentMethod.type`, `stripe.PaymentMethod.CreateParams.type`, `stripe.PaymentMethod.ListParams.type`, `stripe.SetupIntent.ConfirmParamsPaymentMethodData.type`, `stripe.SetupIntent.CreateParamsPaymentMethodData.type`, and `stripe.SetupIntent.ModifyParamsPaymentMethodData.type`
* Add support for `twint` on enums `stripe.checkout.Session.CreateParams.payment_method_types`, `stripe.ConfirmationToken.PaymentMethodPreview.type`, `stripe.ConfirmationToken.CreateParamsPaymentMethodData.type`, `stripe.Customer.ListPaymentMethodsParams.type`, `stripe.PaymentIntent.ConfirmParamsPaymentMethodData.type`, `stripe.PaymentIntent.CreateParamsPaymentMethodData.type`, `stripe.PaymentIntent.ModifyParamsPaymentMethodData.type`, `stripe.PaymentMethod.type`, `stripe.PaymentMethod.CreateParams.type`, `stripe.PaymentMethod.ListParams.type`, `stripe.SetupIntent.ConfirmParamsPaymentMethodData.type`, `stripe.SetupIntent.CreateParamsPaymentMethodData.type`, and `stripe.SetupIntent.ModifyParamsPaymentMethodData.type`

## 9.10.0 - 2024-06-06
* [#1340](https://github.com/stripe/stripe-python/pull/1340) Update generated code
* Add support for `gb_bank_transfer_payments`, `jp_bank_transfer_payments`, `mx_bank_transfer_payments`, `sepa_bank_transfer_payments`, `us_bank_transfer_payments` on resource class `stripe.Account.Capabilities` and parameter class `stripe.Account.CreateParamsCapabilities`
Expand Down
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v1077
v1081
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
9.10.0
9.11.0
12 changes: 12 additions & 0 deletions stripe/_payment_link.py
Original file line number Diff line number Diff line change
Expand Up @@ -1690,6 +1690,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 +2312,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
12 changes: 12 additions & 0 deletions stripe/_payment_link_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -1034,6 +1034,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 +1662,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
2 changes: 1 addition & 1 deletion stripe/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
VERSION = "9.10.0"
VERSION = "9.11.0"
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 81655fe

Please sign in to comment.