diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index ad548b855..1f205edf7 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1260 \ No newline at end of file +v1266 \ No newline at end of file diff --git a/stripe/_account.py b/stripe/_account.py index f5246a701..db36e83a8 100644 --- a/stripe/_account.py +++ b/stripe/_account.py @@ -746,6 +746,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. @@ -895,6 +896,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. diff --git a/stripe/_bank_account.py b/stripe/_bank_account.py index 733b7ba0e..fc827b93b 100644 --- a/stripe/_bank_account.py +++ b/stripe/_bank_account.py @@ -126,6 +126,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. @@ -249,6 +250,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. diff --git a/stripe/_capability.py b/stripe/_capability.py index 0974b8d52..944236d60 100644 --- a/stripe/_capability.py +++ b/stripe/_capability.py @@ -120,6 +120,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. @@ -282,6 +283,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. diff --git a/stripe/_charge.py b/stripe/_charge.py index 2bcb9b148..9d0463bd5 100644 --- a/stripe/_charge.py +++ b/stripe/_charge.py @@ -1286,6 +1286,23 @@ class Receipt(StripeObject): _inner_class_types = {"receipt": Receipt} class Klarna(StripeObject): + class PayerDetails(StripeObject): + class Address(StripeObject): + country: Optional[str] + """ + The payer address country + """ + + address: Optional[Address] + """ + The payer's address + """ + _inner_class_types = {"address": Address} + + payer_details: Optional[PayerDetails] + """ + The payer details for this transaction. + """ payment_method_category: Optional[str] """ The Klarna payment method used for this transaction. @@ -1296,6 +1313,7 @@ class Klarna(StripeObject): Preferred language of the Klarna authorization page that the customer is redirected to. Can be one of `de-AT`, `en-AT`, `nl-BE`, `fr-BE`, `en-BE`, `de-DE`, `en-DE`, `da-DK`, `en-DK`, `es-ES`, `en-ES`, `fi-FI`, `sv-FI`, `en-FI`, `en-GB`, `en-IE`, `it-IT`, `en-IT`, `nl-NL`, `en-NL`, `nb-NO`, `en-NO`, `sv-SE`, `en-SE`, `en-US`, `es-US`, `fr-FR`, `en-FR`, `cs-CZ`, `en-CZ`, `ro-RO`, `en-RO`, `el-GR`, `en-GR`, `en-AU`, `en-NZ`, `en-CA`, `fr-CA`, `pl-PL`, `en-PL`, `pt-PT`, `en-PT`, `de-CH`, `fr-CH`, `it-CH`, or `en-CH` """ + _inner_class_types = {"payer_details": PayerDetails} class Konbini(StripeObject): class Store(StripeObject): diff --git a/stripe/_dispute.py b/stripe/_dispute.py index a7110e941..e75cf056f 100644 --- a/stripe/_dispute.py +++ b/stripe/_dispute.py @@ -165,6 +165,12 @@ class EvidenceDetails(StripeObject): """ class PaymentMethodDetails(StripeObject): + class AmazonPay(StripeObject): + dispute_type: Optional[Literal["chargeback", "claim"]] + """ + The AmazonPay dispute type, chargeback or claim + """ + class Card(StripeObject): brand: str """ @@ -195,14 +201,20 @@ class Paypal(StripeObject): The reason for the dispute as defined by PayPal """ + amazon_pay: Optional[AmazonPay] card: Optional[Card] klarna: Optional[Klarna] paypal: Optional[Paypal] - type: Literal["card", "klarna", "paypal"] + type: Literal["amazon_pay", "card", "klarna", "paypal"] """ Payment method type. """ - _inner_class_types = {"card": Card, "klarna": Klarna, "paypal": Paypal} + _inner_class_types = { + "amazon_pay": AmazonPay, + "card": Card, + "klarna": Klarna, + "paypal": Paypal, + } class CloseParams(RequestOptions): expand: NotRequired[List[str]] diff --git a/stripe/_invoice.py b/stripe/_invoice.py index 8e83f0200..07f217f9e 100644 --- a/stripe/_invoice.py +++ b/stripe/_invoice.py @@ -479,6 +479,7 @@ class LastFinalizationError(StripeObject): "terminal_location_country_unsupported", "terminal_reader_busy", "terminal_reader_hardware_fault", + "terminal_reader_invalid_location_for_activation", "terminal_reader_invalid_location_for_payment", "terminal_reader_offline", "terminal_reader_timeout", @@ -6164,6 +6165,10 @@ class VoidInvoiceParams(RequestOptions): Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action. """ automatic_tax: AutomaticTax + automatically_finalizes_at: Optional[int] + """ + The time when this invoice is currently scheduled to be automatically finalized. The field will be `null` if the invoice is not scheduled to finalize in the future. If the invoice is not in the draft state, this field will always be `null` - see `finalized_at` for the time when an already-finalized invoice was finalized. + """ billing_reason: Optional[ Literal[ "automatic_pending_invoice_item_invoice", diff --git a/stripe/_invoice_rendering_template.py b/stripe/_invoice_rendering_template.py index 5a57cf743..5d7dc7e2f 100644 --- a/stripe/_invoice_rendering_template.py +++ b/stripe/_invoice_rendering_template.py @@ -11,6 +11,11 @@ class InvoiceRenderingTemplate( ListableAPIResource["InvoiceRenderingTemplate"] ): + """ + Invoice Rendering Templates are used to configure how invoices are rendered on surfaces like the PDF. Invoice Rendering Templates + can be created from within the Dashboard, and they can be used over the API when creating invoices. + """ + OBJECT_NAME: ClassVar[Literal["invoice_rendering_template"]] = ( "invoice_rendering_template" ) diff --git a/stripe/_payment_intent.py b/stripe/_payment_intent.py index 78fdab4ed..974f9e729 100644 --- a/stripe/_payment_intent.py +++ b/stripe/_payment_intent.py @@ -255,6 +255,7 @@ class LastPaymentError(StripeObject): "terminal_location_country_unsupported", "terminal_reader_busy", "terminal_reader_hardware_fault", + "terminal_reader_invalid_location_for_activation", "terminal_reader_invalid_location_for_payment", "terminal_reader_offline", "terminal_reader_timeout", diff --git a/stripe/_person.py b/stripe/_person.py index 33b573801..7082f215b 100644 --- a/stripe/_person.py +++ b/stripe/_person.py @@ -246,6 +246,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. @@ -443,6 +444,7 @@ class Error(StripeObject): "verification_missing_owners", "verification_requires_additional_memorandum_of_associations", "verification_requires_additional_proof_of_registration", + "verification_supportability", ] """ The code for the type of error. diff --git a/stripe/_setup_attempt.py b/stripe/_setup_attempt.py index 1745937ef..d9d8d570b 100644 --- a/stripe/_setup_attempt.py +++ b/stripe/_setup_attempt.py @@ -591,6 +591,7 @@ class SetupError(StripeObject): "terminal_location_country_unsupported", "terminal_reader_busy", "terminal_reader_hardware_fault", + "terminal_reader_invalid_location_for_activation", "terminal_reader_invalid_location_for_payment", "terminal_reader_offline", "terminal_reader_timeout", diff --git a/stripe/_setup_intent.py b/stripe/_setup_intent.py index b19a36352..ed2da02a6 100644 --- a/stripe/_setup_intent.py +++ b/stripe/_setup_intent.py @@ -240,6 +240,7 @@ class LastSetupError(StripeObject): "terminal_location_country_unsupported", "terminal_reader_busy", "terminal_reader_hardware_fault", + "terminal_reader_invalid_location_for_activation", "terminal_reader_invalid_location_for_payment", "terminal_reader_offline", "terminal_reader_timeout", diff --git a/stripe/tax/_registration.py b/stripe/tax/_registration.py index 807558ad0..43bcb69a7 100644 --- a/stripe/tax/_registration.py +++ b/stripe/tax/_registration.py @@ -582,12 +582,34 @@ class LocalLeaseTax(StripeObject): A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. """ + class StateSalesTax(StripeObject): + class Election(StripeObject): + jurisdiction: Optional[str] + """ + A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. + """ + type: Literal[ + "local_use_tax", + "simplified_sellers_use_tax", + "single_local_use_tax", + ] + """ + The type of the election for the state sales tax registration. + """ + + elections: Optional[List[Election]] + """ + Elections for the state sales tax registration. + """ + _inner_class_types = {"elections": Election} + local_amusement_tax: Optional[LocalAmusementTax] local_lease_tax: Optional[LocalLeaseTax] state: str """ Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). """ + state_sales_tax: Optional[StateSalesTax] type: Literal[ "local_amusement_tax", "local_lease_tax", @@ -600,6 +622,7 @@ class LocalLeaseTax(StripeObject): _inner_class_types = { "local_amusement_tax": LocalAmusementTax, "local_lease_tax": LocalLeaseTax, + "state_sales_tax": StateSalesTax, } class Vn(StripeObject): @@ -1650,6 +1673,12 @@ class CreateParamsCountryOptionsUs(TypedDict): """ Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). """ + state_sales_tax: NotRequired[ + "Registration.CreateParamsCountryOptionsUsStateSalesTax" + ] + """ + Options for the state sales tax registration. + """ type: Literal[ "local_amusement_tax", "local_lease_tax", @@ -1672,6 +1701,28 @@ class CreateParamsCountryOptionsUsLocalLeaseTax(TypedDict): A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago). """ + class CreateParamsCountryOptionsUsStateSalesTax(TypedDict): + elections: List[ + "Registration.CreateParamsCountryOptionsUsStateSalesTaxElection" + ] + """ + Elections for the state sales tax registration. + """ + + class CreateParamsCountryOptionsUsStateSalesTaxElection(TypedDict): + jurisdiction: NotRequired[str] + """ + A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `003` (Allegheny County) and `60000` (Philadelphia City). + """ + type: Literal[ + "local_use_tax", + "simplified_sellers_use_tax", + "single_local_use_tax", + ] + """ + The type of the election for the state sales tax registration. + """ + class CreateParamsCountryOptionsVn(TypedDict): type: Literal["simplified"] """ diff --git a/stripe/tax/_registration_service.py b/stripe/tax/_registration_service.py index 1f9b4ba93..fd7ccda89 100644 --- a/stripe/tax/_registration_service.py +++ b/stripe/tax/_registration_service.py @@ -934,6 +934,12 @@ class CreateParamsCountryOptionsUs(TypedDict): """ Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). """ + state_sales_tax: NotRequired[ + "RegistrationService.CreateParamsCountryOptionsUsStateSalesTax" + ] + """ + Options for the state sales tax registration. + """ type: Literal[ "local_amusement_tax", "local_lease_tax", @@ -956,6 +962,28 @@ class CreateParamsCountryOptionsUsLocalLeaseTax(TypedDict): A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago). """ + class CreateParamsCountryOptionsUsStateSalesTax(TypedDict): + elections: List[ + "RegistrationService.CreateParamsCountryOptionsUsStateSalesTaxElection" + ] + """ + Elections for the state sales tax registration. + """ + + class CreateParamsCountryOptionsUsStateSalesTaxElection(TypedDict): + jurisdiction: NotRequired[str] + """ + A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `003` (Allegheny County) and `60000` (Philadelphia City). + """ + type: Literal[ + "local_use_tax", + "simplified_sellers_use_tax", + "single_local_use_tax", + ] + """ + The type of the election for the state sales tax registration. + """ + class CreateParamsCountryOptionsVn(TypedDict): type: Literal["simplified"] """